Module: Shoulda::Matchers::Pundit
- Included in:
- MiniTest::Spec
- Defined in:
- lib/shoulda/matchers/pundit.rb,
lib/shoulda/matchers/pundit/version.rb
Defined Under Namespace
Classes: ForbidMatcher, PermitMatcher, PermittedToMatcher
Constant Summary
collapse
- VERSION =
"0.0.2".freeze
Instance Method Summary
collapse
Instance Method Details
#be_permitted_to(action) ⇒ Object
15
16
17
|
# File 'lib/shoulda/matchers/pundit.rb', line 15
def be_permitted_to(action)
PermittedToMatcher.new(action)
end
|
#forbid(*actions) ⇒ Object
11
12
13
|
# File 'lib/shoulda/matchers/pundit.rb', line 11
def forbid(*actions)
ForbidMatcher.new(*actions)
end
|
#permit(*actions) ⇒ Object
7
8
9
|
# File 'lib/shoulda/matchers/pundit.rb', line 7
def permit(*actions)
PermitMatcher.new(*actions)
end
|