└── MyStoreProject
├── .gitignore
├── test-output
├── old
│ ├── Suite
│ │ ├── Test.properties
│ │ ├── Sanity.properties
│ │ ├── Test_All.properties
│ │ ├── Regression.properties
│ │ ├── reporter-output.html
│ │ ├── main.html
│ │ ├── index.html
│ │ ├── methods-not-run.html
│ │ ├── toc.html
│ │ ├── testng.xml.html
│ │ ├── groups.html
│ │ ├── classes.html
│ │ └── methods.html
│ ├── CrossBrowser
│ │ ├── reporter-output.html
│ │ ├── methods-not-run.html
│ │ ├── IETest.properties
│ │ ├── FirefoxTest.properties
│ │ ├── ChromeTest.properties
│ │ ├── main.html
│ │ ├── index.html
│ │ ├── groups.html
│ │ ├── classes.html
│ │ ├── toc.html
│ │ ├── testng.xml.html
│ │ ├── methods.html
│ │ └── methods-alphabetical.html
│ ├── Default suite
│ │ ├── Default test.properties
│ │ ├── reporter-output.html
│ │ ├── methods-not-run.html
│ │ ├── main.html
│ │ ├── index.html
│ │ ├── groups.html
│ │ ├── testng.xml.html
│ │ ├── classes.html
│ │ ├── methods.html
│ │ ├── methods-alphabetical.html
│ │ └── toc.html
│ └── index.html
├── failed.png
├── passed.png
├── skipped.png
├── collapseall.gif
├── bullet_point.png
├── navigator-bullet.png
├── testng.css
├── CrossBrowser
│ ├── ChromeTest.xml
│ ├── FirefoxTest.xml
│ ├── IETest.xml
│ ├── testng-failed.xml
│ ├── ChromeTest.html
│ ├── FirefoxTest.html
│ └── IETest.html
├── junitreports
│ ├── TEST-com.mystore.testcases.OderPageTest.xml
│ ├── TEST-com.mystore.testcases.EndToEndTest.xml
│ ├── TEST-com.mystore.testcases.LoginPageTest.xml
│ ├── TEST-com.mystore.testcases.OrderPageTest.xml
│ ├── TEST-com.mystore.testcases.AddToCartPageTest.xml
│ ├── TEST-com.mystore.testcases.SearchResultPageTest.xml
│ ├── TEST-com.mystore.testcases.AccountCreationPageTest.xml
│ ├── TEST-com.mystore.testcases.HomePageTest.xml
│ └── TEST-com.mystore.testcases.IndexPageTest.xml
├── Default suite
│ ├── testng-failed.xml
│ ├── Default test.xml
│ └── Default test.html
├── testng-failed.xml
├── Suite
│ ├── testng-failed.xml
│ ├── Test.xml
│ ├── Regression.html
│ ├── Sanity.html
│ ├── Sanity.xml
│ ├── Regression.xml
│ ├── Test_All.xml
│ ├── Test.html
│ └── Test_All.html
├── testng-reports.js
├── testng-reports.css
└── emailable-report.html
├── Logo
└── MyStore.png
├── Documentation
├── PageNavigation.png
├── FrameworkArchitecture.png
└── Steps for Log4j,Extent,DataProvider.txt
├── .settings
├── org.eclipse.m2e.core.prefs
└── org.eclipse.jdt.core.prefs
├── ScreenShots
├── verifyTitle_20200717114112.png
├── createAccountTest_20200727052435.png
└── orderHistoryandDetailsTest_20200717113854.png
├── src
├── test
│ ├── resources
│ │ └── TestData
│ │ │ └── TestData.xlsx
│ └── java
│ │ └── com
│ │ └── mystore
│ │ └── testcases
│ │ ├── IndexPageTest.java
│ │ ├── SearchResultPageTest.java
│ │ ├── AddToCartPageTest.java
│ │ ├── LoginPageTest.java
│ │ ├── OrderPageTest.java
│ │ ├── HomePageTest.java
│ │ ├── AccountCreationPageTest.java
│ │ └── EndToEndTest.java
└── main
│ └── java
│ └── com
│ └── mystore
│ ├── pageobjects
│ ├── AddressPage.java
│ ├── OrderConfirmationPage.java
│ ├── OrderSummary.java
│ ├── PaymentPage.java
│ ├── SearchResultPage.java
│ ├── ShippingPage.java
│ ├── HomePage.java
│ ├── OrderPage.java
│ ├── IndexPage.java
│ ├── AddToCartPage.java
│ ├── LoginPage.java
│ └── AccountCreationPage.java
│ ├── utility
│ ├── Log.java
│ ├── ExtentManager.java
│ └── ListenerClass.java
│ ├── actioninterface
│ └── ActionInterface.java
│ ├── base
│ └── BaseClass.java
│ └── dataprovider
│ └── DataProviders.java
├── Configuration
└── Config.properties
├── log4j.dtd
├── .project
├── testng_crossbrowser.xml
├── testng_all.xml
├── testng_smoke.xml
├── testng_sanity.xml
├── testng_regression.xml
├── log4j.xml
├── .classpath
├── extent-config.xml
└── pom.xml
/MyStoreProject/.gitignore:
--------------------------------------------------------------------------------
1 | /target/
2 |
--------------------------------------------------------------------------------
/MyStoreProject/test-output/old/Suite/Test.properties:
--------------------------------------------------------------------------------
1 | [SuiteResult context=Test]
--------------------------------------------------------------------------------
/MyStoreProject/test-output/old/Suite/Sanity.properties:
--------------------------------------------------------------------------------
1 | [SuiteResult context=Sanity]
--------------------------------------------------------------------------------
/MyStoreProject/test-output/old/Suite/Test_All.properties:
--------------------------------------------------------------------------------
1 | [SuiteResult context=Test_All]
--------------------------------------------------------------------------------
/MyStoreProject/test-output/old/Suite/Regression.properties:
--------------------------------------------------------------------------------
1 | [SuiteResult context=Regression]
--------------------------------------------------------------------------------
/MyStoreProject/test-output/old/Suite/reporter-output.html:
--------------------------------------------------------------------------------
1 |
Reporter output
--------------------------------------------------------------------------------
/MyStoreProject/test-output/old/CrossBrowser/reporter-output.html:
--------------------------------------------------------------------------------
1 | Reporter output
--------------------------------------------------------------------------------
/MyStoreProject/test-output/old/Default suite/Default test.properties:
--------------------------------------------------------------------------------
1 | [SuiteResult context=Default test]
--------------------------------------------------------------------------------
/MyStoreProject/test-output/old/Default suite/reporter-output.html:
--------------------------------------------------------------------------------
1 | Reporter output
--------------------------------------------------------------------------------
/MyStoreProject/Logo/MyStore.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hverma22/MyProject/HEAD/MyStoreProject/Logo/MyStore.png
--------------------------------------------------------------------------------
/MyStoreProject/test-output/old/CrossBrowser/methods-not-run.html:
--------------------------------------------------------------------------------
1 | Methods that were not run
--------------------------------------------------------------------------------
/MyStoreProject/test-output/old/CrossBrowser/IETest.properties:
--------------------------------------------------------------------------------
1 | [SuiteResult context=IETest][SuiteResult context=FirefoxTest]
--------------------------------------------------------------------------------
/MyStoreProject/test-output/old/Default suite/methods-not-run.html:
--------------------------------------------------------------------------------
1 | Methods that were not run
--------------------------------------------------------------------------------
/MyStoreProject/test-output/failed.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hverma22/MyProject/HEAD/MyStoreProject/test-output/failed.png
--------------------------------------------------------------------------------
/MyStoreProject/test-output/old/CrossBrowser/FirefoxTest.properties:
--------------------------------------------------------------------------------
1 | [SuiteResult context=IETest][SuiteResult context=FirefoxTest]
--------------------------------------------------------------------------------
/MyStoreProject/test-output/passed.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hverma22/MyProject/HEAD/MyStoreProject/test-output/passed.png
--------------------------------------------------------------------------------
/MyStoreProject/test-output/old/CrossBrowser/ChromeTest.properties:
--------------------------------------------------------------------------------
1 | [SuiteResult context=ChromeTest][SuiteResult context=FirefoxTest]
--------------------------------------------------------------------------------
/MyStoreProject/test-output/skipped.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hverma22/MyProject/HEAD/MyStoreProject/test-output/skipped.png
--------------------------------------------------------------------------------
/MyStoreProject/test-output/collapseall.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hverma22/MyProject/HEAD/MyStoreProject/test-output/collapseall.gif
--------------------------------------------------------------------------------
/MyStoreProject/test-output/bullet_point.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hverma22/MyProject/HEAD/MyStoreProject/test-output/bullet_point.png
--------------------------------------------------------------------------------
/MyStoreProject/Documentation/PageNavigation.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hverma22/MyProject/HEAD/MyStoreProject/Documentation/PageNavigation.png
--------------------------------------------------------------------------------
/MyStoreProject/test-output/navigator-bullet.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hverma22/MyProject/HEAD/MyStoreProject/test-output/navigator-bullet.png
--------------------------------------------------------------------------------
/MyStoreProject/.settings/org.eclipse.m2e.core.prefs:
--------------------------------------------------------------------------------
1 | activeProfiles=
2 | eclipse.preferences.version=1
3 | resolveWorkspaceProjects=true
4 | version=1
5 |
--------------------------------------------------------------------------------
/MyStoreProject/Documentation/FrameworkArchitecture.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hverma22/MyProject/HEAD/MyStoreProject/Documentation/FrameworkArchitecture.png
--------------------------------------------------------------------------------
/MyStoreProject/ScreenShots/verifyTitle_20200717114112.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hverma22/MyProject/HEAD/MyStoreProject/ScreenShots/verifyTitle_20200717114112.png
--------------------------------------------------------------------------------
/MyStoreProject/src/test/resources/TestData/TestData.xlsx:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hverma22/MyProject/HEAD/MyStoreProject/src/test/resources/TestData/TestData.xlsx
--------------------------------------------------------------------------------
/MyStoreProject/test-output/old/Suite/main.html:
--------------------------------------------------------------------------------
1 | Results for Suite
2 | Select a result on the left-hand pane.
3 |
--------------------------------------------------------------------------------
/MyStoreProject/ScreenShots/createAccountTest_20200727052435.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hverma22/MyProject/HEAD/MyStoreProject/ScreenShots/createAccountTest_20200727052435.png
--------------------------------------------------------------------------------
/MyStoreProject/test-output/old/CrossBrowser/main.html:
--------------------------------------------------------------------------------
1 | Results for CrossBrowser
2 | Select a result on the left-hand pane.
3 |
--------------------------------------------------------------------------------
/MyStoreProject/test-output/old/Default suite/main.html:
--------------------------------------------------------------------------------
1 | Results for Default suite
2 | Select a result on the left-hand pane.
3 |
--------------------------------------------------------------------------------
/MyStoreProject/ScreenShots/orderHistoryandDetailsTest_20200717113854.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hverma22/MyProject/HEAD/MyStoreProject/ScreenShots/orderHistoryandDetailsTest_20200717113854.png
--------------------------------------------------------------------------------
/MyStoreProject/Configuration/Config.properties:
--------------------------------------------------------------------------------
1 | url=http://automationpractice.com/index.php?
2 | username=admin@xyz.com
3 | password=admin@123
4 | browser=Chrome
5 | implicitWait= 10
6 | pageLoadTimeOut=40
--------------------------------------------------------------------------------
/MyStoreProject/test-output/old/Suite/index.html:
--------------------------------------------------------------------------------
1 | Results for Suite
2 |
3 |
4 |
5 |
6 |
7 |
--------------------------------------------------------------------------------
/MyStoreProject/test-output/old/CrossBrowser/index.html:
--------------------------------------------------------------------------------
1 | Results for CrossBrowser
2 |
3 |
4 |
5 |
6 |
7 |
--------------------------------------------------------------------------------
/MyStoreProject/test-output/old/Default suite/index.html:
--------------------------------------------------------------------------------
1 | Results for Default suite
2 |
3 |
4 |
5 |
6 |
7 |
--------------------------------------------------------------------------------
/MyStoreProject/test-output/testng.css:
--------------------------------------------------------------------------------
1 | .invocation-failed, .test-failed { background-color: #DD0000; }
2 | .invocation-percent, .test-percent { background-color: #006600; }
3 | .invocation-passed, .test-passed { background-color: #00AA00; }
4 | .invocation-skipped, .test-skipped { background-color: #CCCC00; }
5 |
6 | .main-page {
7 | font-size: x-large;
8 | }
9 |
10 |
--------------------------------------------------------------------------------
/MyStoreProject/test-output/old/Default suite/groups.html:
--------------------------------------------------------------------------------
1 | Groups used for this test run
2 | Group name Methods Sanity AccountCreationPageTest.verifyCreateAccountPageTest(java.lang.String)[pri:0, instance:com.mystore.testcases.AccountCreationPageTest@6ee52dcd]
3 |
4 |
--------------------------------------------------------------------------------
/MyStoreProject/.settings/org.eclipse.jdt.core.prefs:
--------------------------------------------------------------------------------
1 | eclipse.preferences.version=1
2 | org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.8
3 | org.eclipse.jdt.core.compiler.compliance=1.8
4 | org.eclipse.jdt.core.compiler.problem.enablePreviewFeatures=disabled
5 | org.eclipse.jdt.core.compiler.problem.forbiddenReference=warning
6 | org.eclipse.jdt.core.compiler.problem.reportPreviewFeatures=ignore
7 | org.eclipse.jdt.core.compiler.release=disabled
8 | org.eclipse.jdt.core.compiler.source=1.8
9 |
--------------------------------------------------------------------------------
/MyStoreProject/test-output/CrossBrowser/ChromeTest.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
--------------------------------------------------------------------------------
/MyStoreProject/test-output/CrossBrowser/FirefoxTest.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
--------------------------------------------------------------------------------
/MyStoreProject/test-output/junitreports/TEST-com.mystore.testcases.OderPageTest.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
--------------------------------------------------------------------------------
/MyStoreProject/test-output/junitreports/TEST-com.mystore.testcases.EndToEndTest.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
--------------------------------------------------------------------------------
/MyStoreProject/test-output/junitreports/TEST-com.mystore.testcases.LoginPageTest.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
--------------------------------------------------------------------------------
/MyStoreProject/test-output/junitreports/TEST-com.mystore.testcases.OrderPageTest.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
--------------------------------------------------------------------------------
/MyStoreProject/test-output/junitreports/TEST-com.mystore.testcases.AddToCartPageTest.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
--------------------------------------------------------------------------------
/MyStoreProject/test-output/junitreports/TEST-com.mystore.testcases.SearchResultPageTest.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
--------------------------------------------------------------------------------
/MyStoreProject/test-output/junitreports/TEST-com.mystore.testcases.AccountCreationPageTest.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
--------------------------------------------------------------------------------
/MyStoreProject/log4j.dtd:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
--------------------------------------------------------------------------------
/MyStoreProject/.project:
--------------------------------------------------------------------------------
1 |
2 |
3 | MyStoreProject
4 |
5 |
6 |
7 |
8 |
9 | org.eclipse.jdt.core.javabuilder
10 |
11 |
12 |
13 |
14 | org.eclipse.m2e.core.maven2Builder
15 |
16 |
17 |
18 |
19 |
20 | org.eclipse.jdt.core.javanature
21 | org.eclipse.m2e.core.maven2Nature
22 |
23 |
24 |
--------------------------------------------------------------------------------
/MyStoreProject/test-output/CrossBrowser/IETest.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
--------------------------------------------------------------------------------
/MyStoreProject/test-output/old/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | Test results
6 | Suite Passed Failed Skipped testng.xml
7 | Total 8 2 0
8 | Suite
9 | 8 2 0 Link
10 |
--------------------------------------------------------------------------------
/MyStoreProject/test-output/old/CrossBrowser/groups.html:
--------------------------------------------------------------------------------
1 | Groups used for this test run
2 | Group name Methods Smoke IndexPageTest.verifyLogo()[pri:0, instance:com.mystore.testcases.IndexPageTest@2781e022] IndexPageTest.verifyLogo()[pri:0, instance:com.mystore.testcases.IndexPageTest@51e2adc7] IndexPageTest.verifyLogo()[pri:0, instance:com.mystore.testcases.IndexPageTest@3d921e20] IndexPageTest.verifyTitle()[pri:0, instance:com.mystore.testcases.IndexPageTest@2781e022] IndexPageTest.verifyTitle()[pri:0, instance:com.mystore.testcases.IndexPageTest@51e2adc7] IndexPageTest.verifyTitle()[pri:0, instance:com.mystore.testcases.IndexPageTest@3d921e20]
3 |
4 |
--------------------------------------------------------------------------------
/MyStoreProject/test-output/old/Default suite/testng.xml.html:
--------------------------------------------------------------------------------
1 | testng.xml for Default suite <?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE suite SYSTEM "https://testng.org/testng-1.0.dtd">
<suite guice-stage="DEVELOPMENT" name="Default suite">
<test thread-count="5" verbose="2" name="Default test">
<classes>
<class name="com.mystore.testcases.AccountCreationPageTest"/>
</classes>
</test> <!-- Default test -->
</suite> <!-- Default suite -->
--------------------------------------------------------------------------------
/MyStoreProject/test-output/Default suite/testng-failed.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
--------------------------------------------------------------------------------
/MyStoreProject/test-output/CrossBrowser/testng-failed.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
--------------------------------------------------------------------------------
/MyStoreProject/src/main/java/com/mystore/pageobjects/AddressPage.java:
--------------------------------------------------------------------------------
1 | /**
2 | *
3 | */
4 | package com.mystore.pageobjects;
5 |
6 | import org.openqa.selenium.WebElement;
7 | import org.openqa.selenium.support.FindBy;
8 | import org.openqa.selenium.support.PageFactory;
9 |
10 | import com.mystore.actiondriver.Action;
11 | import com.mystore.base.BaseClass;
12 |
13 | /**
14 | * @author Hitendra
15 | *
16 | */
17 | public class AddressPage extends BaseClass {
18 |
19 | Action action= new Action();
20 |
21 | @FindBy(xpath="//span[text()='Proceed to checkout']")
22 | private WebElement proceedToCheckOut;
23 |
24 | public AddressPage() {
25 | PageFactory.initElements(getDriver(), this);
26 | }
27 |
28 | public ShippingPage clickOnCheckOut() throws Throwable {
29 | action.click(getDriver(), proceedToCheckOut);
30 | return new ShippingPage();
31 | }
32 |
33 | }
34 |
--------------------------------------------------------------------------------
/MyStoreProject/src/main/java/com/mystore/pageobjects/OrderConfirmationPage.java:
--------------------------------------------------------------------------------
1 | /**
2 | *
3 | */
4 | package com.mystore.pageobjects;
5 |
6 | import org.openqa.selenium.WebElement;
7 | import org.openqa.selenium.support.FindBy;
8 | import org.openqa.selenium.support.PageFactory;
9 |
10 | import com.mystore.actiondriver.Action;
11 | import com.mystore.base.BaseClass;
12 |
13 | /**
14 | * @author Hitendra
15 | *
16 | */
17 | public class OrderConfirmationPage extends BaseClass {
18 |
19 | Action action= new Action();
20 |
21 | @FindBy(xpath="//p/strong[contains(text(),'Your order on My Store is complete.')]")
22 | private WebElement confirmMessag;
23 |
24 | public OrderConfirmationPage() {
25 | PageFactory.initElements(getDriver(), this);
26 | }
27 |
28 | public String validateConfirmMessage() {
29 | String confirmMsg=confirmMessag.getText();
30 | return confirmMsg;
31 | }
32 |
33 |
34 | }
35 |
--------------------------------------------------------------------------------
/MyStoreProject/test-output/old/Suite/methods-not-run.html:
--------------------------------------------------------------------------------
1 | Methods that were not run
2 | com.mystore.base.BaseClass.loadConfig
3 | com.mystore.base.BaseClass.loadConfig
4 | com.mystore.base.BaseClass.loadConfig
5 | com.mystore.base.BaseClass.loadConfig
6 | com.mystore.base.BaseClass.loadConfig
7 | com.mystore.base.BaseClass.loadConfig
8 | com.mystore.base.BaseClass.loadConfig
9 | com.mystore.base.BaseClass.afterSuite
10 | com.mystore.base.BaseClass.afterSuite
11 | com.mystore.base.BaseClass.afterSuite
12 | com.mystore.base.BaseClass.afterSuite
13 | com.mystore.base.BaseClass.afterSuite
14 | com.mystore.base.BaseClass.afterSuite
15 | com.mystore.base.BaseClass.afterSuite
16 |
--------------------------------------------------------------------------------
/MyStoreProject/testng_crossbrowser.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
--------------------------------------------------------------------------------
/MyStoreProject/test-output/old/Default suite/classes.html:
--------------------------------------------------------------------------------
1 |
2 |
3 | Class name
4 | Method name
5 | Groups
6 |
7 | com.mystore.testcases.AccountCreationPageTest
8 |
9 |
10 | @Test
11 |
12 |
13 |
14 | verifyCreateAccountPageTest
15 | Sanity
16 |
17 |
18 | @BeforeClass
19 |
20 |
21 | @BeforeMethod
22 |
23 |
24 |
25 | setup
26 | Sanity Regression Smoke
27 |
28 |
29 | @AfterMethod
30 |
31 |
32 |
33 | tearDown
34 | Sanity Regression Smoke
35 |
36 |
37 | @AfterClass
38 |
39 |
40 |
--------------------------------------------------------------------------------
/MyStoreProject/testng_all.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
--------------------------------------------------------------------------------
/MyStoreProject/src/main/java/com/mystore/pageobjects/OrderSummary.java:
--------------------------------------------------------------------------------
1 | /**
2 | *
3 | */
4 | package com.mystore.pageobjects;
5 |
6 | import java.security.PublicKey;
7 |
8 | import org.openqa.selenium.WebElement;
9 | import org.openqa.selenium.support.FindBy;
10 | import org.openqa.selenium.support.PageFactory;
11 |
12 | import com.mystore.actiondriver.Action;
13 | import com.mystore.base.BaseClass;
14 |
15 | /**
16 | * @author Hitendra
17 | *
18 | */
19 | public class OrderSummary extends BaseClass {
20 |
21 | Action action= new Action();
22 |
23 | @FindBy(xpath="//span[contains(text(),'I confirm my order')]")
24 | private WebElement confirmOrderBtn;
25 |
26 | public OrderSummary() {
27 | PageFactory.initElements(getDriver(), this);
28 | }
29 |
30 | public OrderConfirmationPage clickOnconfirmOrderBtn() throws Throwable {
31 | action.click(getDriver(), confirmOrderBtn);
32 | return new OrderConfirmationPage();
33 | }
34 |
35 | }
36 |
--------------------------------------------------------------------------------
/MyStoreProject/src/main/java/com/mystore/pageobjects/PaymentPage.java:
--------------------------------------------------------------------------------
1 | /**
2 | *
3 | */
4 | package com.mystore.pageobjects;
5 |
6 | import org.openqa.selenium.WebElement;
7 | import org.openqa.selenium.support.FindBy;
8 | import org.openqa.selenium.support.PageFactory;
9 |
10 | import com.mystore.actiondriver.Action;
11 | import com.mystore.base.BaseClass;
12 |
13 | /**
14 | * @author Hitendra
15 | *
16 | */
17 | public class PaymentPage extends BaseClass {
18 |
19 | Action action= new Action();
20 |
21 | @FindBy(xpath = "//a[contains(text(),'Pay by bank wire')]")
22 | private WebElement bankWireMethod;
23 |
24 | @FindBy(xpath = "//a[contains(text(),'Pay by check')]")
25 | private WebElement payByCheckMethod;
26 |
27 | public PaymentPage() {
28 | PageFactory.initElements(getDriver(), this);
29 | }
30 |
31 | public OrderSummary clickOnPaymentMethod() throws Throwable {
32 | action.click(getDriver(), bankWireMethod);
33 | return new OrderSummary();
34 | }
35 |
36 | }
37 |
--------------------------------------------------------------------------------
/MyStoreProject/test-output/old/CrossBrowser/classes.html:
--------------------------------------------------------------------------------
1 |
2 |
3 | Class name
4 | Method name
5 | Groups
6 |
7 | com.mystore.testcases.IndexPageTest
8 |
9 |
10 | @Test
11 |
12 |
13 |
14 | verifyLogo
15 | Smoke
16 |
17 |
18 |
19 | verifyTitle
20 | Smoke
21 |
22 |
23 | @BeforeClass
24 |
25 |
26 | @BeforeMethod
27 |
28 |
29 |
30 | setup
31 | Sanity Regression Smoke
32 |
33 |
34 | @AfterMethod
35 |
36 |
37 |
38 | tearDown
39 | Sanity Regression Smoke
40 |
41 |
42 | @AfterClass
43 |
44 |
45 |
--------------------------------------------------------------------------------
/MyStoreProject/src/main/java/com/mystore/pageobjects/SearchResultPage.java:
--------------------------------------------------------------------------------
1 | /**
2 | *
3 | */
4 | package com.mystore.pageobjects;
5 |
6 | import org.openqa.selenium.WebElement;
7 | import org.openqa.selenium.support.FindBy;
8 | import org.openqa.selenium.support.PageFactory;
9 |
10 | import com.mystore.actiondriver.Action;
11 | import com.mystore.base.BaseClass;
12 |
13 | /**
14 | * @author Hitendra
15 | *
16 | */
17 | public class SearchResultPage extends BaseClass {
18 |
19 | Action action= new Action();
20 |
21 | @FindBy(xpath="//*[@id=\"center_column\"]//img")
22 | private WebElement productResult;
23 |
24 | public SearchResultPage() {
25 | PageFactory.initElements(getDriver(), this);
26 | }
27 |
28 | public boolean isProductAvailable() throws Throwable {
29 | return action.isDisplayed(getDriver(), productResult);
30 | }
31 |
32 | public AddToCartPage clickOnProduct() throws Throwable {
33 | action.click(getDriver(), productResult);
34 | return new AddToCartPage();
35 | }
36 |
37 | }
38 |
--------------------------------------------------------------------------------
/MyStoreProject/testng_smoke.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
--------------------------------------------------------------------------------
/MyStoreProject/testng_sanity.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
--------------------------------------------------------------------------------
/MyStoreProject/testng_regression.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
--------------------------------------------------------------------------------
/MyStoreProject/src/main/java/com/mystore/pageobjects/ShippingPage.java:
--------------------------------------------------------------------------------
1 | /**
2 | *
3 | */
4 | package com.mystore.pageobjects;
5 |
6 | import org.openqa.selenium.WebElement;
7 | import org.openqa.selenium.support.FindBy;
8 | import org.openqa.selenium.support.PageFactory;
9 |
10 | import com.mystore.actiondriver.Action;
11 | import com.mystore.base.BaseClass;
12 |
13 | /**
14 | * @author Hitendra
15 | *
16 | */
17 | public class ShippingPage extends BaseClass {
18 |
19 | Action action= new Action();
20 |
21 | @FindBy(id="cgv")
22 | private WebElement terms;
23 |
24 | @FindBy(xpath="//button/span[contains(text(),'Proceed to checkout')]")
25 | private WebElement proceedToCheckOutBtn;
26 |
27 | public ShippingPage() {
28 | PageFactory.initElements(getDriver(), this);
29 | }
30 |
31 | public void checkTheTerms() throws Throwable {
32 | action.click(getDriver(), terms);
33 | }
34 |
35 | public PaymentPage clickOnProceedToCheckOut() throws Throwable {
36 | action.click(getDriver(), proceedToCheckOutBtn);
37 | return new PaymentPage();
38 | }
39 |
40 | }
41 |
--------------------------------------------------------------------------------
/MyStoreProject/log4j.xml:
--------------------------------------------------------------------------------
1 |
3 |
4 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
--------------------------------------------------------------------------------
/MyStoreProject/test-output/old/Default suite/methods.html:
--------------------------------------------------------------------------------
1 | Methods run, sorted chronologically >> means before, << means after
Default suite
(Hover the method name to see the test class name)
2 |
3 | Time Delta (ms) Suite configuration Test configuration Class configuration Groups configuration Method configuration Test method Thread Instances
4 | 20/07/14 16:26:31 0 >>beforeSuite
5 | main@1897115967
6 | 20/07/14 16:26:32 157 >>loadConfig
7 | main@1897115967
8 |
9 |
--------------------------------------------------------------------------------
/MyStoreProject/test-output/old/Default suite/methods-alphabetical.html:
--------------------------------------------------------------------------------
1 | Methods run, sorted chronologically >> means before, << means after
Default suite
(Hover the method name to see the test class name)
2 |
3 | Time Delta (ms) Suite configuration Test configuration Class configuration Groups configuration Method configuration Test method Thread Instances
4 | 20/07/14 16:26:31 0 >>beforeSuite
5 | main@1897115967
6 | 20/07/14 16:26:32 157 >>loadConfig
7 | main@1897115967
8 |
9 |
--------------------------------------------------------------------------------
/MyStoreProject/src/main/java/com/mystore/pageobjects/HomePage.java:
--------------------------------------------------------------------------------
1 | /**
2 | *
3 | */
4 | package com.mystore.pageobjects;
5 |
6 | import org.openqa.selenium.WebElement;
7 | import org.openqa.selenium.support.FindBy;
8 | import org.openqa.selenium.support.PageFactory;
9 |
10 | import com.mystore.actiondriver.Action;
11 | import com.mystore.base.BaseClass;
12 |
13 | /**
14 | * @author Hitendra
15 | *
16 | */
17 | public class HomePage extends BaseClass {
18 |
19 | Action action= new Action();
20 |
21 | @FindBy(xpath="//span[text()='My wishlists']")
22 | private WebElement myWishList;
23 |
24 | @FindBy(xpath = "//span[text()='Order history and details']")
25 | private WebElement orderHistory;
26 |
27 | public HomePage() {
28 | PageFactory.initElements(getDriver(), this);
29 | }
30 |
31 |
32 | public boolean validateMyWishList() throws Throwable {
33 | return action.isDisplayed(getDriver(), myWishList);
34 | }
35 |
36 | public boolean validateOrderHistory() throws Throwable {
37 | return action.isDisplayed(getDriver(), orderHistory);
38 | }
39 |
40 | public String getCurrURL() throws Throwable {
41 | String homePageURL=action.getCurrentURL(getDriver());
42 | return homePageURL;
43 | }
44 | }
45 |
--------------------------------------------------------------------------------
/MyStoreProject/src/main/java/com/mystore/utility/Log.java:
--------------------------------------------------------------------------------
1 | package com.mystore.utility;
2 |
3 | import org.apache.log4j.Logger;
4 |
5 | public class Log {
6 |
7 | // Initialize Log4j logs
8 | public static Logger Log = Logger.getLogger(Log.class.getName());
9 |
10 | public static void startTestCase(String sTestCaseName){
11 | Log.info("====================================="+sTestCaseName+" TEST START=========================================");
12 | }
13 |
14 | public static void endTestCase(String sTestCaseName){
15 | Log.info("====================================="+sTestCaseName+" TEST END=========================================");
16 | }
17 |
18 | // Need to create below methods, so that they can be called
19 |
20 | public static void info(String message) {
21 |
22 | Log.info(message);
23 |
24 | }
25 |
26 | public static void warn(String message) {
27 |
28 | Log.warn(message);
29 |
30 | }
31 |
32 | public static void error(String message) {
33 |
34 | Log.error(message);
35 |
36 | }
37 |
38 | public static void fatal(String message) {
39 |
40 | Log.fatal(message);
41 |
42 | }
43 |
44 | public static void debug(String message) {
45 |
46 | Log.debug(message);
47 |
48 | }
49 |
50 | }
51 |
--------------------------------------------------------------------------------
/MyStoreProject/test-output/old/Suite/toc.html:
--------------------------------------------------------------------------------
1 |
2 |
3 | Results for Suite
4 |
5 |
6 |
7 |
8 | Results forSuite
9 |
23 |
30 |
--------------------------------------------------------------------------------
/MyStoreProject/test-output/old/Default suite/toc.html:
--------------------------------------------------------------------------------
1 |
2 |
3 | Results for Default suite
4 |
5 |
6 |
7 |
8 | Results forDefault suite
9 |
23 |
24 |
25 | Default test (0/1/0)
26 | Results
27 |
28 |
29 |
30 |
--------------------------------------------------------------------------------
/MyStoreProject/test-output/testng-failed.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
--------------------------------------------------------------------------------
/MyStoreProject/test-output/Suite/testng-failed.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
--------------------------------------------------------------------------------
/MyStoreProject/.classpath:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
--------------------------------------------------------------------------------
/MyStoreProject/src/test/java/com/mystore/testcases/IndexPageTest.java:
--------------------------------------------------------------------------------
1 | /**
2 | *
3 | */
4 | package com.mystore.testcases;
5 | import org.testng.Assert;
6 | import org.testng.annotations.AfterMethod;
7 | import org.testng.annotations.BeforeMethod;
8 | import org.testng.annotations.Parameters;
9 | import org.testng.annotations.Test;
10 | import com.mystore.base.BaseClass;
11 | import com.mystore.pageobjects.IndexPage;
12 | import com.mystore.utility.Log;
13 |
14 | /**
15 | * @author Hitendra
16 | *
17 | */
18 | public class IndexPageTest extends BaseClass {
19 | private IndexPage indexPage;
20 |
21 | @Parameters("browser")
22 | @BeforeMethod(groups = {"Smoke","Sanity","Regression"})
23 | public void setup(String browser) {
24 | launchApp(browser);
25 | }
26 |
27 | @AfterMethod(groups = {"Smoke","Sanity","Regression"})
28 | public void tearDown() {
29 | getDriver().quit();
30 | }
31 |
32 | @Test(groups = "Smoke")
33 | public void verifyLogo() throws Throwable {
34 | Log.startTestCase("verifyLogo");
35 | indexPage= new IndexPage();
36 | boolean result=indexPage.validateLogo();
37 | Assert.assertTrue(result);
38 | Log.endTestCase("verifyLogo");
39 | }
40 |
41 | @Test(groups = "Smoke")
42 | public void verifyTitle() {
43 | Log.startTestCase("verifyTitle");
44 | String actTitle=indexPage.getMyStoreTitle();
45 | Assert.assertEquals(actTitle, "My Store1");
46 | Log.endTestCase("verifyTitle");
47 | }
48 |
49 |
50 | }
51 |
--------------------------------------------------------------------------------
/MyStoreProject/src/main/java/com/mystore/pageobjects/OrderPage.java:
--------------------------------------------------------------------------------
1 | /**
2 | *
3 | */
4 | package com.mystore.pageobjects;
5 |
6 | import org.openqa.selenium.WebElement;
7 | import org.openqa.selenium.support.FindBy;
8 | import org.openqa.selenium.support.PageFactory;
9 |
10 | import com.mystore.actiondriver.Action;
11 | import com.mystore.base.BaseClass;
12 |
13 | /**
14 | * @author Hitendra
15 | *
16 | */
17 | public class OrderPage extends BaseClass {
18 |
19 | Action action= new Action();
20 |
21 | @FindBy(xpath="//td[@class='cart_unit']/span/span")
22 | private WebElement unitPrice;
23 |
24 | @FindBy(id="total_price")
25 | private WebElement totalPrice;
26 |
27 | @FindBy(xpath="//span[text()='Proceed to checkout']")
28 | private WebElement proceedToCheckOut;
29 |
30 | public OrderPage() {
31 | PageFactory.initElements(getDriver(), this);
32 | }
33 |
34 | public double getUnitPrice() {
35 | String unitPrice1=unitPrice.getText();
36 | String unit=unitPrice1.replaceAll("[^a-zA-Z0-9]","");
37 | double finalUnitPrice=Double.parseDouble(unit);
38 | return finalUnitPrice/100;
39 | }
40 |
41 | public double getTotalPrice() {
42 | String totalPrice1=totalPrice.getText();
43 | String tot=totalPrice1.replaceAll("[^a-zA-Z0-9]","");
44 | double finalTotalPrice=Double.parseDouble(tot);
45 | return finalTotalPrice/100;
46 | }
47 |
48 | public LoginPage clickOnCheckOut() throws Throwable {
49 | action.click(getDriver(), proceedToCheckOut);
50 | return new LoginPage();
51 | }
52 |
53 | }
54 |
--------------------------------------------------------------------------------
/MyStoreProject/src/test/java/com/mystore/testcases/SearchResultPageTest.java:
--------------------------------------------------------------------------------
1 | /**
2 | *
3 | */
4 | package com.mystore.testcases;
5 |
6 | import org.testng.Assert;
7 | import org.testng.annotations.AfterMethod;
8 | import org.testng.annotations.BeforeMethod;
9 | import org.testng.annotations.Parameters;
10 | import org.testng.annotations.Test;
11 |
12 | import com.mystore.base.BaseClass;
13 | import com.mystore.dataprovider.DataProviders;
14 | import com.mystore.pageobjects.IndexPage;
15 | import com.mystore.pageobjects.SearchResultPage;
16 | import com.mystore.utility.Log;
17 |
18 | /**
19 | * @author Hitendra
20 | *
21 | */
22 | public class SearchResultPageTest extends BaseClass {
23 | private IndexPage index;
24 | private SearchResultPage searchResultPage;
25 |
26 | @Parameters("browser")
27 | @BeforeMethod(groups = {"Smoke","Sanity","Regression"})
28 | public void setup(String browser) {
29 | launchApp(browser);
30 | }
31 |
32 | @AfterMethod(groups = {"Smoke","Sanity","Regression"})
33 | public void tearDown() {
34 | getDriver().quit();
35 | }
36 |
37 | @Test(groups = "Smoke",dataProvider = "searchProduct", dataProviderClass = DataProviders.class)
38 | public void productAvailabilityTest(String productName) throws Throwable {
39 | Log.startTestCase("productAvailabilityTest");
40 | index= new IndexPage();
41 | searchResultPage=index.searchProduct(productName);
42 | boolean result=searchResultPage.isProductAvailable();
43 | Assert.assertTrue(result);
44 | Log.endTestCase("productAvailabilityTest");
45 | }
46 |
47 | }
48 |
--------------------------------------------------------------------------------
/MyStoreProject/src/main/java/com/mystore/utility/ExtentManager.java:
--------------------------------------------------------------------------------
1 | package com.mystore.utility;
2 |
3 | import com.aventstack.extentreports.ExtentReports;
4 | import com.aventstack.extentreports.ExtentTest;
5 | import com.aventstack.extentreports.reporter.ExtentHtmlReporter;
6 | /**
7 | * @author Hitendra: ExtentManager class is used for Extent Report
8 | *
9 | */
10 | public class ExtentManager {
11 |
12 | public static ExtentHtmlReporter htmlReporter;
13 | public static ExtentReports extent;
14 | public static ExtentTest test;
15 |
16 | public static void setExtent() {
17 | //htmlReporter= new ExtentHtmlReporter(System.getProperty("user.dir")+"/test-output/ExtentReport/"+"MyReport_"+BaseClass.getCurrentTime()+".html");
18 | htmlReporter= new ExtentHtmlReporter(System.getProperty("user.dir")+"/test-output/ExtentReport/"+"MyReport.html");
19 | htmlReporter.loadXMLConfig(System.getProperty("user.dir")+"/extent-config.xml");
20 | //htmlReporter.config().setDocumentTitle("Automation Test Report");
21 | //htmlReporter.config().setReportName("OrangeHRM Test Automation Report");
22 | //htmlReporter.config().setTheme(Theme.DARK);
23 |
24 | extent = new ExtentReports();
25 | extent.attachReporter(htmlReporter);
26 |
27 | extent.setSystemInfo("HostName", "MyHost");
28 | extent.setSystemInfo("ProjectName", "MyStoreProject");
29 | extent.setSystemInfo("Tester", "Hitendra");
30 | extent.setSystemInfo("OS", "Win10");
31 | extent.setSystemInfo("Browser", "Chrome");
32 | }
33 | public static void endReport() {
34 | extent.flush();
35 | }
36 | }
37 |
--------------------------------------------------------------------------------
/MyStoreProject/test-output/old/CrossBrowser/toc.html:
--------------------------------------------------------------------------------
1 |
2 |
3 | Results for CrossBrowser
4 |
5 |
6 |
7 |
8 | Results forCrossBrowser
9 |
23 |
24 |
25 | FirefoxTest (2/0/0)
26 | Results
27 |
28 |
29 |
30 |
31 |
38 |
--------------------------------------------------------------------------------
/MyStoreProject/extent-config.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 | standard
7 |
8 |
9 |
10 | UTF-8
11 |
12 |
13 |
14 | http
15 |
16 |
17 | MyStoreProject
18 |
19 |
20 | MyStoreProject Report
21 |
23 | ]]>
24 |
25 |
26 |
27 |
28 |
29 | bottom
30 |
31 |
32 |
33 |
38 |
39 |
40 |
41 |
42 | img { float:
44 | left;height: 90%;margin-left: 30px;margin-top: 3px;width: auto; }
45 | ]]>
46 |
47 |
48 |
--------------------------------------------------------------------------------
/MyStoreProject/src/main/java/com/mystore/pageobjects/IndexPage.java:
--------------------------------------------------------------------------------
1 | package com.mystore.pageobjects;
2 |
3 | import org.openqa.selenium.WebElement;
4 | import org.openqa.selenium.support.FindBy;
5 | import org.openqa.selenium.support.PageFactory;
6 |
7 | import com.mystore.actiondriver.Action;
8 | import com.mystore.base.BaseClass;
9 |
10 | public class IndexPage extends BaseClass {
11 |
12 | Action action= new Action();
13 |
14 | @FindBy(xpath = "//a[@class='login']")
15 | private WebElement signInBtn;
16 |
17 | @FindBy(xpath = "//img[@class='logo img-responsive']")
18 | private WebElement myStoreLogo;
19 |
20 | @FindBy(id="search_query_top")
21 | private WebElement searchProductBox;
22 |
23 | @FindBy(name="submit_search")
24 | private WebElement searchButton;
25 |
26 | public IndexPage() {
27 | PageFactory.initElements(getDriver(), this);
28 | }
29 |
30 | public LoginPage clickOnSignIn() throws Throwable {
31 | action.fluentWait(getDriver(), signInBtn, 10);
32 | action.click(getDriver(), signInBtn);
33 | return new LoginPage();
34 | }
35 |
36 | public boolean validateLogo() throws Throwable {
37 | return action.isDisplayed(getDriver(), myStoreLogo);
38 | }
39 |
40 | public String getMyStoreTitle() {
41 | String myStoreTitel=getDriver().getTitle();
42 | return myStoreTitel;
43 | }
44 |
45 | public SearchResultPage searchProduct(String productName) throws Throwable {
46 | action.type(searchProductBox, productName);
47 | action.scrollByVisibilityOfElement(getDriver(), searchButton);
48 | action.click(getDriver(), searchButton);
49 | Thread.sleep(3000);
50 | return new SearchResultPage();
51 | }
52 |
53 |
54 |
55 | }
56 |
--------------------------------------------------------------------------------
/MyStoreProject/test-output/old/Suite/testng.xml.html:
--------------------------------------------------------------------------------
1 | testng.xml for Suite <?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE suite SYSTEM "https://testng.org/testng-1.0.dtd">
<suite guice-stage="DEVELOPMENT" name="Suite">
<listeners>
<listener class-name="com.mystore.utility.ListenerClass"/>
</listeners>
<test thread-count="5" name="Test_All">
<parameter name="browser" value="Chrome"/>
<classes>
<class name="com.mystore.testcases.AccountCreationPageTest"/>
<class name="com.mystore.testcases.AddToCartPageTest"/>
<class name="com.mystore.testcases.HomePageTest"/>
<class name="com.mystore.testcases.OrderPageTest"/>
<class name="com.mystore.testcases.SearchResultPageTest"/>
<class name="com.mystore.testcases.LoginPageTest"/>
<class name="com.mystore.testcases.IndexPageTest"/>
<class name="com.mystore.testcases.EndToEndTest"/>
</classes>
</test> <!-- Test_All -->
</suite> <!-- Suite -->
--------------------------------------------------------------------------------
/MyStoreProject/test-output/old/CrossBrowser/testng.xml.html:
--------------------------------------------------------------------------------
1 | testng.xml for CrossBrowser <?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE suite SYSTEM "https://testng.org/testng-1.0.dtd">
<suite thread-count="6" guice-stage="DEVELOPMENT" name="CrossBrowser" parallel="tests">
<test thread-count="6" name="ChromeTest" parallel="tests">
<parameter name="browser" value="Chrome"/>
<classes>
<class name="com.mystore.testcases.IndexPageTest"/>
</classes>
</test> <!-- ChromeTest -->
<test thread-count="6" name="FirefoxTest" parallel="tests">
<parameter name="browser" value="Firefox"/>
<classes>
<class name="com.mystore.testcases.IndexPageTest"/>
</classes>
</test> <!-- FirefoxTest -->
<test thread-count="6" name="IETest" parallel="tests">
<parameter name="browser" value="IE"/>
<classes>
<class name="com.mystore.testcases.IndexPageTest"/>
</classes>
</test> <!-- IETest -->
</suite> <!-- CrossBrowser -->
--------------------------------------------------------------------------------
/MyStoreProject/src/test/java/com/mystore/testcases/AddToCartPageTest.java:
--------------------------------------------------------------------------------
1 | /**
2 | *
3 | */
4 | package com.mystore.testcases;
5 |
6 | import org.testng.Assert;
7 | import org.testng.annotations.AfterMethod;
8 | import org.testng.annotations.BeforeMethod;
9 | import org.testng.annotations.Parameters;
10 | import org.testng.annotations.Test;
11 |
12 | import com.mystore.base.BaseClass;
13 | import com.mystore.dataprovider.DataProviders;
14 | import com.mystore.pageobjects.AddToCartPage;
15 | import com.mystore.pageobjects.IndexPage;
16 | import com.mystore.pageobjects.SearchResultPage;
17 | import com.mystore.utility.Log;
18 |
19 | /**
20 | * @author Hitendra
21 | *
22 | */
23 | public class AddToCartPageTest extends BaseClass {
24 |
25 | private IndexPage index;
26 | private SearchResultPage searchResultPage;
27 | private AddToCartPage addToCartPage;
28 |
29 | @Parameters("browser")
30 | @BeforeMethod(groups = {"Smoke","Sanity","Regression"})
31 | public void setup(String browser) {
32 | launchApp(browser);
33 | }
34 |
35 | @AfterMethod(groups = {"Smoke","Sanity","Regression"})
36 | public void tearDown() {
37 | getDriver().quit();
38 | }
39 |
40 | @Test(groups = {"Regression","Sanity"}, dataProvider = "getProduct", dataProviderClass = DataProviders.class)
41 | public void addToCartTest(String productName, String qty, String size) throws Throwable {
42 | Log.startTestCase("addToCartTest");
43 | index= new IndexPage();
44 | searchResultPage=index.searchProduct(productName);
45 | addToCartPage=searchResultPage.clickOnProduct();
46 | addToCartPage.enterQuantity(qty);
47 | addToCartPage.selectSize(size);
48 | addToCartPage.clickOnAddToCart();
49 | boolean result=addToCartPage.validateAddtoCart();
50 | Assert.assertTrue(result);
51 | Log.endTestCase("addToCartTest");
52 |
53 | }
54 | }
55 |
--------------------------------------------------------------------------------
/MyStoreProject/src/main/java/com/mystore/pageobjects/AddToCartPage.java:
--------------------------------------------------------------------------------
1 | /**
2 | *
3 | */
4 | package com.mystore.pageobjects;
5 |
6 | import org.openqa.selenium.WebElement;
7 | import org.openqa.selenium.support.FindBy;
8 | import org.openqa.selenium.support.PageFactory;
9 |
10 | import com.mystore.actiondriver.Action;
11 | import com.mystore.base.BaseClass;
12 |
13 | /**
14 | * @author Hitendra
15 | *
16 | */
17 | public class AddToCartPage extends BaseClass {
18 |
19 | Action action= new Action();
20 |
21 | @FindBy(id="quantity_wanted")
22 | private WebElement quantity;
23 |
24 | @FindBy(name="group_1")
25 | private WebElement size;
26 |
27 | @FindBy(xpath="//span[text()='Add to cart']")
28 | private WebElement addToCartBtn;
29 |
30 | @FindBy(xpath="//*[@id=\"layer_cart\"]//h2/i")
31 | private WebElement addToCartMessag;
32 |
33 | @FindBy(xpath="//span[contains(text(),'Proceed to checkout')]")
34 | private WebElement proceedToCheckOutBtn;
35 |
36 | public AddToCartPage() {
37 | PageFactory.initElements(getDriver(), this);
38 | }
39 |
40 | public void enterQuantity(String quantity1) throws Throwable {
41 | action.type(quantity, quantity1);
42 | }
43 |
44 | public void selectSize(String size1) throws Throwable {
45 | action.selectByVisibleText(size1, size);
46 | }
47 |
48 | public void clickOnAddToCart() throws Throwable {
49 | action.click(getDriver(), addToCartBtn);
50 | }
51 |
52 | public boolean validateAddtoCart() throws Throwable {
53 | action.fluentWait(getDriver(), addToCartMessag, 10);
54 | return action.isDisplayed(getDriver(), addToCartMessag);
55 | }
56 |
57 | public OrderPage clickOnCheckOut() throws Throwable {
58 | action.fluentWait(getDriver(), proceedToCheckOutBtn, 10);
59 | action.JSClick(getDriver(), proceedToCheckOutBtn);
60 | return new OrderPage();
61 | }
62 |
63 | }
64 |
--------------------------------------------------------------------------------
/MyStoreProject/test-output/old/Suite/groups.html:
--------------------------------------------------------------------------------
1 | Groups used for this test run
2 | Group name Methods Regression AddToCartPageTest.addToCartTest(java.lang.String, java.lang.String, java.lang.String)[pri:0, instance:com.mystore.testcases.AddToCartPageTest@33c7e1bb] OrderPageTest.verifyTotalPrice(java.lang.String, java.lang.String, java.lang.String)[pri:0, instance:com.mystore.testcases.OrderPageTest@52feb982] EndToEndTest.endToEndTest(java.lang.String, java.lang.String, java.lang.String)[pri:0, instance:com.mystore.testcases.EndToEndTest@3043fe0e]
3 | Sanity LoginPageTest.loginTest(java.lang.String, java.lang.String)[pri:0, instance:com.mystore.testcases.LoginPageTest@76b0bfab] AddToCartPageTest.addToCartTest(java.lang.String, java.lang.String, java.lang.String)[pri:0, instance:com.mystore.testcases.AddToCartPageTest@33c7e1bb] AccountCreationPageTest.verifyCreateAccountPageTest(java.lang.String)[pri:0, instance:com.mystore.testcases.AccountCreationPageTest@30a3107a]
4 | Smoke HomePageTest.wishListTest(java.lang.String, java.lang.String)[pri:0, instance:com.mystore.testcases.HomePageTest@34c4973] LoginPageTest.loginTest(java.lang.String, java.lang.String)[pri:0, instance:com.mystore.testcases.LoginPageTest@76b0bfab] IndexPageTest.verifyLogo()[pri:0, instance:com.mystore.testcases.IndexPageTest@17d677df] IndexPageTest.verifyTitle()[pri:0, instance:com.mystore.testcases.IndexPageTest@17d677df] SearchResultPageTest.productAvailabilityTest(java.lang.String)[pri:0, instance:com.mystore.testcases.SearchResultPageTest@7a765367] HomePageTest.orderHistoryandDetailsTest(java.lang.String, java.lang.String)[pri:0, instance:com.mystore.testcases.HomePageTest@34c4973]
5 |
6 |
--------------------------------------------------------------------------------
/MyStoreProject/Documentation/Steps for Log4j,Extent,DataProvider.txt:
--------------------------------------------------------------------------------
1 |
2 | 1. Log4j
3 | ================================================================================
4 |
5 | -->Add/Create Log4j.xml in project directory
6 |
7 | -->Add/Create Log Class in utility Package
8 |
9 | -->Configure @BeforeSuite at BaseClass to configure log4j.xml
10 | DOMConfigurator.configure("log4j.xml");
11 |
12 | -->Need to just Call in methods in testCase from Log class
13 |
14 |
15 |
16 |
17 | 2. DataDriven Testing and DataProvider
18 | ================================================================================
19 |
20 | -->Add/Create ExcelLibrary in utility package.
21 |
22 | -->Create a Folder and add TestData.xlxs in that.
23 |
24 | -->Create a package for DataProvider and add DataProvider class there
25 | and create the object of ExcelLibrary Class
26 |
27 | -->Add the DataProvider methods
28 |
29 | -->Call the DataProvider methods from testcases
30 |
31 |
32 |
33 | 3. Extent Report
34 | ================================================================================
35 |
36 | -->Add/Create extent-config.xml file for Extent Report Configuration
37 |
38 | -->Add/Create ExtentManager Class in utility Package-- to create the object
39 | of ExtentHtmlReporter and load extent-config.xml
40 |
41 | -->Create a folder ro Save Extent Report under test-output
42 |
43 | -->Configure ExtentManager.setExtent() in @BeforeSuite method in BaseClass
44 |
45 | -->Configure ExtentManager.endReport() in @AfterSuite method in BaseClass
46 |
47 | -->Add/Create screenShot method in Action/BaseClass
48 |
49 | To attach the screenshot in extent report
50 | -->Add/Create a Listener Class -- ListenerClass
51 |
52 | -->To call the listener Add the below listener (inside suite tag)
53 | setting in testng.xml
54 |
55 |
56 |
57 |
58 |
59 |
60 |
61 |
62 |
63 |
64 |
65 |
66 |
67 |
68 |
69 |
70 |
71 |
72 |
73 |
74 |
75 |
76 |
--------------------------------------------------------------------------------
/MyStoreProject/src/main/java/com/mystore/pageobjects/LoginPage.java:
--------------------------------------------------------------------------------
1 | /**
2 | *
3 | */
4 | package com.mystore.pageobjects;
5 |
6 | import org.openqa.selenium.WebElement;
7 | import org.openqa.selenium.support.FindBy;
8 | import org.openqa.selenium.support.PageFactory;
9 |
10 | import com.mystore.actiondriver.Action;
11 | import com.mystore.base.BaseClass;
12 |
13 | /**
14 | * @author Hitendra
15 | *
16 | */
17 | public class LoginPage extends BaseClass {
18 |
19 | Action action= new Action();
20 |
21 | @FindBy(id="email")
22 | private WebElement userName;
23 |
24 | @FindBy(id="passwd")
25 | private WebElement password;
26 |
27 | @FindBy(id="SubmitLogin")
28 | private WebElement signInBtn;
29 |
30 | @FindBy(name="email_create")
31 | private WebElement emailForNewAccount;
32 |
33 | @FindBy(name="SubmitCreate")
34 | private WebElement createNewAccountBtn;
35 |
36 | public LoginPage() {
37 | PageFactory.initElements(getDriver(), this);
38 | }
39 |
40 | public HomePage login(String uname, String pswd,HomePage homePage) throws Throwable {
41 | action.scrollByVisibilityOfElement(getDriver(), userName);
42 | action.type(userName, uname);
43 | action.type(password, pswd);
44 | action.JSClick(getDriver(), signInBtn);
45 | Thread.sleep(2000);
46 | homePage=new HomePage();
47 | return homePage;
48 | }
49 |
50 | public AddressPage login(String uname, String pswd,AddressPage addressPage) throws Throwable {
51 | action.scrollByVisibilityOfElement(getDriver(), userName);
52 | action.type(userName, uname);
53 | action.type(password, pswd);
54 | action.click(getDriver(), signInBtn);
55 | Thread.sleep(2000);
56 | addressPage=new AddressPage();
57 | return addressPage;
58 | }
59 |
60 | public AccountCreationPage createNewAccount(String newEmail) throws Throwable {
61 | action.type(emailForNewAccount, newEmail);
62 | action.click(getDriver(), createNewAccountBtn);
63 | return new AccountCreationPage();
64 | }
65 |
66 | }
67 |
68 |
69 |
70 |
71 |
72 |
73 |
--------------------------------------------------------------------------------
/MyStoreProject/src/test/java/com/mystore/testcases/LoginPageTest.java:
--------------------------------------------------------------------------------
1 | /**
2 | *
3 | */
4 | package com.mystore.testcases;
5 | import org.testng.Assert;
6 | import org.testng.annotations.AfterMethod;
7 | import org.testng.annotations.BeforeMethod;
8 | import org.testng.annotations.DataProvider;
9 | import org.testng.annotations.Parameters;
10 | import org.testng.annotations.Test;
11 |
12 | import com.mystore.base.BaseClass;
13 | import com.mystore.dataprovider.DataProviders;
14 | import com.mystore.pageobjects.HomePage;
15 | import com.mystore.pageobjects.IndexPage;
16 | import com.mystore.pageobjects.LoginPage;
17 | import com.mystore.utility.Log;
18 |
19 | /**
20 | * @author Hitendra
21 | *
22 | */
23 | public class LoginPageTest extends BaseClass {
24 | private IndexPage indexPage;
25 | private LoginPage loginPage;
26 | private HomePage homePage;
27 |
28 | @Parameters("browser")
29 | @BeforeMethod(groups = {"Smoke","Sanity","Regression"})
30 | public void setup(String browser) {
31 | launchApp(browser);
32 | }
33 |
34 | @AfterMethod(groups = {"Smoke","Sanity","Regression"})
35 | public void tearDown() {
36 | getDriver().quit();
37 | }
38 | @Test(groups = {"Smoke","Sanity"},dataProvider = "credentials", dataProviderClass = DataProviders.class)
39 | public void loginTest(String uname, String pswd) throws Throwable {
40 | Log.startTestCase("loginTest");
41 | indexPage= new IndexPage();
42 | Log.info("user is going to click on SignIn");
43 | loginPage=indexPage.clickOnSignIn();
44 | Log.info("Enter Username and Password");
45 | //homePage=loginPage.login(prop.getProperty("username"), prop.getProperty("password"));
46 | homePage=loginPage.login(uname,pswd,homePage);
47 | String actualURL=homePage.getCurrURL();
48 | String expectedURL="http://automationpractice.com/index.php?controller=my-account";
49 | Log.info("Verifying if user is able to login");
50 | Assert.assertEquals(actualURL, expectedURL);
51 | Log.info("Login is Sucess");
52 | Log.endTestCase("loginTest");
53 | }
54 |
55 | }
56 |
--------------------------------------------------------------------------------
/MyStoreProject/src/test/java/com/mystore/testcases/OrderPageTest.java:
--------------------------------------------------------------------------------
1 | /**
2 | *
3 | */
4 | package com.mystore.testcases;
5 |
6 | import org.testng.Assert;
7 | import org.testng.annotations.AfterMethod;
8 | import org.testng.annotations.BeforeMethod;
9 | import org.testng.annotations.Parameters;
10 | import org.testng.annotations.Test;
11 |
12 | import com.mystore.base.BaseClass;
13 | import com.mystore.dataprovider.DataProviders;
14 | import com.mystore.pageobjects.AddToCartPage;
15 | import com.mystore.pageobjects.IndexPage;
16 | import com.mystore.pageobjects.OrderPage;
17 | import com.mystore.pageobjects.SearchResultPage;
18 | import com.mystore.utility.Log;
19 |
20 | /**
21 | * @author Hitendra
22 | *
23 | */
24 | public class OrderPageTest extends BaseClass {
25 |
26 | private IndexPage index;
27 | private SearchResultPage searchResultPage;
28 | private AddToCartPage addToCartPage;
29 | private OrderPage orderPage;
30 |
31 | @Parameters("browser")
32 | @BeforeMethod(groups = {"Smoke","Sanity","Regression"})
33 | public void setup(String browser) {
34 | launchApp(browser);
35 | }
36 |
37 | @AfterMethod(groups = {"Smoke","Sanity","Regression"})
38 | public void tearDown() {
39 | getDriver().quit();
40 | }
41 |
42 | @Test(groups = "Regression",dataProvider = "getProduct", dataProviderClass = DataProviders.class)
43 | public void verifyTotalPrice(String productName, String qty, String size) throws Throwable {
44 | Log.startTestCase("verifyTotalPrice");
45 | index= new IndexPage();
46 | searchResultPage=index.searchProduct(productName);
47 | addToCartPage=searchResultPage.clickOnProduct();
48 | addToCartPage.enterQuantity(qty);
49 | addToCartPage.selectSize(size);
50 | addToCartPage.clickOnAddToCart();
51 | orderPage=addToCartPage.clickOnCheckOut();
52 | Double unitPrice=orderPage.getUnitPrice();
53 | Double totalPrice=orderPage.getTotalPrice();
54 | Double totalExpectedPrice=(unitPrice*(Double.parseDouble(qty)))+2;
55 | Assert.assertEquals(totalPrice, totalExpectedPrice);
56 | Log.endTestCase("verifyTotalPrice");
57 | }
58 | }
59 |
--------------------------------------------------------------------------------
/MyStoreProject/src/test/java/com/mystore/testcases/HomePageTest.java:
--------------------------------------------------------------------------------
1 | /**
2 | *
3 | */
4 | package com.mystore.testcases;
5 |
6 | import org.testng.Assert;
7 | import org.testng.annotations.AfterMethod;
8 | import org.testng.annotations.BeforeMethod;
9 | import org.testng.annotations.Parameters;
10 | import org.testng.annotations.Test;
11 |
12 | import com.mystore.base.BaseClass;
13 | import com.mystore.dataprovider.DataProviders;
14 | import com.mystore.pageobjects.HomePage;
15 | import com.mystore.pageobjects.IndexPage;
16 | import com.mystore.pageobjects.LoginPage;
17 | import com.mystore.utility.Log;
18 |
19 | /**
20 | * @author Hitendra
21 | *
22 | */
23 | public class HomePageTest extends BaseClass {
24 | private IndexPage indexPage;
25 | private LoginPage loginPage;
26 | private HomePage homePage;
27 |
28 | @Parameters("browser")
29 | @BeforeMethod(groups = {"Smoke","Sanity","Regression"})
30 | public void setup(String browser) {
31 | launchApp(browser);
32 | }
33 |
34 | @AfterMethod(groups = {"Smoke","Sanity","Regression"})
35 | public void tearDown() {
36 | getDriver().quit();
37 | }
38 |
39 | @Test(groups = "Smoke",dataProvider = "credentials", dataProviderClass = DataProviders.class)
40 | public void wishListTest(String uname, String pswd) throws Throwable {
41 | Log.startTestCase("wishListTest");
42 | indexPage= new IndexPage();
43 | loginPage=indexPage.clickOnSignIn();
44 | homePage=loginPage.login(uname,pswd,homePage);
45 | boolean result=homePage.validateMyWishList();
46 | Assert.assertTrue(result);
47 | Log.endTestCase("wishListTest");
48 | }
49 |
50 | @Test(groups = "Smoke",dataProvider = "credentials", dataProviderClass = DataProviders.class)
51 | public void orderHistoryandDetailsTest(String uname, String pswd) throws Throwable {
52 | Log.startTestCase("orderHistoryandDetailsTest");
53 | indexPage= new IndexPage();
54 | loginPage=indexPage.clickOnSignIn();
55 | homePage=loginPage.login(uname,pswd,homePage);
56 | boolean result=homePage.validateOrderHistory();
57 | Assert.assertTrue(result);
58 | Log.endTestCase("orderHistoryandDetailsTest");
59 | }
60 |
61 | }
62 |
--------------------------------------------------------------------------------
/MyStoreProject/src/main/java/com/mystore/utility/ListenerClass.java:
--------------------------------------------------------------------------------
1 | package com.mystore.utility;
2 |
3 | import java.io.File;
4 | import java.io.IOException;
5 | import org.apache.commons.io.FileUtils;
6 | import org.testng.ITestContext;
7 | import org.testng.ITestListener;
8 | import org.testng.ITestResult;
9 | import com.aventstack.extentreports.MediaEntityBuilder;
10 | import com.aventstack.extentreports.Status;
11 | import com.aventstack.extentreports.markuputils.ExtentColor;
12 | import com.aventstack.extentreports.markuputils.MarkupHelper;
13 | import com.mystore.actiondriver.Action;
14 | import com.mystore.base.BaseClass;
15 |
16 |
17 | public class ListenerClass extends ExtentManager implements ITestListener {
18 |
19 | Action action= new Action();
20 |
21 | public void onTestStart(ITestResult result) {
22 | test = extent.createTest(result.getName());
23 | }
24 |
25 | public void onTestSuccess(ITestResult result) {
26 | if (result.getStatus() == ITestResult.SUCCESS) {
27 | test.log(Status.PASS, "Pass Test case is: " + result.getName());
28 | }
29 | }
30 |
31 | public void onTestFailure(ITestResult result) {
32 | if (result.getStatus() == ITestResult.FAILURE) {
33 | try {
34 | test.log(Status.FAIL,
35 | MarkupHelper.createLabel(result.getName() + " - Test Case Failed", ExtentColor.RED));
36 | test.log(Status.FAIL,
37 | MarkupHelper.createLabel(result.getThrowable() + " - Test Case Failed", ExtentColor.RED));
38 | String imgPath = action.screenShot(BaseClass.getDriver(), result.getName());
39 |
40 | test.fail("ScreenShot is Attached", MediaEntityBuilder.createScreenCaptureFromPath(imgPath).build());
41 |
42 | } catch (IOException e) {
43 | // TODO Auto-generated catch block
44 | e.printStackTrace();
45 | }
46 | }
47 | }
48 |
49 | public void onTestSkipped(ITestResult result) {
50 | if (result.getStatus() == ITestResult.SKIP) {
51 | test.log(Status.SKIP, "Skipped Test case is: " + result.getName());
52 | }
53 | }
54 |
55 | public void onTestFailedButWithinSuccessPercentage(ITestResult result) {
56 | // TODO Auto-generated method stub
57 | }
58 |
59 | public void onStart(ITestContext context) {
60 | // TODO Auto-generated method stub
61 |
62 | }
63 |
64 | public void onFinish(ITestContext context) {
65 | // TODO Auto-generated method stub
66 | }
67 | }
68 |
--------------------------------------------------------------------------------
/MyStoreProject/test-output/Suite/Test.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
--------------------------------------------------------------------------------
/MyStoreProject/test-output/CrossBrowser/ChromeTest.html:
--------------------------------------------------------------------------------
1 |
2 |
3 | TestNG: ChromeTest
4 |
5 |
6 |
7 |
11 |
53 |
54 |
55 |
56 | ChromeTest
57 |
58 | Tests passed/Failed/Skipped: 2/0/0
59 |
60 | Started on: Fri Jul 17 19:11:37 IST 2020
61 |
62 | Total time: 30 seconds (30370 ms)
63 |
64 | Included groups:
65 |
66 | Excluded groups:
67 |
68 |
69 | (Hover the method name to see the test class name)
70 |
71 | PASSED TESTS
72 | Test method
73 | Exception
74 | Time (seconds)
75 | Instance
76 |
77 |
78 | verifyLogo Test class: com.mystore.testcases.IndexPageTest
79 |
80 | 0
81 | com.mystore.testcases.IndexPageTest@2781e022
82 |
83 | verifyTitle Test class: com.mystore.testcases.IndexPageTest
84 |
85 | 0
86 | com.mystore.testcases.IndexPageTest@2781e022
87 |
88 |
89 |
--------------------------------------------------------------------------------
/MyStoreProject/test-output/Default suite/Default test.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
7 |
35 |
36 |
37 |
38 |
--------------------------------------------------------------------------------
/MyStoreProject/pom.xml:
--------------------------------------------------------------------------------
1 |
4 | 4.0.0
5 | MyStoreProject
6 | MyStoreProject
7 | 0.0.1-SNAPSHOT
8 |
9 |
10 | org.seleniumhq.selenium
11 | selenium-java
12 | 3.141.59
13 |
14 |
15 |
16 | org.testng
17 | testng
18 | 7.1.0
19 | compile
20 |
21 |
22 |
23 | org.apache.poi
24 | poi
25 | 4.1.2
26 |
27 |
28 | org.apache.poi
29 | poi-ooxml
30 | 4.1.2
31 |
32 |
33 | com.aventstack
34 | extentreports
35 | 4.0.9
36 |
37 |
38 | commons-io
39 | commons-io
40 | 2.6
41 |
42 |
43 | log4j
44 | log4j
45 | 1.2.17
46 |
47 |
48 | io.github.bonigarcia
49 | webdrivermanager
50 | 4.0.0
51 |
52 |
53 |
54 |
55 |
56 |
57 | org.apache.maven.plugins
58 | maven-compiler-plugin
59 | 3.8.1
60 |
61 | 1.8
62 | 1.8
63 |
64 |
65 |
66 |
67 | org.apache.maven.plugins
68 | maven-release-plugin
69 | 3.0.0-M1
70 |
71 |
72 |
73 | org.codehaus.mojo
74 | exec-maven-plugin
75 | 1.6.0
76 |
77 |
78 | org.apache.maven.plugins
79 | maven-surefire-plugin
80 | 3.0.0-M4
81 |
82 |
83 | ${xmlFiles}
84 |
85 |
86 | ${url}
87 |
88 |
89 |
90 |
91 |
92 |
93 |
94 |
--------------------------------------------------------------------------------
/MyStoreProject/src/test/java/com/mystore/testcases/AccountCreationPageTest.java:
--------------------------------------------------------------------------------
1 | package com.mystore.testcases;
2 | import java.util.HashMap;
3 | import org.testng.Assert;
4 | import org.testng.annotations.AfterMethod;
5 | import org.testng.annotations.BeforeMethod;
6 | import org.testng.annotations.Parameters;
7 | import org.testng.annotations.Test;
8 | import com.mystore.base.BaseClass;
9 | import com.mystore.dataprovider.DataProviders;
10 | import com.mystore.pageobjects.AccountCreationPage;
11 | import com.mystore.pageobjects.HomePage;
12 | import com.mystore.pageobjects.IndexPage;
13 | import com.mystore.pageobjects.LoginPage;
14 | import com.mystore.utility.Log;
15 |
16 | public class AccountCreationPageTest extends BaseClass {
17 | private IndexPage indexPage;
18 | private LoginPage loginPage;
19 | private AccountCreationPage acountCreationPage;
20 | private HomePage homePage;
21 |
22 | @Parameters("browser")
23 | @BeforeMethod(groups = {"Smoke","Sanity","Regression"})
24 | public void setup(String browser) {
25 | launchApp(browser);
26 | }
27 |
28 | @AfterMethod(groups = {"Smoke","Sanity","Regression"})
29 | public void tearDown() {
30 | getDriver().quit();
31 | }
32 |
33 | @Test(groups = "Sanity",dataProvider = "email", dataProviderClass = DataProviders.class)
34 | public void verifyCreateAccountPageTest(String email) throws Throwable {
35 | Log.startTestCase("verifyCreateAccountPageTest");
36 | indexPage= new IndexPage();
37 | loginPage=indexPage.clickOnSignIn();
38 | acountCreationPage=loginPage.createNewAccount(email);
39 | boolean result=acountCreationPage.validateAcountCreatePage();
40 | Assert.assertTrue(result);
41 | Log.endTestCase("verifyCreateAccountPageTest");
42 | }
43 |
44 | @Test(groups = "Regression",dataProvider = "newAcountDetailsData",dataProviderClass = DataProviders.class)
45 | public void createAccountTest(HashMap hashMapValue) throws Throwable {
46 | Log.startTestCase("createAccountTest");
47 | indexPage= new IndexPage();
48 | loginPage=indexPage.clickOnSignIn();
49 | acountCreationPage=loginPage.createNewAccount(hashMapValue.get("Email"));
50 | acountCreationPage.createAccount(
51 | hashMapValue.get("Gender"),
52 | hashMapValue.get("FirstName"),
53 | hashMapValue.get("LastName"),
54 | hashMapValue.get("SetPassword"),
55 | hashMapValue.get("Day"),
56 | hashMapValue.get("Month"),
57 | hashMapValue.get("Year"),
58 | hashMapValue.get("Company"),
59 | hashMapValue.get("Address"),
60 | hashMapValue.get("City"),
61 | hashMapValue.get("State"),
62 | hashMapValue.get("Zipcode"),
63 | hashMapValue.get("Country"),
64 | hashMapValue.get("MobilePhone"));
65 | homePage=acountCreationPage.validateRegistration();
66 | Assert.assertEquals("http://automationpractice.com/index.php?controller=my-account", homePage.getCurrURL());
67 | Log.endTestCase("createAccountTest");
68 | }
69 |
70 | }
71 |
--------------------------------------------------------------------------------
/MyStoreProject/src/main/java/com/mystore/actioninterface/ActionInterface.java:
--------------------------------------------------------------------------------
1 | package com.mystore.actioninterface;
2 |
3 | import org.openqa.selenium.WebDriver;
4 | import org.openqa.selenium.WebElement;
5 |
6 | public interface ActionInterface {
7 |
8 | //Added all user actions abstract methods to achieve Abstraction
9 | public void scrollByVisibilityOfElement(WebDriver driver, WebElement ele);
10 | public void click(WebDriver ldriver, WebElement ele);
11 | public boolean isDisplayed(WebDriver ldriver, WebElement ele);
12 | public boolean type(WebElement ele, String text);
13 | public boolean findElement(WebDriver ldriver, WebElement ele);
14 | public boolean isSelected(WebDriver ldriver, WebElement ele);
15 | public boolean isEnabled(WebDriver ldriver, WebElement ele);
16 | public boolean selectBySendkeys(String value,WebElement ele);
17 | public boolean selectByIndex(WebElement element, int index);
18 | public boolean selectByValue(WebElement element,String value);
19 | public boolean selectByVisibleText(String visibletext, WebElement ele);
20 | public boolean mouseHoverByJavaScript(WebElement locator);
21 | public boolean JSClick(WebDriver driver, WebElement ele);
22 | public boolean switchToFrameByIndex(WebDriver driver,int index);
23 | public boolean switchToFrameById(WebDriver driver,String idValue);
24 | public boolean switchToFrameByName(WebDriver driver,String nameValue);
25 | public boolean switchToDefaultFrame(WebDriver driver);
26 | public void mouseOverElement(WebDriver driver,WebElement element);
27 | public boolean moveToElement(WebDriver driver, WebElement ele);
28 | public boolean mouseover(WebDriver driver, WebElement ele);
29 | public boolean draggable(WebDriver driver,WebElement source, int x, int y);
30 | public boolean draganddrop(WebDriver driver,WebElement source, WebElement target);
31 | public boolean slider(WebDriver driver,WebElement ele, int x, int y);
32 | public boolean rightclick(WebDriver driver,WebElement ele);
33 | public boolean switchWindowByTitle(WebDriver driver,String windowTitle, int count);
34 | public boolean switchToNewWindow(WebDriver driver);
35 | public boolean switchToOldWindow(WebDriver driver);
36 | public int getColumncount(WebElement row);
37 | public int getRowCount(WebElement table);
38 | public boolean Alert(WebDriver driver);
39 | public boolean launchUrl(WebDriver driver,String url);
40 | public boolean isAlertPresent(WebDriver driver);
41 | public String getCurrentURL(WebDriver driver);
42 | public String getTitle(WebDriver driver);
43 | public boolean click1(WebElement locator, String locatorName);
44 | public void fluentWait(WebDriver driver,WebElement element, int timeOut);
45 | public void implicitWait(WebDriver driver, int timeOut);
46 | public void explicitWait(WebDriver driver, WebElement element, int timeOut);
47 | public void pageLoadTimeOut(WebDriver driver, int timeOut);
48 | public String screenShot(WebDriver driver, String filename);
49 | public String getCurrentTime();
50 |
51 | }
52 |
--------------------------------------------------------------------------------
/MyStoreProject/src/test/java/com/mystore/testcases/EndToEndTest.java:
--------------------------------------------------------------------------------
1 | /**
2 | *
3 | */
4 | package com.mystore.testcases;
5 |
6 | import org.testng.Assert;
7 | import org.testng.annotations.AfterMethod;
8 | import org.testng.annotations.BeforeMethod;
9 | import org.testng.annotations.Parameters;
10 | import org.testng.annotations.Test;
11 |
12 | import com.mystore.base.BaseClass;
13 | import com.mystore.dataprovider.DataProviders;
14 | import com.mystore.pageobjects.AddToCartPage;
15 | import com.mystore.pageobjects.AddressPage;
16 | import com.mystore.pageobjects.IndexPage;
17 | import com.mystore.pageobjects.LoginPage;
18 | import com.mystore.pageobjects.OrderConfirmationPage;
19 | import com.mystore.pageobjects.OrderPage;
20 | import com.mystore.pageobjects.OrderSummary;
21 | import com.mystore.pageobjects.PaymentPage;
22 | import com.mystore.pageobjects.SearchResultPage;
23 | import com.mystore.pageobjects.ShippingPage;
24 | import com.mystore.utility.Log;
25 |
26 | /**
27 | * @author Hitendra
28 | *
29 | */
30 | public class EndToEndTest extends BaseClass {
31 |
32 | private IndexPage index;
33 | private SearchResultPage searchResultPage;
34 | private AddToCartPage addToCartPage;
35 | private OrderPage orderPage;
36 | private LoginPage loginPage;
37 | private AddressPage addressPage;
38 | private ShippingPage shippingPage;
39 | private PaymentPage paymentPage;
40 | private OrderSummary orderSummary;
41 | private OrderConfirmationPage orderConfirmationPage;
42 |
43 | @Parameters("browser")
44 | @BeforeMethod(groups = {"Smoke","Sanity","Regression"})
45 | public void setup(String browser) {
46 | launchApp(browser);
47 | }
48 |
49 | @AfterMethod(groups = {"Smoke","Sanity","Regression"})
50 | public void tearDown() {
51 | getDriver().quit();
52 | }
53 |
54 | @Test(groups = "Regression",dataProvider = "getProduct", dataProviderClass = DataProviders.class)
55 | public void endToEndTest(String productName, String qty, String size) throws Throwable {
56 | Log.startTestCase("endToEndTest");
57 | index= new IndexPage();
58 | searchResultPage=index.searchProduct(productName);
59 | addToCartPage=searchResultPage.clickOnProduct();
60 | addToCartPage.enterQuantity(qty);
61 | addToCartPage.selectSize(size);
62 | addToCartPage.clickOnAddToCart();
63 | orderPage=addToCartPage.clickOnCheckOut();
64 | loginPage=orderPage.clickOnCheckOut();
65 | addressPage=loginPage.login(prop.getProperty("username"), prop.getProperty("password"),addressPage);
66 | shippingPage=addressPage.clickOnCheckOut();
67 | shippingPage.checkTheTerms();
68 | paymentPage=shippingPage.clickOnProceedToCheckOut();
69 | orderSummary=paymentPage.clickOnPaymentMethod();
70 | orderConfirmationPage=orderSummary.clickOnconfirmOrderBtn();
71 | String actualMessage=orderConfirmationPage.validateConfirmMessage();
72 | String expectedMsg="Your order on My Store is complete.";
73 | Assert.assertEquals(actualMessage, expectedMsg);
74 | Log.endTestCase("endToEndTest");
75 | }
76 |
77 | }
78 |
--------------------------------------------------------------------------------
/MyStoreProject/test-output/Suite/Regression.html:
--------------------------------------------------------------------------------
1 |
2 |
3 | TestNG: Regression
4 |
5 |
6 |
7 |
11 |
53 |
54 |
55 |
56 | Regression
57 |
58 | Tests passed/Failed/Skipped: 3/0/0
59 |
60 | Started on: Fri Jul 17 19:13:25 IST 2020
61 |
62 | Total time: 105 seconds (105700 ms)
63 |
64 | Included groups: Regression
65 |
66 | Excluded groups:
67 |
68 |
69 | (Hover the method name to see the test class name)
70 |
71 | PASSED TESTS
72 | Test method
73 | Exception
74 | Time (seconds)
75 | Instance
76 |
77 |
78 | addToCartTest Test class: com.mystore.testcases.AddToCartPageTest Parameters: t-shirt, 2.0, M
79 |
80 | 12
81 | com.mystore.testcases.AddToCartPageTest@3043fe0e
82 |
83 | endToEndTest Test class: com.mystore.testcases.EndToEndTest Parameters: t-shirt, 2.0, M
84 |
85 | 33
86 | com.mystore.testcases.EndToEndTest@78e67e0a
87 |
88 | verifyTotalPrice Test class: com.mystore.testcases.OrderPageTest Parameters: t-shirt, 2.0, M
89 |
90 | 16
91 | com.mystore.testcases.OrderPageTest@17d677df
92 |
93 |
94 |
--------------------------------------------------------------------------------
/MyStoreProject/test-output/Suite/Sanity.html:
--------------------------------------------------------------------------------
1 |
2 |
3 | TestNG: Sanity
4 |
5 |
6 |
7 |
11 |
53 |
54 |
55 |
56 | Sanity
57 |
58 | Tests passed/Failed/Skipped: 3/0/0
59 |
60 | Started on: Fri Jul 17 19:15:37 IST 2020
61 |
62 | Total time: 68 seconds (68093 ms)
63 |
64 | Included groups: Sanity
65 |
66 | Excluded groups:
67 |
68 |
69 | (Hover the method name to see the test class name)
70 |
71 | PASSED TESTS
72 | Test method
73 | Exception
74 | Time (seconds)
75 | Instance
76 |
77 |
78 | addToCartTest Test class: com.mystore.testcases.AddToCartPageTest Parameters: t-shirt, 2.0, M
79 |
80 | 9
81 | com.mystore.testcases.AddToCartPageTest@3043fe0e
82 |
83 | loginTest Test class: com.mystore.testcases.LoginPageTest Parameters: admin@xyz.com, admin@123
84 |
85 | 9
86 | com.mystore.testcases.LoginPageTest@17d677df
87 |
88 | verifyCreateAccountPageTest Test class: com.mystore.testcases.AccountCreationPageTest Parameters: ghfsdtyfg@gmail.com
89 |
90 | 7
91 | com.mystore.testcases.AccountCreationPageTest@78e67e0a
92 |
93 |
94 |
--------------------------------------------------------------------------------
/MyStoreProject/test-output/junitreports/TEST-com.mystore.testcases.HomePageTest.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
43 |
44 |
45 |
46 |
47 |
--------------------------------------------------------------------------------
/MyStoreProject/test-output/CrossBrowser/FirefoxTest.html:
--------------------------------------------------------------------------------
1 |
2 |
3 | TestNG: FirefoxTest
4 |
5 |
6 |
7 |
11 |
53 |
54 |
55 |
56 | FirefoxTest
57 |
58 | Tests passed/Failed/Skipped: 2/0/0
59 |
60 | Started on: Fri Jul 17 19:11:37 IST 2020
61 |
62 | Total time: 38 seconds (38380 ms)
63 |
64 | Included groups:
65 |
66 | Excluded groups:
67 |
68 |
69 | (Hover the method name to see the test class name)
70 |
71 | PASSED TESTS
72 | Test method
73 | Exception
74 | Time (seconds)
75 | Instance
76 |
77 |
78 | verifyLogo Test class: com.mystore.testcases.IndexPageTest
79 |
80 | 0
81 | com.mystore.testcases.IndexPageTest@2781e022
82 |
83 | verifyLogo Test class: com.mystore.testcases.IndexPageTest
84 |
85 | 0
86 | com.mystore.testcases.IndexPageTest@51e2adc7
87 |
88 | verifyTitle Test class: com.mystore.testcases.IndexPageTest
89 |
90 | 0
91 | com.mystore.testcases.IndexPageTest@2781e022
92 |
93 | verifyTitle Test class: com.mystore.testcases.IndexPageTest
94 |
95 | 0
96 | com.mystore.testcases.IndexPageTest@51e2adc7
97 |
98 |
99 |
--------------------------------------------------------------------------------
/MyStoreProject/test-output/junitreports/TEST-com.mystore.testcases.IndexPageTest.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
44 |
45 |
46 |
47 |
48 |
--------------------------------------------------------------------------------
/MyStoreProject/src/main/java/com/mystore/base/BaseClass.java:
--------------------------------------------------------------------------------
1 | package com.mystore.base;
2 |
3 | import java.io.FileInputStream;
4 | import java.io.FileNotFoundException;
5 | import java.io.IOException;
6 | import java.util.Properties;
7 | import java.util.concurrent.TimeUnit;
8 |
9 | import org.apache.log4j.xml.DOMConfigurator;
10 | import org.ietf.jgss.Oid;
11 | import org.openqa.selenium.WebDriver;
12 | import org.openqa.selenium.chrome.ChromeDriver;
13 | import org.openqa.selenium.firefox.FirefoxDriver;
14 | import org.openqa.selenium.ie.InternetExplorerDriver;
15 | import org.openqa.selenium.remote.RemoteWebDriver;
16 | import org.testng.annotations.AfterSuite;
17 | import org.testng.annotations.BeforeSuite;
18 | import org.testng.annotations.BeforeTest;
19 | import org.testng.annotations.Parameters;
20 |
21 | import com.beust.jcommander.Parameter;
22 | import com.mystore.actiondriver.Action;
23 | import com.mystore.utility.ExtentManager;
24 |
25 | import io.github.bonigarcia.wdm.WebDriverManager;
26 | /**
27 | * @author Hitendra: BaseClass is used to load the config file and Initialize
28 | * WebDriver
29 | *
30 | */
31 | public class BaseClass {
32 | public static Properties prop;
33 |
34 | // Declare ThreadLocal Driver
35 | public static ThreadLocal driver = new ThreadLocal<>();
36 |
37 | //loadConfig method is to load the configuration
38 | @BeforeSuite(groups = { "Smoke", "Sanity", "Regression" })
39 | public void loadConfig() {
40 | ExtentManager.setExtent();
41 | DOMConfigurator.configure("log4j.xml");
42 |
43 | try {
44 | prop = new Properties();
45 | FileInputStream ip = new FileInputStream(
46 | System.getProperty("user.dir") + "\\Configuration\\config.properties");
47 | prop.load(ip);
48 |
49 | } catch (FileNotFoundException e) {
50 | e.printStackTrace();
51 | } catch (IOException e) {
52 | e.printStackTrace();
53 | }
54 | }
55 |
56 | public static WebDriver getDriver() {
57 | // Get Driver from threadLocalmap
58 | return driver.get();
59 | }
60 |
61 | public void launchApp(String browserName) {
62 | // String browserName = prop.getProperty("browser");
63 | if (browserName.equalsIgnoreCase("Chrome")) {
64 | WebDriverManager.chromedriver().setup();
65 | // Set Browser to ThreadLocalMap
66 | driver.set(new ChromeDriver());
67 | } else if (browserName.equalsIgnoreCase("FireFox")) {
68 | WebDriverManager.firefoxdriver().setup();
69 | driver.set(new FirefoxDriver());
70 | } else if (browserName.equalsIgnoreCase("IE")) {
71 | WebDriverManager.iedriver().setup();
72 | driver.set(new InternetExplorerDriver());
73 | }
74 | //Maximize the screen
75 | getDriver().manage().window().maximize();
76 | //Delete all the cookies
77 | getDriver().manage().deleteAllCookies();
78 | //Implicit TimeOuts
79 | getDriver().manage().timeouts().implicitlyWait
80 | (Integer.parseInt(prop.getProperty("implicitWait")),TimeUnit.SECONDS);
81 | //PageLoad TimeOuts
82 | getDriver().manage().timeouts().pageLoadTimeout
83 | (Integer.parseInt(prop.getProperty("pageLoadTimeOut")),TimeUnit.SECONDS);
84 | //Launching the URL
85 | getDriver().get(prop.getProperty("url"));
86 | }
87 |
88 | @AfterSuite(groups = { "Smoke", "Regression","Sanity" })
89 | public void afterSuite() {
90 | ExtentManager.endReport();
91 | }
92 | }
93 |
--------------------------------------------------------------------------------
/MyStoreProject/src/main/java/com/mystore/pageobjects/AccountCreationPage.java:
--------------------------------------------------------------------------------
1 | /**
2 | *
3 | */
4 | package com.mystore.pageobjects;
5 | import org.openqa.selenium.WebElement;
6 | import org.openqa.selenium.support.FindBy;
7 | import org.openqa.selenium.support.PageFactory;
8 | import com.mystore.actiondriver.Action;
9 | import com.mystore.base.BaseClass;
10 |
11 | /**
12 | * @author Hitendra
13 | *
14 | */
15 | public class AccountCreationPage extends BaseClass {
16 |
17 | Action action= new Action();
18 |
19 | @FindBy(xpath = "//h1[text()='Create an account']")
20 | private WebElement formTitle;
21 |
22 | @FindBy(id = "uniform-id_gender1")
23 | private WebElement mr;
24 |
25 | @FindBy(id = "id_gender2")
26 | private WebElement mrs;
27 |
28 | @FindBy(name = "customer_firstname")
29 | private WebElement firstName;
30 |
31 | @FindBy(name = "customer_lastname")
32 | private WebElement lastName;
33 |
34 | @FindBy(name = "passwd")
35 | private WebElement passWord;
36 |
37 | @FindBy(name = "days")
38 | private WebElement days;
39 |
40 | @FindBy(name = "months")
41 | private WebElement months;
42 |
43 | @FindBy(name = "years")
44 | private WebElement years;
45 |
46 | @FindBy(name = "firstname")
47 | private WebElement customerNirstName;
48 |
49 | @FindBy(name = "lastname")
50 | private WebElement customerLastName;
51 |
52 | @FindBy(name = "company")
53 | private WebElement companyName;
54 |
55 | @FindBy(name = "address1")
56 | private WebElement address;
57 |
58 | @FindBy(name = "city")
59 | private WebElement city;
60 |
61 | @FindBy(name = "id_state")
62 | private WebElement state;
63 |
64 | @FindBy(name = "postcode")
65 | private WebElement postCode;
66 |
67 | @FindBy(name = "id_country")
68 | private WebElement country;
69 |
70 | @FindBy(name = "phone")
71 | private WebElement phone;
72 |
73 | @FindBy(name = "phone_mobile")
74 | private WebElement mobile;
75 |
76 | @FindBy(name = "alias")
77 | private WebElement ref;
78 |
79 | @FindBy(name = "submitAccount")
80 | private WebElement registerBtn;
81 |
82 | public AccountCreationPage() {
83 | PageFactory.initElements(getDriver(), this);
84 | }
85 |
86 | public void createAccount(String gender,String fName,
87 | String lName,
88 | String pswd,
89 | String day,
90 | String month,
91 | String year,
92 | String comPany,
93 | String addr,
94 | String cityString,
95 | String stateName,
96 | String zip,
97 | String countryName,
98 | String mobilePhone) throws Throwable {
99 |
100 | if(gender.equalsIgnoreCase("Mr")) {
101 | action.click(getDriver(), mr);
102 | } else {
103 | action.click(getDriver(), mrs);
104 | }
105 |
106 | action.type(firstName, fName);
107 | action.type(lastName, lName);
108 | action.type(passWord, pswd);
109 | action.selectByValue(days, day);
110 | action.selectByValue(months, month);
111 | action.selectByValue(years, year);
112 | action.type(companyName, comPany);
113 | action.type(address, addr);
114 | action.type(city, cityString);
115 | action.selectByVisibleText(stateName, state);
116 | action.type(postCode, zip);
117 | action.selectByVisibleText(countryName, country);
118 | action.type(mobile, mobilePhone);
119 | }
120 |
121 | public HomePage validateRegistration() throws Throwable {
122 | registerBtn.click();
123 | return new HomePage();
124 | }
125 |
126 | public boolean validateAcountCreatePage() throws Throwable {
127 | return action.isDisplayed(getDriver(), formTitle);
128 | }
129 |
130 | }
131 |
--------------------------------------------------------------------------------
/MyStoreProject/test-output/CrossBrowser/IETest.html:
--------------------------------------------------------------------------------
1 |
2 |
3 | TestNG: IETest
4 |
5 |
6 |
7 |
11 |
53 |
54 |
55 |
56 | IETest
57 |
58 | Tests passed/Failed/Skipped: 2/0/0
59 |
60 | Started on: Fri Jul 17 19:11:37 IST 2020
61 |
62 | Total time: 27 seconds (27348 ms)
63 |
64 | Included groups:
65 |
66 | Excluded groups:
67 |
68 |
69 | (Hover the method name to see the test class name)
70 |
71 | PASSED TESTS
72 | Test method
73 | Exception
74 | Time (seconds)
75 | Instance
76 |
77 |
78 | verifyLogo Test class: com.mystore.testcases.IndexPageTest
79 |
80 | 0
81 | com.mystore.testcases.IndexPageTest@2781e022
82 |
83 | verifyLogo Test class: com.mystore.testcases.IndexPageTest
84 |
85 | 6
86 | com.mystore.testcases.IndexPageTest@3d921e20
87 |
88 | verifyLogo Test class: com.mystore.testcases.IndexPageTest
89 |
90 | 0
91 | com.mystore.testcases.IndexPageTest@51e2adc7
92 |
93 | verifyTitle Test class: com.mystore.testcases.IndexPageTest
94 |
95 | 0
96 | com.mystore.testcases.IndexPageTest@3d921e20
97 |
98 | verifyTitle Test class: com.mystore.testcases.IndexPageTest
99 |
100 | 0
101 | com.mystore.testcases.IndexPageTest@2781e022
102 |
103 | verifyTitle Test class: com.mystore.testcases.IndexPageTest
104 |
105 | 0
106 | com.mystore.testcases.IndexPageTest@51e2adc7
107 |
108 |
109 |
--------------------------------------------------------------------------------
/MyStoreProject/src/main/java/com/mystore/dataprovider/DataProviders.java:
--------------------------------------------------------------------------------
1 | /**
2 | *
3 | */
4 | package com.mystore.dataprovider;
5 |
6 | import java.util.ArrayList;
7 | import java.util.HashMap;
8 | import java.util.List;
9 | import java.util.Map;
10 |
11 | import org.testng.annotations.DataProvider;
12 |
13 | import com.mystore.utility.NewExcelLibrary;
14 |
15 | /**
16 | * @author Hitendra
17 | *
18 | */
19 | public class DataProviders {
20 |
21 | NewExcelLibrary obj = new NewExcelLibrary();
22 |
23 | //Class --> LoginPageTest,HomePageTest Test Case--> loginTest, wishListTest, orderHistoryandDetailsTest
24 |
25 | @DataProvider(name = "credentials")
26 | public Object[][] getCredentials() {
27 | // Totals rows count
28 | int rows = obj.getRowCount("Credentials");
29 | // Total Columns
30 | int column = obj.getColumnCount("Credentials");
31 | int actRows = rows - 1;
32 |
33 | Object[][] data = new Object[actRows][column];
34 |
35 | for (int i = 0; i < actRows; i++) {
36 | for (int j = 0; j < column; j++) {
37 | data[i][j] = obj.getCellData("Credentials", j, i + 2);
38 | }
39 | }
40 | return data;
41 | }
42 |
43 | //Class --> AccountCreationPage Test Case--> verifyCreateAccountPageTest
44 | @DataProvider(name = "email")
45 | public Object[][] getEmail() {
46 | // Totals rows count
47 | int rows = obj.getRowCount("Email");
48 | // Total Columns
49 | int column = obj.getColumnCount("Email");
50 | int actRows = rows - 1;
51 |
52 | Object[][] data = new Object[actRows][column];
53 |
54 | for (int i = 0; i < actRows; i++) {
55 | for (int j = 0; j < column; j++) {
56 | data[i][j] = obj.getCellData("Email", j, i + 2);
57 | }
58 | }
59 | return data;
60 | }
61 |
62 | //Class --> AddToCartPageTest, EndToEndTest, Test Case--> addToCartTest, endToEndTest
63 | @DataProvider(name = "getProduct")
64 | public Object[][] getProduct() {
65 | // Totals rows count
66 | int rows = obj.getRowCount("ProductDetails");
67 | // Total Columns
68 | int column = obj.getColumnCount("ProductDetails");
69 | int actRows = rows - 1;
70 |
71 | Object[][] data = new Object[actRows][column];
72 |
73 | for (int i = 0; i < actRows; i++) {
74 | for (int j = 0; j < column; j++) {
75 | data[i][j] = obj.getCellData("ProductDetails", j, i + 2);
76 | }
77 | }
78 | return data;
79 | }
80 |
81 | // Class --> SearchResultPageTest, Test Case--> productAvailabilityTest
82 | @DataProvider(name = "searchProduct")
83 | public Object[][] getProductPrice() {
84 | // Totals rows count
85 | int rows = obj.getRowCount("SearchProduct");
86 | // Total Columns
87 | int column = obj.getColumnCount("SearchProduct");
88 | int actRows = rows - 1;
89 |
90 | Object[][] data = new Object[actRows][column];
91 |
92 | for (int i = 0; i < actRows; i++) {
93 | for (int j = 0; j < column; j++) {
94 | data[i][j] = obj.getCellData("SearchProduct", j, i + 2);
95 | }
96 | }
97 | return data;
98 | }
99 |
100 | @DataProvider(name = "newAcountDetailsData")
101 | public Object[][] accountCreation() {
102 |
103 | // Totals rows count
104 | int rows = obj.getRowCount("AccountCreationData");
105 | // Total Columns
106 | int column = obj.getColumnCount("AccountCreationData");
107 | int actRows = rows - 1;
108 | //Created an object of array to store data
109 | Object[][] data = new Object[actRows][1];
110 |
111 | for (int i = 0; i < actRows; i++) {
112 | Map hashMap = new HashMap<>();
113 | for (int j = 0; j < column; j++) {
114 | hashMap.put(obj.getCellData("AccountCreationData", j, 1),
115 | obj.getCellData("AccountCreationData", j, i + 2));
116 | }
117 | data[i][0]=hashMap;
118 | }
119 | return data;
120 | }
121 |
122 | }
123 |
--------------------------------------------------------------------------------
/MyStoreProject/test-output/Suite/Sanity.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 |
37 |
38 |
39 |
40 |
41 |
42 |
43 |
44 |
45 |
46 |
47 |
48 |
49 |
50 |
51 |
52 |
53 |
54 |
55 |
56 |
57 |
58 |
59 |
60 |
61 |
62 |
63 |
64 |
65 |
66 |
67 |
68 |
69 |
70 |
71 |
--------------------------------------------------------------------------------
/MyStoreProject/test-output/Suite/Regression.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 |
37 |
38 |
39 |
40 |
41 |
42 |
43 |
44 |
45 |
46 |
47 |
48 |
49 |
50 |
51 |
52 |
53 |
54 |
55 |
56 |
57 |
58 |
59 |
60 |
61 |
62 |
63 |
64 |
65 |
66 |
67 |
68 |
69 |
70 |
71 |
--------------------------------------------------------------------------------
/MyStoreProject/test-output/testng-reports.js:
--------------------------------------------------------------------------------
1 | $(document).ready(function() {
2 | $('a.navigator-link').on("click", function() {
3 | // Extract the panel for this link
4 | var panel = getPanelName($(this));
5 |
6 | // Mark this link as currently selected
7 | $('.navigator-link').parent().removeClass('navigator-selected');
8 | $(this).parent().addClass('navigator-selected');
9 |
10 | showPanel(panel);
11 | });
12 |
13 | installMethodHandlers('failed');
14 | installMethodHandlers('skipped');
15 | installMethodHandlers('passed', true); // hide passed methods by default
16 |
17 | $('a.method').on("click", function() {
18 | showMethod($(this));
19 | return false;
20 | });
21 |
22 | // Hide all the panels and display the first one (do this last
23 | // to make sure the click() will invoke the listeners)
24 | $('.panel').hide();
25 | $('.navigator-link').first().trigger("click");
26 |
27 | // Collapse/expand the suites
28 | $('a.collapse-all-link').on("click", function() {
29 | var contents = $('.navigator-suite-content');
30 | if (contents.css('display') == 'none') {
31 | contents.show();
32 | } else {
33 | contents.hide();
34 | }
35 | });
36 | });
37 |
38 | // The handlers that take care of showing/hiding the methods
39 | function installMethodHandlers(name, hide) {
40 | function getContent(t) {
41 | return $('.method-list-content.' + name + "." + t.attr('panel-name'));
42 | }
43 |
44 | function getHideLink(t, name) {
45 | var s = 'a.hide-methods.' + name + "." + t.attr('panel-name');
46 | return $(s);
47 | }
48 |
49 | function getShowLink(t, name) {
50 | return $('a.show-methods.' + name + "." + t.attr('panel-name'));
51 | }
52 |
53 | function getMethodPanelClassSel(element, name) {
54 | var panelName = getPanelName(element);
55 | var sel = '.' + panelName + "-class-" + name;
56 | return $(sel);
57 | }
58 |
59 | $('a.hide-methods.' + name).on("click", function() {
60 | var w = getContent($(this));
61 | w.hide();
62 | getHideLink($(this), name).hide();
63 | getShowLink($(this), name).show();
64 | getMethodPanelClassSel($(this), name).hide();
65 | });
66 |
67 | $('a.show-methods.' + name).on("click", function() {
68 | var w = getContent($(this));
69 | w.show();
70 | getHideLink($(this), name).show();
71 | getShowLink($(this), name).hide();
72 | showPanel(getPanelName($(this)));
73 | getMethodPanelClassSel($(this), name).show();
74 | });
75 |
76 | if (hide) {
77 | $('a.hide-methods.' + name).trigger("click");
78 | } else {
79 | $('a.show-methods.' + name).trigger("click");
80 | }
81 | }
82 |
83 | function getHashForMethod(element) {
84 | return element.attr('hash-for-method');
85 | }
86 |
87 | function getPanelName(element) {
88 | return element.attr('panel-name');
89 | }
90 |
91 | function showPanel(panelName) {
92 | $('.panel').hide();
93 | var panel = $('.panel[panel-name="' + panelName + '"]');
94 | panel.show();
95 | }
96 |
97 | function showMethod(element) {
98 | var hashTag = getHashForMethod(element);
99 | var panelName = getPanelName(element);
100 | showPanel(panelName);
101 | var current = document.location.href;
102 | var base = current.substring(0, current.indexOf('#'))
103 | document.location.href = base + '#' + hashTag;
104 | var newPosition = $(document).scrollTop() - 65;
105 | $(document).scrollTop(newPosition);
106 | }
107 |
108 | function drawTable() {
109 | for (var i = 0; i < suiteTableInitFunctions.length; i++) {
110 | window[suiteTableInitFunctions[i]]();
111 | }
112 |
113 | for (var k in window.suiteTableData) {
114 | var v = window.suiteTableData[k];
115 | var div = v.tableDiv;
116 | var data = v.tableData
117 | var table = new google.visualization.Table(document.getElementById(div));
118 | table.draw(data, {
119 | showRowNumber : false
120 | });
121 | }
122 | }
123 |
--------------------------------------------------------------------------------
/MyStoreProject/test-output/Suite/Test_All.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 |
37 |
38 |
39 |
40 |
41 |
42 |
43 |
44 |
45 |
46 |
47 |
48 |
49 |
50 |
51 |
52 |
53 |
54 |
55 |
56 |
57 |
58 |
59 |
60 |
61 |
62 |
63 |
64 |
65 |
66 |
67 |
68 |
69 |
70 |
71 |
--------------------------------------------------------------------------------
/MyStoreProject/test-output/Suite/Test.html:
--------------------------------------------------------------------------------
1 |
2 |
3 | TestNG: Test
4 |
5 |
6 |
7 |
11 |
53 |
54 |
55 |
56 | Test
57 |
58 | Tests passed/Failed/Skipped: 9/0/0
59 |
60 | Started on: Mon Jul 13 17:22:50 IST 2020
61 |
62 | Total time: 202 seconds (202075 ms)
63 |
64 | Included groups:
65 |
66 | Excluded groups:
67 |
68 |
69 | (Hover the method name to see the test class name)
70 |
71 | PASSED TESTS
72 | Test method
73 | Exception
74 | Time (seconds)
75 | Instance
76 |
77 |
78 | addToCartTest Test class: com.mystore.testcases.AddToCartPageTest
79 |
80 | 11
81 | com.mystore.testcases.AddToCartPageTest@7a1ebcd8
82 |
83 | endToEndTest Test class: com.mystore.testcases.EndToEndTest
84 |
85 | 35
86 | com.mystore.testcases.EndToEndTest@ea1a8d5
87 |
88 | orderHistoryandDetailsTest Test class: com.mystore.testcases.HomePageTest
89 |
90 | 8
91 | com.mystore.testcases.HomePageTest@458c1321
92 |
93 | productAvailabilityTest Test class: com.mystore.testcases.SearchResultPageTest
94 |
95 | 5
96 | com.mystore.testcases.SearchResultPageTest@34cd072c
97 |
98 | verifyCreateAccountPageTest Test class: com.mystore.testcases.AccountCreationPageTest
99 |
100 | 6
101 | com.mystore.testcases.AccountCreationPageTest@5faeada1
102 |
103 | verifyLogo Test class: com.mystore.testcases.IndexPageTest
104 |
105 | 0
106 | com.mystore.testcases.IndexPageTest@528931cf
107 |
108 | verifyTitle Test class: com.mystore.testcases.IndexPageTest
109 |
110 | 0
111 | com.mystore.testcases.IndexPageTest@528931cf
112 |
113 | verifyTotalPrice Test class: com.mystore.testcases.OrderPageTest
114 |
115 | 15
116 | com.mystore.testcases.OrderPageTest@11438d26
117 |
118 | wishListTest Test class: com.mystore.testcases.HomePageTest
119 |
120 | 9
121 | com.mystore.testcases.HomePageTest@458c1321
122 |
123 |
124 |
--------------------------------------------------------------------------------
/MyStoreProject/test-output/old/Suite/classes.html:
--------------------------------------------------------------------------------
1 |
2 |
3 | Class name
4 | Method name
5 | Groups
6 |
7 | com.mystore.testcases.AccountCreationPageTest
8 |
9 |
10 | @Test
11 |
12 |
13 |
14 | verifyCreateAccountPageTest
15 | Sanity
16 |
17 |
18 | @BeforeClass
19 |
20 |
21 | @BeforeMethod
22 |
23 |
24 |
25 | setup
26 | Sanity Regression Smoke
27 |
28 |
29 | @AfterMethod
30 |
31 |
32 |
33 | tearDown
34 | Sanity Regression Smoke
35 |
36 |
37 | @AfterClass
38 |
39 |
40 | com.mystore.testcases.EndToEndTest
41 |
42 |
43 | @Test
44 |
45 |
46 |
47 | endToEndTest
48 | Regression
49 |
50 |
51 | @BeforeClass
52 |
53 |
54 | @BeforeMethod
55 |
56 |
57 |
58 | setup
59 | Sanity Regression Smoke
60 |
61 |
62 | @AfterMethod
63 |
64 |
65 |
66 | tearDown
67 | Sanity Regression Smoke
68 |
69 |
70 | @AfterClass
71 |
72 |
73 | com.mystore.testcases.SearchResultPageTest
74 |
75 |
76 | @Test
77 |
78 |
79 |
80 | productAvailabilityTest
81 | Smoke
82 |
83 |
84 | @BeforeClass
85 |
86 |
87 | @BeforeMethod
88 |
89 |
90 |
91 | setup
92 | Sanity Regression Smoke
93 |
94 |
95 | @AfterMethod
96 |
97 |
98 |
99 | tearDown
100 | Sanity Regression Smoke
101 |
102 |
103 | @AfterClass
104 |
105 |
106 | com.mystore.testcases.AddToCartPageTest
107 |
108 |
109 | @Test
110 |
111 |
112 |
113 | addToCartTest
114 | Sanity Regression
115 |
116 |
117 | @BeforeClass
118 |
119 |
120 | @BeforeMethod
121 |
122 |
123 |
124 | setup
125 | Sanity Regression Smoke
126 |
127 |
128 | @AfterMethod
129 |
130 |
131 |
132 | tearDown
133 | Sanity Regression Smoke
134 |
135 |
136 | @AfterClass
137 |
138 |
139 | com.mystore.testcases.IndexPageTest
140 |
141 |
142 | @Test
143 |
144 |
145 |
146 | verifyLogo
147 | Smoke
148 |
149 |
150 |
151 | verifyTitle
152 | Smoke
153 |
154 |
155 | @BeforeClass
156 |
157 |
158 | @BeforeMethod
159 |
160 |
161 |
162 | setup
163 | Sanity Regression Smoke
164 |
165 |
166 | @AfterMethod
167 |
168 |
169 |
170 | tearDown
171 | Sanity Regression Smoke
172 |
173 |
174 | @AfterClass
175 |
176 |
177 | com.mystore.testcases.OrderPageTest
178 |
179 |
180 | @Test
181 |
182 |
183 |
184 | verifyTotalPrice
185 | Regression
186 |
187 |
188 | @BeforeClass
189 |
190 |
191 | @BeforeMethod
192 |
193 |
194 |
195 | setup
196 | Sanity Regression Smoke
197 |
198 |
199 | @AfterMethod
200 |
201 |
202 |
203 | tearDown
204 | Sanity Regression Smoke
205 |
206 |
207 | @AfterClass
208 |
209 |
210 | com.mystore.testcases.HomePageTest
211 |
212 |
213 | @Test
214 |
215 |
216 |
217 | wishListTest
218 | Smoke
219 |
220 |
221 |
222 | orderHistoryandDetailsTest
223 | Smoke
224 |
225 |
226 | @BeforeClass
227 |
228 |
229 | @BeforeMethod
230 |
231 |
232 |
233 | setup
234 | Sanity Regression Smoke
235 |
236 |
237 | @AfterMethod
238 |
239 |
240 |
241 | tearDown
242 | Sanity Regression Smoke
243 |
244 |
245 | @AfterClass
246 |
247 |
248 | com.mystore.testcases.LoginPageTest
249 |
250 |
251 | @Test
252 |
253 |
254 |
255 | loginTest
256 | Sanity Smoke
257 |
258 |
259 | @BeforeClass
260 |
261 |
262 | @BeforeMethod
263 |
264 |
265 |
266 | setup
267 | Sanity Regression Smoke
268 |
269 |
270 | @AfterMethod
271 |
272 |
273 |
274 | tearDown
275 | Sanity Regression Smoke
276 |
277 |
278 | @AfterClass
279 |
280 |
281 |
--------------------------------------------------------------------------------
/MyStoreProject/test-output/testng-reports.css:
--------------------------------------------------------------------------------
1 | body {
2 | margin: 0 0 5px 5px;
3 | }
4 |
5 | ul {
6 | margin: 0;
7 | }
8 |
9 | li {
10 | list-style-type: none;
11 | }
12 |
13 | a {
14 | text-decoration: none;
15 | }
16 |
17 | a:hover {
18 | text-decoration: underline;
19 | }
20 |
21 | .navigator-selected {
22 | background: #ffa500;
23 | }
24 |
25 | .wrapper {
26 | position: absolute;
27 | top: 60px;
28 | bottom: 0;
29 | left: 400px;
30 | right: 0;
31 | overflow: auto;
32 | }
33 |
34 | .navigator-root {
35 | position: absolute;
36 | top: 60px;
37 | bottom: 0;
38 | left: 0;
39 | width: 400px;
40 | overflow-y: auto;
41 | }
42 |
43 | .suite {
44 | margin: 0 10px 10px 0;
45 | background-color: #fff8dc;
46 | }
47 |
48 | .suite-name {
49 | padding-left: 10px;
50 | font-size: 25px;
51 | font-family: Times, sans-serif;
52 | }
53 |
54 | .main-panel-header {
55 | padding: 5px;
56 | background-color: #9FB4D9; /*afeeee*/;
57 | font-family: monospace;
58 | font-size: 18px;
59 | }
60 |
61 | .main-panel-content {
62 | padding: 5px;
63 | margin-bottom: 10px;
64 | background-color: #DEE8FC; /*d0ffff*/;
65 | }
66 |
67 | .rounded-window {
68 | border-radius: 10px;
69 | border-style: solid;
70 | border-width: 1px;
71 | }
72 |
73 | .rounded-window-top {
74 | border-top-right-radius: 10px 10px;
75 | border-top-left-radius: 10px 10px;
76 | border-style: solid;
77 | border-width: 1px;
78 | overflow: auto;
79 | }
80 |
81 | .light-rounded-window-top {
82 | border-top-right-radius: 10px 10px;
83 | border-top-left-radius: 10px 10px;
84 | }
85 |
86 | .rounded-window-bottom {
87 | border-style: solid;
88 | border-width: 0 1px 1px 1px;
89 | border-bottom-right-radius: 10px 10px;
90 | border-bottom-left-radius: 10px 10px;
91 | overflow: auto;
92 | }
93 |
94 | .method-name {
95 | font-size: 12px;
96 | font-family: monospace;
97 | }
98 |
99 | .method-content {
100 | border-style: solid;
101 | border-width: 0 0 1px 0;
102 | margin-bottom: 10px;
103 | padding-bottom: 5px;
104 | width: 80%;
105 | }
106 |
107 | .parameters {
108 | font-size: 14px;
109 | font-family: monospace;
110 | }
111 |
112 | .stack-trace {
113 | white-space: pre;
114 | font-family: monospace;
115 | font-size: 12px;
116 | font-weight: bold;
117 | margin-top: 0;
118 | margin-left: 20px;
119 | }
120 |
121 | .testng-xml {
122 | font-family: monospace;
123 | }
124 |
125 | .method-list-content {
126 | margin-left: 10px;
127 | }
128 |
129 | .navigator-suite-content {
130 | margin-left: 10px;
131 | font: 12px 'Lucida Grande';
132 | }
133 |
134 | .suite-section-title {
135 | margin-top: 10px;
136 | width: 80%;
137 | border-style: solid;
138 | border-width: 1px 0 0 0;
139 | font-family: Times, sans-serif;
140 | font-size: 18px;
141 | font-weight: bold;
142 | }
143 |
144 | .suite-section-content {
145 | list-style-image: url(bullet_point.png);
146 | }
147 |
148 | .top-banner-root {
149 | position: absolute;
150 | top: 0;
151 | height: 45px;
152 | left: 0;
153 | right: 0;
154 | padding: 5px;
155 | margin: 0 0 5px 0;
156 | background-color: #0066ff;
157 | font-family: Times, sans-serif;
158 | color: #fff;
159 | text-align: center;
160 | }
161 |
162 | .top-banner-title-font {
163 | font-size: 25px;
164 | }
165 |
166 | .test-name {
167 | font-family: 'Lucida Grande', sans-serif;
168 | font-size: 16px;
169 | }
170 |
171 | .suite-icon {
172 | padding: 5px;
173 | float: right;
174 | height: 20px;
175 | }
176 |
177 | .test-group {
178 | font: 20px 'Lucida Grande';
179 | margin: 5px 5px 10px 5px;
180 | border-width: 0 0 1px 0;
181 | border-style: solid;
182 | padding: 5px;
183 | }
184 |
185 | .test-group-name {
186 | font-weight: bold;
187 | }
188 |
189 | .method-in-group {
190 | font-size: 16px;
191 | margin-left: 80px;
192 | }
193 |
194 | table.google-visualization-table-table {
195 | width: 100%;
196 | }
197 |
198 | .reporter-method-name {
199 | font-size: 14px;
200 | font-family: monospace;
201 | }
202 |
203 | .reporter-method-output-div {
204 | padding: 5px;
205 | margin: 0 0 5px 20px;
206 | font-size: 12px;
207 | font-family: monospace;
208 | border-width: 0 0 0 1px;
209 | border-style: solid;
210 | }
211 |
212 | .ignored-class-div {
213 | font-size: 14px;
214 | font-family: monospace;
215 | }
216 |
217 | .ignored-methods-div {
218 | padding: 5px;
219 | margin: 0 0 5px 20px;
220 | font-size: 12px;
221 | font-family: monospace;
222 | border-width: 0 0 0 1px;
223 | border-style: solid;
224 | }
225 |
226 | .border-failed {
227 | border-top-left-radius: 10px 10px;
228 | border-bottom-left-radius: 10px 10px;
229 | border-style: solid;
230 | border-width: 0 0 0 10px;
231 | border-color: #f00;
232 | }
233 |
234 | .border-skipped {
235 | border-top-left-radius: 10px 10px;
236 | border-bottom-left-radius: 10px 10px;
237 | border-style: solid;
238 | border-width: 0 0 0 10px;
239 | border-color: #edc600;
240 | }
241 |
242 | .border-passed {
243 | border-top-left-radius: 10px 10px;
244 | border-bottom-left-radius: 10px 10px;
245 | border-style: solid;
246 | border-width: 0 0 0 10px;
247 | border-color: #19f52d;
248 | }
249 |
250 | .times-div {
251 | text-align: center;
252 | padding: 5px;
253 | }
254 |
255 | .suite-total-time {
256 | font: 16px 'Lucida Grande';
257 | }
258 |
259 | .configuration-suite {
260 | margin-left: 20px;
261 | }
262 |
263 | .configuration-test {
264 | margin-left: 40px;
265 | }
266 |
267 | .configuration-class {
268 | margin-left: 60px;
269 | }
270 |
271 | .configuration-method {
272 | margin-left: 80px;
273 | }
274 |
275 | .test-method {
276 | margin-left: 100px;
277 | }
278 |
279 | .chronological-class {
280 | background-color: skyblue;
281 | border-style: solid;
282 | border-width: 0 0 1px 1px;
283 | }
284 |
285 | .method-start {
286 | float: right;
287 | }
288 |
289 | .chronological-class-name {
290 | padding: 0 0 0 5px;
291 | color: #008;
292 | }
293 |
294 | .after, .before, .test-method {
295 | font-family: monospace;
296 | font-size: 14px;
297 | }
298 |
299 | .navigator-suite-header {
300 | font-size: 22px;
301 | margin: 0 10px 5px 0;
302 | background-color: #deb887;
303 | text-align: center;
304 | }
305 |
306 | .collapse-all-icon {
307 | padding: 5px;
308 | float: right;
309 | }
310 |
--------------------------------------------------------------------------------
/MyStoreProject/test-output/Default suite/Default test.html:
--------------------------------------------------------------------------------
1 |
2 |
3 | TestNG: Default test
4 |
5 |
6 |
7 |
11 |
53 |
54 |
55 |
56 | Default test
57 |
58 | Tests passed/Failed/Skipped: 0/1/0
59 |
60 | Started on: Tue Jul 14 16:26:32 IST 2020
61 |
62 | Total time: 0 seconds (63 ms)
63 |
64 | Included groups:
65 |
66 | Excluded groups:
67 |
68 |
69 | (Hover the method name to see the test class name)
70 |
71 | FAILED TESTS
72 | Test method
73 | Exception
74 | Time (seconds)
75 | Instance
76 |
77 |
78 | verifyCreateAccountPageTest Test class: com.mystore.testcases.AccountCreationPageTest
79 | org.testng.TestNGException:
80 | Method public void com.mystore.testcases.AccountCreationPageTest.verifyCreateAccountPageTest(java.lang.String) throws java.lang.Throwable requires a @DataProvider named : email
81 | at org.testng.internal.Parameters.findDataProvider(Parameters.java:563)
82 | at org.testng.internal.Parameters.handleParameters(Parameters.java:776)
83 | at org.testng.internal.Parameters.handleParameters(Parameters.java:744)
84 | at org.testng.internal.ParameterHandler.handleParameters(ParameterHandler.java:59)
85 | at org.testng.internal.ParameterHandler.createParameters(ParameterHandler.java:38)
86 | at org.testng.internal.TestInvoker$MethodInvocationAgent.invoke(TestInvoker.java:783)
87 | at org.testng.internal.TestInvoker.invokeTestMethods(TestInvoker.java:146)
88 | at org.testng.internal.TestMethodWorker.invokeTestMethods(TestMethodWorker.java:146)
89 | at org.testng.internal.TestMethodWorker.run(TestMethodWorker.java:128)
90 | at java.util.ArrayList.forEach(ArrayList.java:1257)
91 | at org.testng.TestRunner.privateRun(TestRunner.java:766)
92 | at org.testng.TestRunner.run(TestRunner.java:587)
93 | at org.testng.SuiteRunner.runTest(SuiteRunner.java:384)
94 | at org.testng.SuiteRunner.runSequentially(SuiteRunner.java:378)
95 | at org.testng.SuiteRunner.privateRun(SuiteRunner.java:337)
96 | at org.testng.SuiteRunner.run(SuiteRunner.java:286)
97 | at org.testng.SuiteRunnerWorker.runSuite(SuiteRunnerWorker.java:53)
98 | at org.testng.SuiteRunnerWorker.run(SuiteRunnerWorker.java:96)
99 | at org.testng.TestNG.runSuitesSequentially(TestNG.java:1187)
100 | at org.testng.TestNG.runSuitesLocally(TestNG.java:1109)
101 | at org.testng.TestNG.runSuites(TestNG.java:1039)
102 | at org.testng.TestNG.run(TestNG.java:1007)
103 | at org.testng.remote.AbstractRemoteTestNG.run(AbstractRemoteTestNG.java:115)
104 | at org.testng.remote.RemoteTestNG.initAndRun(RemoteTestNG.java:251)
105 | at org.testng.remote.RemoteTestNG.main(RemoteTestNG.java:77)
106 | Click to show all stack frames
107 | org.testng.TestNGException:
108 | Method public void com.mystore.testcases.AccountCreationPageTest.verifyCreateAccountPageTest(java.lang.String) throws java.lang.Throwable requires a @DataProvider named : email
109 | at org.testng.internal.Parameters.findDataProvider(Parameters.java:563)
110 | at org.testng.internal.Parameters.handleParameters(Parameters.java:776)
111 | at org.testng.internal.Parameters.handleParameters(Parameters.java:744)
112 | at org.testng.internal.ParameterHandler.handleParameters(ParameterHandler.java:59)
113 | at org.testng.internal.ParameterHandler.createParameters(ParameterHandler.java:38)
114 | at org.testng.internal.TestInvoker$MethodInvocationAgent.invoke(TestInvoker.java:783)
115 | at org.testng.internal.TestInvoker.invokeTestMethods(TestInvoker.java:146)
116 | at org.testng.internal.TestMethodWorker.invokeTestMethods(TestMethodWorker.java:146)
117 | at org.testng.internal.TestMethodWorker.run(TestMethodWorker.java:128)
118 | at java.util.ArrayList.forEach(ArrayList.java:1257)
119 | at org.testng.TestRunner.privateRun(TestRunner.java:766)
120 | at org.testng.TestRunner.run(TestRunner.java:587)
121 | at org.testng.SuiteRunner.runTest(SuiteRunner.java:384)
122 | at org.testng.SuiteRunner.runSequentially(SuiteRunner.java:378)
123 | at org.testng.SuiteRunner.privateRun(SuiteRunner.java:337)
124 | at org.testng.SuiteRunner.run(SuiteRunner.java:286)
125 | at org.testng.SuiteRunnerWorker.runSuite(SuiteRunnerWorker.java:53)
126 | at org.testng.SuiteRunnerWorker.run(SuiteRunnerWorker.java:96)
127 | at org.testng.TestNG.runSuitesSequentially(TestNG.java:1187)
128 | at org.testng.TestNG.runSuitesLocally(TestNG.java:1109)
129 | at org.testng.TestNG.runSuites(TestNG.java:1039)
130 | at org.testng.TestNG.run(TestNG.java:1007)
131 | at org.testng.remote.AbstractRemoteTestNG.run(AbstractRemoteTestNG.java:115)
132 | at org.testng.remote.RemoteTestNG.initAndRun(RemoteTestNG.java:251)
133 | at org.testng.remote.RemoteTestNG.main(RemoteTestNG.java:77)
134 |
135 | 0
136 | com.mystore.testcases.AccountCreationPageTest@6ee52dcd
137 |
138 |
139 |
--------------------------------------------------------------------------------
/MyStoreProject/test-output/emailable-report.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | TestNG Report
6 |
7 |
8 |
9 |
10 | Test # Passed # Skipped # Retried # Failed Time (ms) Included Groups Excluded Groups
11 | Suite
12 | Test_All 8 0 0 2 278,888
13 |
14 |
16 | Test_All com.mystore.testcases.HomePageTest#orderHistoryandDetailsTest Parameter #1 Parameter #2 admin@xyz.com admin@123 Exception java.lang.AssertionError: expected [true] but found [false]
17 | at com.mystore.testcases.HomePageTest.orderHistoryandDetailsTest(HomePageTest.java:57)
18 | at java.util.ArrayList.forEach(ArrayList.java:1257)
19 | ... Removed 31 stack frames
back to summary
20 | com.mystore.testcases.IndexPageTest#verifyTitle Exception java.lang.AssertionError: expected [My Store1] but found [My Store]
21 | at com.mystore.testcases.IndexPageTest.verifyTitle(IndexPageTest.java:45)
22 | at java.util.ArrayList.forEach(ArrayList.java:1257)
23 | ... Removed 32 stack frames
back to summary
24 | com.mystore.testcases.AccountCreationPageTest#verifyCreateAccountPageTest Parameter #1 ghfsdtyfg@gmail.com
back to summary
25 | com.mystore.testcases.AddToCartPageTest#addToCartTest Parameter #1 Parameter #2 Parameter #3 t-shirt 2.0 M
back to summary
26 | com.mystore.testcases.EndToEndTest#endToEndTest Parameter #1 Parameter #2 Parameter #3 t-shirt 2.0 M
back to summary
27 | com.mystore.testcases.HomePageTest#wishListTest Parameter #1 Parameter #2 admin@xyz.com admin@123
back to summary
28 | com.mystore.testcases.IndexPageTest#verifyLogo back to summary
29 | com.mystore.testcases.LoginPageTest#loginTest Parameter #1 Parameter #2 admin@xyz.com admin@123
back to summary
30 | com.mystore.testcases.OrderPageTest#verifyTotalPrice Parameter #1 Parameter #2 Parameter #3 t-shirt 2.0 M
back to summary
31 | com.mystore.testcases.SearchResultPageTest#productAvailabilityTest back to summary
32 |
33 |
34 |
--------------------------------------------------------------------------------
/MyStoreProject/test-output/old/CrossBrowser/methods.html:
--------------------------------------------------------------------------------
1 | Methods run, sorted chronologically >> means before, << means after
CrossBrowser
(Hover the method name to see the test class name)
2 |
3 | Time Delta (ms) Suite configuration Test configuration Class configuration Groups configuration Method configuration Test method Thread Instances
4 | 20/07/17 19:11:37 0 >>beforeSuite
5 | main@1188753216
6 | 20/07/17 19:11:37 187 >>loadConfig
7 | TestNG-tests-1@1319658452
8 | 20/07/17 19:11:37 191 >>loadConfig
9 | TestNG-tests-2@1631315962
10 | 20/07/17 19:11:37 195 >>loadConfig
11 | TestNG-tests-3@1246841284
12 | 20/07/17 19:11:37 239 >>setup
13 | TestNG-tests-2@1631315962
14 | 20/07/17 19:11:37 239 >>setup
15 | TestNG-tests-1@1319658452
16 | 20/07/17 19:11:37 239 >>setup
17 | TestNG-tests-3@1246841284
18 | 20/07/17 19:11:48 10538 verifyLogo
19 | TestNG-tests-3@1246841284
20 | 20/07/17 19:11:53 15395 verifyLogo
21 | TestNG-tests-1@1319658452
22 | 20/07/17 19:11:53 15681 <<tearDown
23 | TestNG-tests-1@1319658452
24 | 20/07/17 19:11:54 16390 >>setup
25 | TestNG-tests-1@1319658452
26 | 20/07/17 19:11:55 17432 <<tearDown
27 | TestNG-tests-3@1246841284
28 | 20/07/17 19:11:55 17982 >>setup
29 | TestNG-tests-3@1246841284
30 | 20/07/17 19:11:56 19137 verifyLogo
31 | TestNG-tests-2@1631315962
32 | 20/07/17 19:11:56 19305 <<tearDown
33 | TestNG-tests-2@1631315962
34 | 20/07/17 19:11:58 20843 >>setup
35 | TestNG-tests-2@1631315962
36 | 20/07/17 19:12:04 26509 verifyTitle
37 | TestNG-tests-3@1246841284
38 | 20/07/17 19:12:04 26883 <<tearDown
39 | TestNG-tests-3@1246841284
40 | 20/07/17 19:12:07 29724 verifyTitle
41 | TestNG-tests-1@1319658452
42 | 20/07/17 19:12:07 29760 <<tearDown
43 | TestNG-tests-1@1319658452
44 | 20/07/17 19:12:14 37322 verifyTitle
45 | TestNG-tests-2@1631315962
46 | 20/07/17 19:12:15 37383 <<tearDown
47 | TestNG-tests-2@1631315962
48 |
49 |
--------------------------------------------------------------------------------
/MyStoreProject/test-output/old/CrossBrowser/methods-alphabetical.html:
--------------------------------------------------------------------------------
1 | Methods run, sorted chronologically >> means before, << means after
CrossBrowser
(Hover the method name to see the test class name)
2 |
3 | Time Delta (ms) Suite configuration Test configuration Class configuration Groups configuration Method configuration Test method Thread Instances
4 | 20/07/17 19:11:37 0 >>beforeSuite
5 | main@1188753216
6 | 20/07/17 19:11:37 187 >>loadConfig
7 | TestNG-tests-1@1319658452
8 | 20/07/17 19:11:37 191 >>loadConfig
9 | TestNG-tests-2@1631315962
10 | 20/07/17 19:11:37 195 >>loadConfig
11 | TestNG-tests-3@1246841284
12 | 20/07/17 19:11:37 239 >>setup
13 | TestNG-tests-2@1631315962
14 | 20/07/17 19:11:37 239 >>setup
15 | TestNG-tests-1@1319658452
16 | 20/07/17 19:11:37 239 >>setup
17 | TestNG-tests-3@1246841284
18 | 20/07/17 19:11:54 16390 >>setup
19 | TestNG-tests-1@1319658452
20 | 20/07/17 19:11:55 17982 >>setup
21 | TestNG-tests-3@1246841284
22 | 20/07/17 19:11:58 20843 >>setup
23 | TestNG-tests-2@1631315962
24 | 20/07/17 19:11:53 15681 <<tearDown
25 | TestNG-tests-1@1319658452
26 | 20/07/17 19:11:55 17432 <<tearDown
27 | TestNG-tests-3@1246841284
28 | 20/07/17 19:11:56 19305 <<tearDown
29 | TestNG-tests-2@1631315962
30 | 20/07/17 19:12:04 26883 <<tearDown
31 | TestNG-tests-3@1246841284
32 | 20/07/17 19:12:07 29760 <<tearDown
33 | TestNG-tests-1@1319658452
34 | 20/07/17 19:12:15 37383 <<tearDown
35 | TestNG-tests-2@1631315962
36 | 20/07/17 19:11:48 10538 verifyLogo
37 | TestNG-tests-3@1246841284
38 | 20/07/17 19:11:53 15395 verifyLogo
39 | TestNG-tests-1@1319658452
40 | 20/07/17 19:11:56 19137 verifyLogo
41 | TestNG-tests-2@1631315962
42 | 20/07/17 19:12:04 26509 verifyTitle
43 | TestNG-tests-3@1246841284
44 | 20/07/17 19:12:07 29724 verifyTitle
45 | TestNG-tests-1@1319658452
46 | 20/07/17 19:12:14 37322 verifyTitle
47 | TestNG-tests-2@1631315962
48 |
49 |
--------------------------------------------------------------------------------
/MyStoreProject/test-output/Suite/Test_All.html:
--------------------------------------------------------------------------------
1 |
2 |
3 | TestNG: Test_All
4 |
5 |
6 |
7 |
11 |
53 |
54 |
55 |
56 | Test_All
57 |
58 | Tests passed/Failed/Skipped: 8/2/0
59 |
60 | Started on: Fri Jul 17 23:37:28 IST 2020
61 |
62 | Total time: 278 seconds (278888 ms)
63 |
64 | Included groups:
65 |
66 | Excluded groups:
67 |
68 |
69 | (Hover the method name to see the test class name)
70 |
71 | FAILED TESTS
72 | Test method
73 | Exception
74 | Time (seconds)
75 | Instance
76 |
77 |
78 | orderHistoryandDetailsTest Test class: com.mystore.testcases.HomePageTest Parameters: admin@xyz.com, admin@123
79 | java.lang.AssertionError: expected [true] but found [false]
80 | at com.mystore.testcases.HomePageTest.orderHistoryandDetailsTest(HomePageTest.java:57)
81 | at java.util.ArrayList.forEach(ArrayList.java:1257)
82 | ... Removed 31 stack frames Click to show all stack frames
83 | java.lang.AssertionError: expected [true] but found [false]
84 | at org.testng.Assert.fail(Assert.java:97)
85 | at org.testng.Assert.failNotEquals(Assert.java:969)
86 | at org.testng.Assert.assertTrue(Assert.java:43)
87 | at org.testng.Assert.assertTrue(Assert.java:53)
88 | at com.mystore.testcases.HomePageTest.orderHistoryandDetailsTest(HomePageTest.java:57)
89 | at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
90 | at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
91 | at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
92 | at java.lang.reflect.Method.invoke(Method.java:498)
93 | at org.testng.internal.MethodInvocationHelper.invokeMethod(MethodInvocationHelper.java:134)
94 | at org.testng.internal.TestInvoker.invokeMethod(TestInvoker.java:597)
95 | at org.testng.internal.TestInvoker.invokeTestMethod(TestInvoker.java:173)
96 | at org.testng.internal.MethodRunner.runInSequence(MethodRunner.java:46)
97 | at org.testng.internal.TestInvoker$MethodInvocationAgent.invoke(TestInvoker.java:816)
98 | at org.testng.internal.TestInvoker.invokeTestMethods(TestInvoker.java:146)
99 | at org.testng.internal.TestMethodWorker.invokeTestMethods(TestMethodWorker.java:146)
100 | at org.testng.internal.TestMethodWorker.run(TestMethodWorker.java:128)
101 | at java.util.ArrayList.forEach(ArrayList.java:1257)
102 | at org.testng.TestRunner.privateRun(TestRunner.java:766)
103 | at org.testng.TestRunner.run(TestRunner.java:587)
104 | at org.testng.SuiteRunner.runTest(SuiteRunner.java:384)
105 | at org.testng.SuiteRunner.runSequentially(SuiteRunner.java:378)
106 | at org.testng.SuiteRunner.privateRun(SuiteRunner.java:337)
107 | at org.testng.SuiteRunner.run(SuiteRunner.java:286)
108 | at org.testng.SuiteRunnerWorker.runSuite(SuiteRunnerWorker.java:53)
109 | at org.testng.SuiteRunnerWorker.run(SuiteRunnerWorker.java:96)
110 | at org.testng.TestNG.runSuitesSequentially(TestNG.java:1187)
111 | at org.testng.TestNG.runSuitesLocally(TestNG.java:1109)
112 | at org.testng.TestNG.runSuites(TestNG.java:1039)
113 | at org.testng.TestNG.run(TestNG.java:1007)
114 | at org.testng.remote.AbstractRemoteTestNG.run(AbstractRemoteTestNG.java:115)
115 | at org.testng.remote.RemoteTestNG.initAndRun(RemoteTestNG.java:251)
116 | at org.testng.remote.RemoteTestNG.main(RemoteTestNG.java:77)
117 |
118 | 13
119 | com.mystore.testcases.HomePageTest@34c4973
120 |
121 | verifyTitle Test class: com.mystore.testcases.IndexPageTest
122 | java.lang.AssertionError: expected [My Store1] but found [My Store]
123 | at com.mystore.testcases.IndexPageTest.verifyTitle(IndexPageTest.java:45)
124 | at java.util.ArrayList.forEach(ArrayList.java:1257)
125 | ... Removed 32 stack frames Click to show all stack frames
126 | java.lang.AssertionError: expected [My Store1] but found [My Store]
127 | at org.testng.Assert.fail(Assert.java:97)
128 | at org.testng.Assert.assertEqualsImpl(Assert.java:136)
129 | at org.testng.Assert.assertEquals(Assert.java:118)
130 | at org.testng.Assert.assertEquals(Assert.java:575)
131 | at org.testng.Assert.assertEquals(Assert.java:585)
132 | at com.mystore.testcases.IndexPageTest.verifyTitle(IndexPageTest.java:45)
133 | at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
134 | at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
135 | at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
136 | at java.lang.reflect.Method.invoke(Method.java:498)
137 | at org.testng.internal.MethodInvocationHelper.invokeMethod(MethodInvocationHelper.java:134)
138 | at org.testng.internal.TestInvoker.invokeMethod(TestInvoker.java:597)
139 | at org.testng.internal.TestInvoker.invokeTestMethod(TestInvoker.java:173)
140 | at org.testng.internal.MethodRunner.runInSequence(MethodRunner.java:46)
141 | at org.testng.internal.TestInvoker$MethodInvocationAgent.invoke(TestInvoker.java:816)
142 | at org.testng.internal.TestInvoker.invokeTestMethods(TestInvoker.java:146)
143 | at org.testng.internal.TestMethodWorker.invokeTestMethods(TestMethodWorker.java:146)
144 | at org.testng.internal.TestMethodWorker.run(TestMethodWorker.java:128)
145 | at java.util.ArrayList.forEach(ArrayList.java:1257)
146 | at org.testng.TestRunner.privateRun(TestRunner.java:766)
147 | at org.testng.TestRunner.run(TestRunner.java:587)
148 | at org.testng.SuiteRunner.runTest(SuiteRunner.java:384)
149 | at org.testng.SuiteRunner.runSequentially(SuiteRunner.java:378)
150 | at org.testng.SuiteRunner.privateRun(SuiteRunner.java:337)
151 | at org.testng.SuiteRunner.run(SuiteRunner.java:286)
152 | at org.testng.SuiteRunnerWorker.runSuite(SuiteRunnerWorker.java:53)
153 | at org.testng.SuiteRunnerWorker.run(SuiteRunnerWorker.java:96)
154 | at org.testng.TestNG.runSuitesSequentially(TestNG.java:1187)
155 | at org.testng.TestNG.runSuitesLocally(TestNG.java:1109)
156 | at org.testng.TestNG.runSuites(TestNG.java:1039)
157 | at org.testng.TestNG.run(TestNG.java:1007)
158 | at org.testng.remote.AbstractRemoteTestNG.run(AbstractRemoteTestNG.java:115)
159 | at org.testng.remote.RemoteTestNG.initAndRun(RemoteTestNG.java:251)
160 | at org.testng.remote.RemoteTestNG.main(RemoteTestNG.java:77)
161 |
162 | 0
163 | com.mystore.testcases.IndexPageTest@17d677df
164 |
165 |
166 | PASSED TESTS
167 | Test method
168 | Exception
169 | Time (seconds)
170 | Instance
171 |
172 |
173 | addToCartTest Test class: com.mystore.testcases.AddToCartPageTest Parameters: t-shirt, 2.0, M
174 |
175 | 13
176 | com.mystore.testcases.AddToCartPageTest@33c7e1bb
177 |
178 | endToEndTest Test class: com.mystore.testcases.EndToEndTest Parameters: t-shirt, 2.0, M
179 |
180 | 38
181 | com.mystore.testcases.EndToEndTest@3043fe0e
182 |
183 | loginTest Test class: com.mystore.testcases.LoginPageTest Parameters: admin@xyz.com, admin@123
184 |
185 | 12
186 | com.mystore.testcases.LoginPageTest@76b0bfab
187 |
188 | productAvailabilityTest Test class: com.mystore.testcases.SearchResultPageTest Parameters: t-shirt
189 |
190 | 7
191 | com.mystore.testcases.SearchResultPageTest@7a765367
192 |
193 | verifyCreateAccountPageTest Test class: com.mystore.testcases.AccountCreationPageTest Parameters: ghfsdtyfg@gmail.com
194 |
195 | 10
196 | com.mystore.testcases.AccountCreationPageTest@30a3107a
197 |
198 | verifyLogo Test class: com.mystore.testcases.IndexPageTest
199 |
200 | 0
201 | com.mystore.testcases.IndexPageTest@17d677df
202 |
203 | verifyTotalPrice Test class: com.mystore.testcases.OrderPageTest Parameters: t-shirt, 2.0, M
204 |
205 | 17
206 | com.mystore.testcases.OrderPageTest@52feb982
207 |
208 | wishListTest Test class: com.mystore.testcases.HomePageTest Parameters: admin@xyz.com, admin@123
209 |
210 | 12
211 | com.mystore.testcases.HomePageTest@34c4973
212 |
213 |
214 |
--------------------------------------------------------------------------------
/MyStoreProject/test-output/old/Suite/methods.html:
--------------------------------------------------------------------------------
1 |
Methods run, sorted chronologically >> means before, << means after
Suite
(Hover the method name to see the test class name)
2 |
3 | Time Delta (ms) Suite configuration Test configuration Class configuration Groups configuration Method configuration Test method Thread Instances
4 | 20/07/17 23:37:28 0 >>loadConfig
5 | main@2050835901
6 | 20/07/17 23:37:30 2344 >>setup
7 | main@2050835901
8 | 20/07/17 23:37:47 19574 verifyCreateAccountPageTest
9 | main@2050835901
10 | 20/07/17 23:37:57 29764 <<tearDown
11 | main@2050835901
12 | 20/07/17 23:37:59 31117 >>setup
13 | main@2050835901
14 | 20/07/17 23:38:12 44709 addToCartTest
15 | main@2050835901
16 | 20/07/17 23:38:26 58438 <<tearDown
17 | main@2050835901
18 | 20/07/17 23:38:27 59344 >>setup
19 | main@2050835901
20 | 20/07/17 23:38:41 73117 orderHistoryandDetailsTest
21 | main@2050835901
22 | 20/07/17 23:38:55 86959 <<tearDown
23 | main@2050835901
24 | 20/07/17 23:38:56 87932 >>setup
25 | main@2050835901
26 | 20/07/17 23:39:09 101408 wishListTest
27 | main@2050835901
28 | 20/07/17 23:39:21 113480 <<tearDown
29 | main@2050835901
30 | 20/07/17 23:39:22 114319 >>setup
31 | main@2050835901
32 | 20/07/17 23:39:36 127840 verifyTotalPrice
33 | main@2050835901
34 | 20/07/17 23:39:53 145402 <<tearDown
35 | main@2050835901
36 | 20/07/17 23:39:54 146201 >>setup
37 | main@2050835901
38 | 20/07/17 23:40:08 160195 productAvailabilityTest
39 | main@2050835901
40 | 20/07/17 23:40:16 168063 <<tearDown
41 | main@2050835901
42 | 20/07/17 23:40:17 168975 >>setup
43 | main@2050835901
44 | 20/07/17 23:40:30 182674 loginTest
45 | main@2050835901
46 | 20/07/17 23:40:43 195118 <<tearDown
47 | main@2050835901
48 | 20/07/17 23:40:44 195900 >>setup
49 | main@2050835901
50 | 20/07/17 23:40:57 209069 verifyLogo
51 | main@2050835901
52 | 20/07/17 23:40:57 209451 <<tearDown
53 | main@2050835901
54 | 20/07/17 23:40:58 210582 >>setup
55 | main@2050835901
56 | 20/07/17 23:41:12 224315 verifyTitle
57 | main@2050835901
58 | 20/07/17 23:41:13 225567 <<tearDown
59 | main@2050835901
60 | 20/07/17 23:41:14 226804 >>setup
61 | main@2050835901
62 | 20/07/17 23:41:28 240068 endToEndTest
63 | main@2050835901
64 | 20/07/17 23:42:07 278835 <<tearDown
65 | main@2050835901
66 | 20/07/17 23:42:07 279698 <<afterSuite
67 | main@2050835901
68 |
69 |
--------------------------------------------------------------------------------