Skip to content

Instantly share code, notes, and snippets.

@james-prickett
Created March 6, 2011 18:53
Show Gist options
  • Select an option

  • Save james-prickett/857535 to your computer and use it in GitHub Desktop.

Select an option

Save james-prickett/857535 to your computer and use it in GitHub Desktop.
a simple spoc test
import java.io.File;
class HomePageTests extends BaseSpec {
def "Load the home page correctly"() {
when:
go "/"
then:
$("h1").text() == "movie"
$("div.clickable").size() > 0
}
def "Verify that the movie view loads correctly"() {
when:
go "/"
$("div.clickable", onclick: contains("3510")).click()
then:
waitFor { $("span.movie-title").text() == "127 Hours" }
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment