Skip to content

Instantly share code, notes, and snippets.

@jlstr
Created March 23, 2012 01:32
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 jlstr/2166049 to your computer and use it in GitHub Desktop.
Save jlstr/2166049 to your computer and use it in GitHub Desktop.
First Feature from Cuke book
Given /^the input "([^"]*)"$/ do |input|
@input = input
end
When /^the calculator is run$/ do
@output = "ruby calc.rb #{@input}"
raise "Command failed!" unless $?.success?
end
Then /^the output should be "([^"]*)"$/ do |arg1|
pending # express the regexp above with the code you wish you had
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment