public
Created

  • Download Gist
matchers.rb
Ruby
1 2 3 4 5 6 7 8 9 10 11
RSpec::Matchers.define :permit do |*args|
match do |permission|
expect(permission.allow?(*args)).to be_true
end
end
 
RSpec::Matchers.define :permit_param do |*args|
match do |permission|
expect(permission.allow_param?(*args)).to be_true
end
end

Please sign in to comment on this gist.

Something went wrong with that request. Please try again.