class Eaco::Cucumber::ActiveRecord::User::Designators::Authenticated
A {Designator} based on a the {User} class.
This is an example on how to grant rights to all instances of a given model.
The class name is available as the {Designator#value}.
The String representation for an example User
is +“authenticated:User”+.
Public Instance Methods
describe(*)
click to toggle source
This {Designator} description.
@return [String] an hardcoded description
# File lib/eaco/cucumber/active_record/user/designators/authenticated.rb, line 26 def describe(*) "Any authenticated user" end
resolve()
click to toggle source
{User}s matching this designator.
@return [Array] All {User}s.
# File lib/eaco/cucumber/active_record/user/designators/authenticated.rb, line 35 def resolve klass.all end
Private Instance Methods
klass()
click to toggle source
Looks up this class by constantizing it.
@return [Class]
# File lib/eaco/cucumber/active_record/user/designators/authenticated.rb, line 45 def klass @_klass ||= self.value.constantize end