Skip to content

Instantly share code, notes, and snippets.

@xconnecting
Created June 10, 2013 06:36
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 xconnecting/5746907 to your computer and use it in GitHub Desktop.
Save xconnecting/5746907 to your computer and use it in GitHub Desktop.
[Groovy] cucumber-jvm-groovy sample (step definition - pending)
import cucumber.runtime.PendingException
this.metaClass.mixin(cucumber.runtime.groovy.Hooks)
this.metaClass.mixin(cucumber.runtime.groovy.EN)
Given(~'^I have a hello app with "([^"]*)"$') { String arg1 ->
// Express the Regexp above with the code you wish you had
throw new PendingException()
}
When(~'^I ask it to say hi$') { ->
// Express the Regexp above with the code you wish you had
throw new PendingException()
}
Then(~'^it should answer with "([^"]*)"$') { String arg1 ->
// Express the Regexp above with the code you wish you had
throw new PendingException()
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment