lib/cancan/matchers.rb in cancan-1.3.2 vs lib/cancan/matchers.rb in cancan-1.3.3
- old
+ new
@@ -1,5 +1,6 @@
-Spec::Matchers.define :be_able_to do |*args|
+RSpec = Spec unless defined? RSpec # for RSpec 1 compatability
+RSpec::Matchers.define :be_able_to do |*args|
match do |ability|
ability.can?(*args)
end
failure_message_for_should do |ability|