Skip to content

Instantly share code, notes, and snippets.

@wycats
Created October 3, 2008 20:59
Show Gist options
  • Save wycats/14642 to your computer and use it in GitHub Desktop.
Save wycats/14642 to your computer and use it in GitHub Desktop.
module Kernel
def given(*args, &example_group_block)
args << {} unless Hash === args.last
params = args.last
params[:shared] = true
describe(*args) do
before(:each) do
self.instance_eval(&example_group_block)
end
end
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment