Skip to content

Instantly share code, notes, and snippets.

@benhoskings
Created September 3, 2009 08:29
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 benhoskings/180188 to your computer and use it in GitHub Desktop.
Save benhoskings/180188 to your computer and use it in GitHub Desktop.
class Foo
def done?
false
end
def indirect_done?
done?
end
end
describe "Foo#done?" do
before {
foo.stub!(:done?).and_return(true)
}
it "is behaving strangely" do
foo.done? # => true
foo.indirect_done? # => false
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment