Skip to content

Instantly share code, notes, and snippets.

@zmoazeni
Created July 9, 2009 14:05
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 zmoazeni/143693 to your computer and use it in GitHub Desktop.
Save zmoazeni/143693 to your computer and use it in GitHub Desktop.
describe "Some functionality" do
it "should do something" do
@variable = some_expensive_operation
@variable.should do_something
end
describe "in a specific context" do
before(:all) do
@variable = some_expensive_operation
end
it "should do another thing" do
@variable.should do_another_thing
end
end
def some_expensive_operation
p "in here"
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment