Skip to content

Commit

Permalink
Add tests for should.==
Browse files Browse the repository at this point in the history
Proposed by Gabriel Horner <[email protected]>.
  • Loading branch information
leahneukirchen committed Mar 16, 2012
1 parent ce75f62 commit 799cb3b
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions test/spec_bacon.rb
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,14 @@ def equal_string(x)
lambda { 2.should.satisfy { |n| n % 2 == 0 } }.should succeed
end

it "should have should.==" do
lambda { "string1".should == "string1" }.should succeed
lambda { "string1".should == "string2" }.should fail

lambda { [1,2,3].should == [1,2,3] }.should succeed
lambda { [1,2,3].should == [1,2,4] }.should fail
end

it "should have should.equal" do
lambda { "string1".should == "string1" }.should succeed
lambda { "string1".should == "string2" }.should fail
Expand Down

0 comments on commit 799cb3b

Please sign in to comment.