Skip to content

Instantly share code, notes, and snippets.

@kuronekomichael
Created December 13, 2013 10:16
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save kuronekomichael/7942348 to your computer and use it in GitHub Desktop.
Save kuronekomichael/7942348 to your computer and use it in GitHub Desktop.
Selenium RCからWebDriverに移行するための、シンプルな4つの手順
// 良くない例:<body>の中のテキストを全て取得して検証している
String text = selenium.getBodyText();
assertTrue(text.contains("hello"));
WebElement body = webdriver.findElement(
By.tagName("body"));
String text = body.getText();
assertTrue(text.contains("hello"));
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment