29 lines
777 B
Java
29 lines
777 B
Java
package grant;
|
|
|
|
import core.PageObject;
|
|
import org.openqa.selenium.By;
|
|
import org.openqa.selenium.WebElement;
|
|
|
|
import java.util.List;
|
|
|
|
public class KiasPage extends PageObject {
|
|
@Override
|
|
public String getSubTitle() {
|
|
return driver.findElement(By.tagName("h1")).getText();
|
|
}
|
|
|
|
public List<WebElement> getGrants() {
|
|
WebElement listContest = driver.findElement(By.tagName("tBody"));
|
|
return listContest.findElements(By.cssSelector("tr.tr"));
|
|
|
|
}
|
|
|
|
public String getGrantTitle(WebElement grant) {
|
|
return grant.findElement(By.cssSelector("td.tertiary")).findElement(By.tagName("a")).getText();
|
|
}
|
|
|
|
public String getFirstDeadline(WebElement grant) {
|
|
return grant.findElement(By.xpath("./td[5]")).getText();
|
|
}
|
|
}
|