Skip to content

Instantly share code, notes, and snippets.

@nobusue
Created November 5, 2011 05:30
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 nobusue/1341148 to your computer and use it in GitHub Desktop.
Save nobusue/1341148 to your computer and use it in GitHub Desktop.
コードで自己紹介 @jggug Camp 2011
@Grapes([
@Grab("org.codehaus.geb:geb-core:latest.release"),
@Grab("org.seleniumhq.selenium:selenium-firefox-driver:latest.release")
])
import geb.Browser
Browser.drive {
go "http://www.facebook.com/profile.php?id=732337788"
go "http://d.hatena.ne.jp/keyword/"
assert title == "はてなキーワード - 話題の言葉がわかる、みんなで編集するキーワード"
$("form.header-search").word = "nobusue"
$("form.header-search").find("input", name:"submit").click()
assert title == "はてな検索: nobusue"
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment