use of com.coveros.selenified.application.App in project selenified by Coveros.
the class ActionGetIT method getCookieExpirationTest.
@Test(groups = { "integration", "actions", "get", "cookie" }, description = "An integration test to check the getCookieExpiration method")
public void getCookieExpirationTest() throws IOException, ParseException {
// the cookie date
String dateval = "2019-12-18T12:00:00";
DateFormat df = new SimpleDateFormat("yyyy-MM-dd'T'HH:mm:ss");
df.setTimeZone(TimeZone.getTimeZone("UTC"));
// use this object to manipulate the app
App app = this.apps.get();
// perform some actions
Date cookie = app.get().cookieExpiration("cookie");
Assert.assertEquals(cookie, df.parse(dateval));
// verify no issues
finish();
}
use of com.coveros.selenified.application.App in project selenified by Coveros.
the class ActionGetIT method getAllAttributeNoneTest.
@Test(groups = { "integration", "actions", "get" }, description = "An integration test to check the getAllAttribute method")
public void getAllAttributeNoneTest() {
// use this object to manipulate the app
App app = this.apps.get();
// perform some actions
Map<String, String> attributes = app.newElement(Locator.TAGNAME, "thead", 0).get().allAttributes();
Map<String, String> expected = new HashMap<>();
Assert.assertEquals(attributes, expected);
// verify no issues
finish();
}
use of com.coveros.selenified.application.App in project selenified by Coveros.
the class ActionGetIT method getCssWonkyTest.
@Test(groups = { "integration", "actions", "get" }, description = "An integration test to check the getCss method")
public void getCssWonkyTest() {
// use this object to manipulate the app
App app = this.apps.get();
// perform some actions
String css = app.newElement(Locator.ID, "disable_click", 0).get().css("some-bad-css-attribute");
Assert.assertEquals(css, "");
// verify no issues
finish();
}
use of com.coveros.selenified.application.App in project selenified by Coveros.
the class ActionGetIT method negativeGetCookieDomainTest.
@Test(groups = { "integration", "actions", "get", "cookie" }, description = "An integration negative test to check the getCookieDomain method")
public void negativeGetCookieDomainTest() {
// use this object to manipulate the app
App app = this.apps.get();
// perform some actions
String cookie = app.get().cookieDomain("badcookie");
Assert.assertNull(cookie);
// verify no issues
finish();
}
use of com.coveros.selenified.application.App in project selenified by Coveros.
the class ActionGetIT method getSelectOptionsNotExistTest.
@Test(groups = { "integration", "actions", "get" }, description = "An integration test to check the getSelectOptions method")
public void getSelectOptionsNotExistTest() {
// use this object to manipulate the app
App app = this.apps.get();
// perform some actions
String[] options = app.newElement(Locator.NAME, "non-existent-name", 0).get().selectOptions();
Assert.assertNull(options);
// verify no issues
finish();
}
Aggregations