diff --git a/Kochkaleva/pom.xml b/Kochkaleva/pom.xml new file mode 100644 index 0000000..c1f1a82 --- /dev/null +++ b/Kochkaleva/pom.xml @@ -0,0 +1,56 @@ + + + 4.0.0 + + kochkaleva_labs + kochkaleva_labs + 1.0-SNAPSHOT + + + + + org.apache.maven.plugins + maven-compiler-plugin + + 8 + 8 + + + + + + + + org.seleniumhq.selenium + selenium-java + 3.7.1 + + + + org.junit.jupiter + junit-jupiter-api + 5.1.0-RC1 + + + + com.github.javafaker + javafaker + 0.16 + + + org.junit.jupiter + junit-jupiter-api + RELEASE + test + + + junit + junit + 4.12 + test + + + + \ No newline at end of file diff --git a/Kochkaleva/src/main/resources/chromedriver b/Kochkaleva/src/main/resources/chromedriver new file mode 100644 index 0000000..02ff671 Binary files /dev/null and b/Kochkaleva/src/main/resources/chromedriver differ diff --git a/Kochkaleva/src/main/resources/chromedriver.exe b/Kochkaleva/src/main/resources/chromedriver.exe new file mode 100644 index 0000000..4bfff1e Binary files /dev/null and b/Kochkaleva/src/main/resources/chromedriver.exe differ diff --git a/Kochkaleva/src/test/java/helpers/ChromeContext.java b/Kochkaleva/src/test/java/helpers/ChromeContext.java new file mode 100644 index 0000000..23f7d6c --- /dev/null +++ b/Kochkaleva/src/test/java/helpers/ChromeContext.java @@ -0,0 +1,25 @@ +package helpers; + +import org.openqa.selenium.chrome.ChromeDriver; + +public class ChromeContext extends Context { + private final static String WINDOWS_DRIVER = "chromedriver.exe"; + private final static String LINUX_DRIVER = "chromedriver"; + private final static String DRIVER_TYPE = "webdriver.chrome.driver"; + + @Override + protected void createDriver() { + driver = new ChromeDriver(); + } + + @Override + protected String getDriverExecutable(boolean isWindows) { + return isWindows ? WINDOWS_DRIVER : LINUX_DRIVER; + } + + @Override + protected String getDriverType() { + return DRIVER_TYPE; + } +} + diff --git a/Kochkaleva/src/test/java/helpers/Context.java b/Kochkaleva/src/test/java/helpers/Context.java new file mode 100644 index 0000000..0eb27cf --- /dev/null +++ b/Kochkaleva/src/test/java/helpers/Context.java @@ -0,0 +1,45 @@ +package helpers; + +import org.openqa.selenium.WebDriver; +import org.openqa.selenium.chrome.ChromeDriver; + +import java.util.Objects; +import java.util.concurrent.TimeUnit; + +public abstract class Context { + private final static String DRIVER_LOCATION = "src\\main\\resources\\chromedriver.exe"; + protected WebDriver driver; + + public WebDriver getDriver() { + if (driver != null) { + return driver; + } + throw new IllegalStateException("WebDriver is not initialized"); + } + + public void start() { + System.setProperty("webdriver.chrome.driver", "src\\main\\resources\\chromedriver.exe"); + driver = new ChromeDriver(); + driver.manage().timeouts().implicitlyWait(10, TimeUnit.SECONDS); + } + + public void close() { + driver.quit(); + } + + protected abstract void createDriver(); + + protected abstract String getDriverType(); + + protected abstract String getDriverExecutable(boolean windows); + + private String getDriverExecutablePath() { + System.setProperty("webdriver.chrome.driver", DRIVER_LOCATION); + + return null; + } + + private boolean isWindows() { + return System.getProperty("os.name").toLowerCase().contains("windows"); + } +} diff --git a/Kochkaleva/src/test/java/pages/Email.java b/Kochkaleva/src/test/java/pages/Email.java new file mode 100644 index 0000000..9eca1c7 --- /dev/null +++ b/Kochkaleva/src/test/java/pages/Email.java @@ -0,0 +1,86 @@ +package pages; + +import com.github.javafaker.Faker; +import helpers.Context; +import org.openqa.selenium.By; +import org.openqa.selenium.Keys; +import org.openqa.selenium.WebDriver; +import org.openqa.selenium.WebElement; +import org.openqa.selenium.support.FindBy; +import org.openqa.selenium.support.PageFactory; + +import java.util.concurrent.TimeUnit; + + +public class Email { + + private WebDriver driver; + private Context context; + Faker faker = new Faker(); + + public Email(WebDriver driver) { + PageFactory.initElements(driver, this); + this.driver = driver; + } + + @FindBy(name = "email") + private WebElement emailField; + + @FindBy(xpath = "//*[@id=\"subscribe_submit\"]") + private WebElement submitButton; + + @FindBy(xpath = "//*[@id=\"subscribePopup\"]/div[1]") + private WebElement succsessAlert; + + @FindBy(id = "loginRef") + private WebElement logInLink; + + @FindBy(name = "login") + private WebElement loginField; + + @FindBy(name = "password") + private WebElement passwordField; + + @FindBy(id = "loginPopupButtonID") + private WebElement logInButton; + + + + public void emailService() { + String firstPart = faker.name().firstName(); + String secondPart = faker.name().lastName(); + String domen = faker.app().name(); + emailField.sendKeys(Keys.chord(Keys.CONTROL, "v") + firstPart + secondPart + "@" + domen + ".com"); + } + + public void submitButtonClick() { + submitButton.click(); + } + + public boolean setSuccsessAlert() { + return driver.findElement(By.xpath("//*[@id=\"subscribePopup\"]/div[1]")).isDisplayed(); + + } + + public void logInLinkCLick() { + logInLink.click(); + } + + public void fillFields(String email,String password) { + emailField.sendKeys(email); + passwordField.sendKeys(password); + } + + public void logInButtonClick() { + logInButton.click(); + context.getDriver().manage().timeouts().implicitlyWait(10, TimeUnit.SECONDS); + } + + public boolean canClickLogInButton() { + return driver.findElement(By.id("loginPopupButtonID")).isEnabled(); + } + + public boolean logInButtonDisplayed() { + return logInButton.isDisplayed(); + } +} diff --git a/Kochkaleva/src/test/java/pages/Navigation.java b/Kochkaleva/src/test/java/pages/Navigation.java new file mode 100644 index 0000000..7cddf8a --- /dev/null +++ b/Kochkaleva/src/test/java/pages/Navigation.java @@ -0,0 +1,87 @@ +package pages; + +import org.openqa.selenium.WebDriver; +import org.openqa.selenium.WebElement; +import org.openqa.selenium.support.FindBy; +import org.openqa.selenium.support.PageFactory; + + +public class Navigation { + + private WebDriver driver; + + public Navigation(WebDriver driver) { + PageFactory.initElements(driver, this); + this.driver = driver; + } + + @FindBy(xpath = "/html/body/div[7]/div[1]/div/div[4]/div/a[1]") + private WebElement yesCityButton; + + @FindBy(id = "cat_cat308680401") + private WebElement saleLink; + + @FindBy(xpath = "//*[@id=\"cat_cat308680401\"]/div/div/div/div/ul/li[1]/a") + private WebElement saleFemaleLink; + + @FindBy(xpath = "//*[@id=\"atg_store_footer\"]/div[2]/div/div/div/div[1]/a[2]") + private WebElement basementLink; + + @FindBy(xpath = "//*[@id=\"atg_store_footer\"]/div[3]/div/ul/li[2]/div[1]/div/a[2]") + private WebElement socialElementLink; + + @FindBy(xpath = "//*[@id=\"group\"]/div[1]/div[2]/div[2]/h2") + private WebElement pageName; + + @FindBy(xpath = "//*[@id=\"atg_store_content\"]/div[2]/ul/li[1]") + private WebElement displayedPromo; + + @FindBy(xpath = "//*[@id=\"atg_store_content\"]/div[2]/div[2]/div[1]/h1") + private WebElement mainTitle; + + @FindBy(xpath = "//*[@id=\"atg_store_content\"]/div/div[1]/div/div[1]/a") + private WebElement womenSales; + + public boolean womaneSalesLink() { + return womenSales.isDisplayed(); + } + + public boolean setMainTitle() { + return mainTitle.isDisplayed(); + } + + public boolean setDisplayedPromo() { + return displayedPromo.isDisplayed(); + } + + public boolean setPageName() { + return pageName.isDisplayed(); + } + + private void setCurrentCity() { + if (yesCityButton != null) { + yesCityButton.click(); + } + } + + public void saleLinkClick() { + setCurrentCity(); + saleLink.click(); + } + + public void saleFemaleLinkClick() { + setCurrentCity(); + saleFemaleLink.click(); + } + + public void basementLinkClick() { + setCurrentCity(); + basementLink.click(); + } + + public void socialElementLinkClcik() { + setCurrentCity(); + socialElementLink.click(); + } + +} diff --git a/Kochkaleva/src/test/java/pages/Recyclebin.java b/Kochkaleva/src/test/java/pages/Recyclebin.java new file mode 100644 index 0000000..cfe8b7a --- /dev/null +++ b/Kochkaleva/src/test/java/pages/Recyclebin.java @@ -0,0 +1,69 @@ +package pages; + +import helpers.Context; +import org.openqa.selenium.By; +import org.openqa.selenium.WebDriver; +import org.openqa.selenium.WebElement; +import org.openqa.selenium.support.FindBy; +import org.openqa.selenium.support.PageFactory; + +import java.util.concurrent.TimeUnit; + +public class Recyclebin { + + private WebDriver driver; + private Context context; + + public Recyclebin(WebDriver driver) { + PageFactory.initElements(driver, this); + this.driver = driver; + } + + @FindBy(xpath = "//*[@id=\"sc_19836410299\"]") + private WebElement color; + + @FindBy(id = "size_170398140299") + private WebElement pickSize; + + @FindBy(id = "addItemToOrderID") + private WebElement addToCartButton; + + @FindBy(xpath = "//*[@id=\"headerCart\"]/a") + private WebElement toCart; + + @FindBy(xpath = "//*[@id=\"cartPopup\"]/div[2]/div[2]/div[2]/a") + private WebElement followCart; + + @FindBy(xpath = "//*[@id=\"atg_store_content\"]/div[9]/div[2]/div/div/ul/li[1]/div/a/img") + private WebElement imagePoint; + + @FindBy(xpath = "//*[@id=\"atg_store_content\"]/div[9]/div[2]/div/div/a") + private WebElement removeLink; + + public void pickSizeClick() { + pickSize.click(); + } + public void colorClick() { + color.click(); + context.getDriver().manage().timeouts().pageLoadTimeout(10, TimeUnit.SECONDS); + } + + public void addToCartButtonClick() { + addToCartButton.click(); + } + + public boolean afterClick() { + return driver.findElement(By.xpath("//*[@id=\"cartPopup\"]/div[2]/div[2]/div[2]/a")).isDisplayed(); + } + + public void toCartClick() { + context.getDriver().manage().timeouts().implicitlyWait(10, TimeUnit.SECONDS); + toCart.click(); + context.getDriver().manage().timeouts().pageLoadTimeout(10, TimeUnit.SECONDS); + followCart.click(); + } + + public boolean removeItem() { + return !imagePoint.isDisplayed(); + } +} diff --git a/Kochkaleva/src/test/java/pages/Sort.java b/Kochkaleva/src/test/java/pages/Sort.java new file mode 100644 index 0000000..35c6d72 --- /dev/null +++ b/Kochkaleva/src/test/java/pages/Sort.java @@ -0,0 +1,150 @@ +package pages; + +import helpers.Context; +import org.openqa.selenium.By; +import org.openqa.selenium.Keys; +import org.openqa.selenium.WebDriver; +import org.openqa.selenium.WebElement; +import org.openqa.selenium.support.FindBy; +import org.openqa.selenium.support.PageFactory; + +import java.util.concurrent.TimeUnit; + +public class Sort { + + private WebDriver driver; + private static Context context; + + public Sort(WebDriver driver) { + PageFactory.initElements(driver, this); + this.driver = driver; + } + + @FindBy(xpath = "//*[@id=\"atg_store_content\"]/div[2]/div[2]/div[1]/div/form/div/i") + private WebElement sortDropDown; + + @FindBy(xpath = "//*[@id=\"atg_store_content\"]/div[2]/div[2]/div[1]/div/form/div/div/div[2]/ul/li[4]") + private WebElement sortBySales; + + @FindBy(xpath = "//*[@id=\"atg_store_content\"]/div[2]/div[2]/div[1]/div/form/div/span") + private WebElement sortLabel; + + @FindBy(xpath = "//*[@id=\"atg_store_content\"]/div[2]/div[2]/div[2]/form/div[1]/i") + private WebElement dropDownSize; + + @FindBy(xpath = "//*[@id=\"atg_store_content\"]/div[2]/div[2]/div[2]/form/div[1]/div/div[2]/ul/div/div/li[1]/" + + "label/input") + private WebElement checkBoxSize; + + @FindBy(xpath = "//*[@id=\"atg_store_content\"]/div[2]/div[2]/div[2]/form/div[2]/i") + private WebElement dropDownColor; + + @FindBy(xpath = "//*[@id=\"atg_store_content\"]/div[2]/div[2]/div[2]/form/div[2]/div/div[2]/ul/li[1]/label/span/i") + private WebElement checkBoxColor; + + @FindBy(xpath = "//*[@id=\"atg_store_content\"]/div[2]/div[2]/div[2]/form/div[3]/i") + private WebElement dropDownCost; + + @FindBy(xpath = "//*[@id=\"searchPriceSliderMin\"]") + private WebElement minCostField; + + @FindBy(xpath = "//*[@id=\"atg_store_content\"]/div[2]/div[2]/div[2]/form/div[3]/div/div[2]/a") + private WebElement submitButton; + + @FindBy(xpath = "//*[@id=\"searchForm\"]/a") + private WebElement searchButton; + + @FindBy(id = "atg_store_searchInput") + private WebElement searchField; + + @FindBy(xpath = "//*[@id=\"atg_store_content\"]/div[2]/div[2]/div[3]/div/div/b[1]") + private WebElement searchingRequset; + + public void setSearchingRequset() { + if (searchingRequset != null) { + + } else { + throw new IllegalStateException(" this"); + } + } + + public static int random(int lowerBound, int upperBound) { + return (lowerBound + (int) Math.round(Math.random() + * (upperBound - lowerBound))); + } + + public void sortDropDownClick() { + sortDropDown.click(); + context.getDriver().manage().timeouts().implicitlyWait(10, TimeUnit.SECONDS); + } + + public boolean checkForDisplayed() { + return driver.findElement(By + .xpath("//*[@id=\"atg_store_content\"]/div[2]/div[2]/div[1]/div/form/div/div/div[2]/ul/li[1]")) + .isDisplayed(); + } + + public void sortBySalesClick() { + sortBySales.click(); + context.getDriver().manage().timeouts().implicitlyWait(5, TimeUnit.SECONDS); + } + + public boolean checkForSalesDisplayed() { + return driver.findElement(By.xpath("//*[@id=\"atg_store_content\"]/div[2]/div[2]/div[1]/div/form/div/span")) + .isDisplayed(); + } + + public String setSortLabel() { + String labelText = sortLabel.getAttribute("innerText"); + return labelText; + } + + public void sizeFilter() { + dropDownSize.click(); + checkBoxSize.click(); + WebElement submit = driver.findElement(By + .xpath("//*[@id=\"atg_store_content\"]/div[2]/div[2]/div[2]/form/div[1]/div/div[2]/a")); + submit.click(); + } + + public boolean checkForSize() { + return driver.findElement(By.cssSelector("//*[@id=\"atg_store_content\"]" + + "/div[2]/div[2]/div[2]/form/div[1]/label")).isDisplayed(); + } + + public void colorFilter() { + dropDownColor.click(); + checkBoxColor.click(); + WebElement submit = driver.findElement(By + .xpath("//*[@id=\"atg_store_content\"]/div[2]/div[2]/div[2]/form/div[1]/div/div[2]/a")); + submit.click(); + } + + public boolean checkForColor() { + return driver.findElement(By.xpath("//*[@id=\"atg_store_content\"]/div[2]/div[2]/div[2]/form/div[2]/i")) + .isDisplayed(); + } + + public void costFilter() { + int cost = random(1500, 5000); + dropDownCost.click(); + minCostField.sendKeys(Integer.toString(cost)); + submitButton.click(); + } + + public boolean checkForCost() { + return driver.findElement(By.xpath("//*[@id=\"atg_store_content\"]/div[2]/div[2]/div[2]/form/div[3]/i")) + .isDisplayed(); + } + + public void searching(String type) { + searchButton.click(); + searchField.sendKeys(type, Keys.RETURN); + context.getDriver().manage().timeouts().pageLoadTimeout(10, TimeUnit.SECONDS); + } + + public boolean checkForResultSearching() { + return driver.findElement(By.xpath("//*[@id=\"atg_store_content\"]/div[2]/div[2]/div[1]/h1")).isDisplayed(); + } + +} diff --git a/Kochkaleva/src/test/java/tests/EmailTests.java b/Kochkaleva/src/test/java/tests/EmailTests.java new file mode 100644 index 0000000..779cf94 --- /dev/null +++ b/Kochkaleva/src/test/java/tests/EmailTests.java @@ -0,0 +1,65 @@ +package tests; + +import helpers.ChromeContext; +import helpers.Context; +import org.junit.jupiter.api.Assertions; +import org.openqa.selenium.support.PageFactory; +import pages.Email; + +import org.junit.*; +import org.junit.jupiter.api.BeforeAll; +import org.junit.jupiter.api.Test; + +import org.openqa.selenium.WebDriver; + + +public class EmailTests { + + private static Email email; + private static Context context; + private final static String URL = "https://ostin.com/"; + + @BeforeAll + public static void setUp() { + + context = new ChromeContext(); + context.start(); + + context.getDriver().manage().window().maximize(); + context.getDriver().get(URL); + email = new Email((WebDriver) context); + } + + @Test + public void checkForFollow() throws InterruptedException { + Thread.sleep(3000); + email.emailService(); + email.submitButtonClick(); + Email email = PageFactory.initElements(context.getDriver(), Email.class); + Assertions.assertTrue(email.setSuccsessAlert()); + } + + @Test + public void checkForLogIn() { + email.logInLinkCLick(); + email.fillFields("lkdlfr@mail.ru", "jhbhjbjbj"); + email.logInButtonClick(); + PageFactory.initElements(context.getDriver(), Email.class); + Assertions.assertTrue(email.canClickLogInButton()); + } + + @Test + public void checkForLogOut() { + email.logInLinkCLick(); + email.fillFields("asda@dasd.asd", "12312eqs"); + email.logInButtonClick(); + PageFactory.initElements(context.getDriver(), Email.class); + Assertions.assertTrue(email.logInButtonDisplayed()); + } + + @After + public void quit() { + context.getDriver().quit(); + } + +} diff --git a/Kochkaleva/src/test/java/tests/NavigationTests.java b/Kochkaleva/src/test/java/tests/NavigationTests.java new file mode 100644 index 0000000..5bcc067 --- /dev/null +++ b/Kochkaleva/src/test/java/tests/NavigationTests.java @@ -0,0 +1,71 @@ +package tests; + +import com.google.common.collect.Iterators; + +import helpers.ChromeContext; +import helpers.Context; +import org.junit.After; +import org.junit.Before; +import org.junit.Test; + +import org.junit.jupiter.api.Assertions; +import org.openqa.selenium.WebDriver; + +import org.openqa.selenium.support.PageFactory; +import pages.Navigation; + +import java.util.Set; + +public class NavigationTests { + + private static Context context; + private static Navigation navigation; + private final static String URL = "https://ostin.com/"; + + @Before + public static void setUp() { + context = new ChromeContext(); + context.start(); + context.getDriver().manage().window().maximize(); + context.getDriver().get(URL); + + navigation = new Navigation((WebDriver) context); + } + + @Test + public void checkForSaleRedirect() { + navigation.saleLinkClick(); + navigation.womaneSalesLink(); + PageFactory.initElements(context.getDriver(), Navigation.class); + Assertions.assertTrue(navigation.womaneSalesLink()); + } + + @Test + public void checkForFemalesSaleRedirect() { + navigation.saleFemaleLinkClick(); + PageFactory.initElements(context.getDriver(), Navigation.class); + Assertions.assertTrue(navigation.setMainTitle()); + } + + @Test + public void checkForBasementLinkRedirect() { + navigation.basementLinkClick(); + PageFactory.initElements(context.getDriver(), Navigation.class); + Assertions.assertTrue(navigation.setDisplayedPromo()); + } + + @Test + public void checkForFollowSocialLink() { + navigation.socialElementLinkClcik(); + Set tabs = context.getDriver().getWindowHandles(); + context.getDriver().switchTo().window(Iterators.getLast(tabs.iterator())); + PageFactory.initElements(context.getDriver(), Navigation.class); + Assertions.assertTrue(navigation.setPageName()); + } + + @After + public void quit() { + context.getDriver().quit(); + } + +} diff --git a/Kochkaleva/src/test/java/tests/RecylebinTests.java b/Kochkaleva/src/test/java/tests/RecylebinTests.java new file mode 100644 index 0000000..8a080ed --- /dev/null +++ b/Kochkaleva/src/test/java/tests/RecylebinTests.java @@ -0,0 +1,56 @@ +package tests; + +import helpers.ChromeContext; +import helpers.Context; +import org.junit.jupiter.api.Assertions; +import org.openqa.selenium.support.PageFactory; +import pages.Recyclebin; + +import org.junit.After; +import org.junit.Test; +import org.junit.jupiter.api.BeforeAll; + +import org.openqa.selenium.WebDriver; + + +public class RecylebinTests { + + private static Recyclebin recyclebin; + private static Context context; + private final static String URL = "https://ostin.com/ru/ru/catalog/jenskaya_odejda/" + + "jenskaya_verhnyaya_odejda/jenskie_kurtki_i_vetrovki/156777240299/?scId=19836410299"; + + @BeforeAll + public void setUp() { + context = new ChromeContext(); + context.start(); + context.getDriver().manage().window().maximize(); + context.getDriver().get(URL); + + recyclebin = new Recyclebin((WebDriver) context); + } + + @Test + public void checkForAddItemToCart() { + recyclebin.colorClick(); + recyclebin.pickSizeClick(); + recyclebin.addToCartButtonClick(); + PageFactory.initElements(context.getDriver(), Recyclebin.class); + Assertions.assertTrue(recyclebin.afterClick()); + } + + @Test + public void checkForRemoveItem() { + recyclebin.toCartClick(); + + recyclebin.removeItem(); + PageFactory.initElements(context.getDriver(), Recyclebin.class); + Assertions.assertTrue(recyclebin.removeItem()); + } + + @After + public void quit() { + context.getDriver().quit(); + } + +} diff --git a/Kochkaleva/src/test/java/tests/SortTests.java b/Kochkaleva/src/test/java/tests/SortTests.java new file mode 100644 index 0000000..445bbde --- /dev/null +++ b/Kochkaleva/src/test/java/tests/SortTests.java @@ -0,0 +1,82 @@ +package tests; + +import helpers.ChromeContext; +import helpers.Context; + +import org.junit.After; +import org.junit.Before; +import org.junit.Test; + +import org.junit.jupiter.api.Assertions; +import org.openqa.selenium.WebDriver; + +import org.openqa.selenium.support.PageFactory; +import pages.Sort; + + +public class SortTests { + + private static Context context; + private static Sort sort; + private final static String URL = "https://ostin.com/ru/ru/catalog/jenskaya_odejda/jenskaya_verhnyaya_odejda/"; + private final static String SEARCH_TYPE = "куртка"; + + @Before + public void setUp() { + context = new ChromeContext(); + context.start(); + context.getDriver().get(URL); + + sort = new Sort((WebDriver) context); + } + + @Test + public void checkForSorting() { + sort.sortDropDownClick(); + PageFactory.initElements(context.getDriver(), Sort.class); + Assertions.assertTrue(sort.checkForDisplayed()); + } + + @Test + public void checkForSortingBt() { + sort.sortDropDownClick(); + sort.sortBySalesClick(); + PageFactory.initElements(context.getDriver(), Sort.class); + Assertions.assertTrue(sort.checkForSalesDisplayed()); + } + + @Test + public void checkForSizeFiltering() { + sort.sizeFilter(); + PageFactory.initElements(context.getDriver(), Sort.class); + Assertions.assertTrue(sort.checkForSize()); + } + + @Test + public void checkForColorFiltering() { + sort.colorFilter(); + PageFactory.initElements(context.getDriver(), Sort.class); + Assertions.assertTrue(sort.checkForColor()); + } + + @Test + public void checkForCostFilter() { + sort.costFilter(); + PageFactory.initElements(context.getDriver(), Sort.class); + Assertions.assertTrue(sort.checkForCost()); + } + + @Test + public void checkForSearch() { + sort.searching(SEARCH_TYPE); + sort.setSearchingRequset(); + PageFactory.initElements(context.getDriver(), Sort.class); + Assertions.assertTrue(sort.checkForResultSearching()); + } + + @After + public void quit() { + context.getDriver().quit(); + } + +}