Package org.openqa.selenium.chrome

Examples of org.openqa.selenium.chrome.ChromeDriver.quit()


      }
    }
   
    Thread.sleep(1000);
    System.out.println("browser will be close");
    dr.quit()
  }

}
View Full Code Here


//    ����2: ֱ�Ӷ�λlink
    dr.findElement(By.linkText("Home")).click();
   
    Thread.sleep(1000);
    System.out.println("browser will be close");
    dr.quit()
  }

}
View Full Code Here

                }
      });
           
    Thread.sleep(1000);
    System.out.println("browser will be close");
    dr.quit()
  }

}
View Full Code Here

    System.out.printf("now accesss %s \n", url);
    dr.get(url);
    Thread.sleep(2000);
   
    System.out.println("browser will be close");
    dr.quit()
  }

}
View Full Code Here

//    clear
    element.clear();
   
    Thread.sleep(1000);
    System.out.println("browser will be close");
    dr.quit()
  }

}
View Full Code Here

   
    dr.findElement(By.cssSelector("input[type=file]")).sendKeys("src/navs.html");
   
    Thread.sleep(1000);
    System.out.println("browser will be close");
    dr.quit()
  }

}
View Full Code Here

  public static void main(String[] args) {
    WebDriver dr = new ChromeDriver();
    dr.manage().window().setSize(new Dimension(240, 320));
    dr.get("http://www.3g.qq.com/");
    dr.quit();
  }

}
View Full Code Here

   
    System.out.println(dr.findElement(By.tagName("h3")).getCssValue("font"));
   
    Thread.sleep(1000);
    System.out.println("browser will be close");
    dr.quit()
  }

}
View Full Code Here

    WebElement current = dr.findElement(By.className("breadcrumb")).findElement(By.className("active"));
    System.out.println(current.getText());
   
    Thread.sleep(1000);
    System.out.println("browser will be close");
    dr.quit()
  }

}
View Full Code Here

    dr.manage().addCookie(c1);
    dr.manage().addCookie(c2);
   
    System.out.println("browser will be close");
   
    dr.quit()
  }

}
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.