Permalink
Browse files

add Alex's and David's solution to bug #6

  • Loading branch information...
1 parent 7180d53 commit 65b645470da3786dcbf506738b1710a59fb6bc9d @alexch committed May 15, 2011
Showing with 9 additions and 7 deletions.
  1. +9 −7 bleucheese_spec.rb
View
@@ -8,18 +8,20 @@ def smell
require "wrong"
require "wrong/adapters/rspec"
-Wrong.config.alias_assert :should
+# David's solution
+# require "rspec/expectations"
+# require "wrong"
+# require "wrong/adapters/rspec"
+# RSpec.configuration.expect_with :stdlib
-describe BleuCheese do
- it "stinks" do
- should { BleuCheese.new.smell > 9000 }
- end
+# Alex's solution
+module RSpec::Matchers
+ remove_method(:expect)
end
-
-# This test should fail, yet it passes, since RSpec aliases expect to lambda
Wrong.config.alias_assert :expect
+# This test should fail, yet it passes, since RSpec aliases expect to lambda
describe BleuCheese do
it "stinks with expect" do
expect { BleuCheese.new.smell > 9000 }

0 comments on commit 65b6454

Please sign in to comment.