27d9a429
suweicheng
开发梳理;
|
1
2
3
|
package com.essa.testSuite;
import com.essa.pageObject.BaseTest;
|
a0824d2d
toby5221
啊啊啊
|
4
|
import com.essa.pageObject.HomePage;
|
a294c18e
zengjin
修改设置装柜的返回值
|
5
6
|
import com.essa.pageObject.DocumentaryManage.POBoardPage;
import com.essa.pageObject.DocumentaryManage.PODocumentaryListPage;
|
27d9a429
suweicheng
开发梳理;
|
7
|
import org.openqa.selenium.WebDriver;
|
a0824d2d
toby5221
啊啊啊
|
8
|
import org.openqa.selenium.support.PageFactory;
|
27d9a429
suweicheng
开发梳理;
|
9
10
11
|
import org.testng.annotations.AfterClass;
import org.testng.annotations.BeforeClass;
import org.testng.annotations.Test;
|
438eca07
toby5221
添加断言
|
12
|
import org.testng.asserts.SoftAssert;
|
27d9a429
suweicheng
开发梳理;
|
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
|
public class TestNoticeReceiveAndLoad extends BaseTest{
WebDriver driver;
@BeforeClass
public void setUp(){
initsetUp();
loginValid("chenyijie");
}
@AfterClass
public void tearDown(){
driver.quit();
}
/**
|
a0824d2d
toby5221
啊啊啊
|
30
|
* 通知收货、装柜
|
27d9a429
suweicheng
开发梳理;
|
31
|
*/
|
a0824d2d
toby5221
啊啊啊
|
32
|
@Test(description = "通知收货、装柜")
|
27d9a429
suweicheng
开发梳理;
|
33
34
|
public void NoticeReceiveAndLoad(){
this.driver = getDriver();
|
a0824d2d
toby5221
啊啊啊
|
35
36
37
38
39
|
HomePage homePage = PageFactory.initElements(driver,HomePage.class);
homePage.toPoDocumentaryListPage();
PODocumentaryListPage poDocumentaryListPage = PageFactory.initElements(driver,PODocumentaryListPage.class);
POBoardPage poBoardPage = PageFactory.initElements(driver,POBoardPage.class);
poDocumentaryListPage.toPoFollowDetail();
|
438eca07
toby5221
添加断言
|
40
41
|
//通知收货
|
a0824d2d
toby5221
啊啊啊
|
42
|
poBoardPage.noticeReceive();
|
438eca07
toby5221
添加断言
|
43
44
45
46
47
48
49
50
|
//断言:通知收货是否成功
boolean actualReceive = poBoardPage.isNoticeReceSucceed();
SoftAssert softAssert = new SoftAssert();
softAssert.assertEquals(actualReceive,true,"通知收货失败!");
softAssert.assertAll();
//通知装柜
|
a0824d2d
toby5221
啊啊啊
|
51
|
poBoardPage.noticeLoad();
|
438eca07
toby5221
添加断言
|
52
53
54
55
56
57
|
//断言:通知收货是否成功
boolean actualLoae = poBoardPage.isNoticeReceSucceed();
SoftAssert anAssert = new SoftAssert();
anAssert.assertEquals(actualLoae,true,"通知装柜失败!");
anAssert.assertAll();
|
27d9a429
suweicheng
开发梳理;
|
58
|
}
|
a0824d2d
toby5221
啊啊啊
|
59
|
|
27d9a429
suweicheng
开发梳理;
|
60
|
}
|