forked from BugorDmitriy/OpenWeatherJavaProject
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathBulkPage.java
More file actions
44 lines (29 loc) · 1016 Bytes
/
Copy pathBulkPage.java
File metadata and controls
44 lines (29 loc) · 1016 Bytes
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
package pages;
import org.openqa.selenium.WebDriver;
import org.openqa.selenium.WebElement;
import org.openqa.selenium.support.FindBy;
import pages.base_abstract.FooterMenuPage;
import java.util.ArrayList;
import java.util.List;
public class BulkPage extends FooterMenuPage<BulkPage> {
@FindBy(xpath = "//section[@id='how']/h2")
private WebElement h2Header;
@FindBy(xpath = "//div[@class='api']/*")
private List<WebElement> bulkFilesRequests;
public BulkPage(WebDriver driver) {
super(driver);
}
public BulkPage createGeneric() {
return new BulkPage(getDriver());
}
public String getH2Header() {
return getText(h2Header);
}
public List<String> getBulkFilesRequests() {
List<String> bulkFilesRequestsText = new ArrayList<>();
for (int i = 0; i < getListSize(bulkFilesRequests); i += 2) {
bulkFilesRequestsText.add(getText(bulkFilesRequests.get(i)));
}
return bulkFilesRequestsText;
}
}