Skip to content

Instantly share code, notes, and snippets.

@dchelimsky
Created October 6, 2008 18:01
Show Gist options
  • Save dchelimsky/15086 to your computer and use it in GitHub Desktop.
Save dchelimsky/15086 to your computer and use it in GitHub Desktop.
GIVENS = {}
def given name, &block
GIVENS[name] = &block
end
config.extend_group_on(:given) do |given, group|
group.before(:each) do
GIVENS[give].call
end
end
given "logged in" do
login
end
describe "home page", :given => "logged in" do
..
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment