Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public void click(WebDriver driver) throws InterruptedException {
- WebDriverWait wait = new WebDriverWait(driver, 30);
- try {
- Thread.sleep(3000);
- WebElement table = driver.findElement(By.className("ng-star-inserted"));
- List<WebElement> allrows = table.findElements(By.tagName("tr"));
- // List<WebElement> allcols = table.findElements(By.tagName("td"));
- Thread.sleep(2000);
- for(WebElement row: allrows) {
- List<WebElement> Cells = row.findElements(By.tagName("td"));
- for(WebElement Cell:Cells) {
- if (Cell.getText().contains("COASTAL"))
- Cell.click();
- }
- }
- Thread.sleep(2000);
- System.out.println("Welcome");
- Thread.sleep(10000);
- wait.until(ExpectedConditions.visibilityOfElementLocated(By.id("call-caseDetail"))).click();
- System.out.println("first row is clicked");
- createDirector(wait, driver);
- updateDirector(wait, driver);
- deleteDirector(driver);
- }
- catch (Exception e) {
- System.out.println("Timeout " + e);
- }
- koganName = driver.findElement(By.xpath(("//div[@class='row p-3']/div/div/div/dl/dt[1]/following-sibling::dd[1]"))).getText();
- koganName = driver.findElement(By.xpath(("//div[@class='row mb-1']//dd[1]")).getText();
- koganName = driver.findElement(By.xpath(("//div[@class='row mb-1']//dt[text() = 'Name:']/following-sibling::dd[1]")).getText();
Add Comment
Please, Sign In to add comment