Sha256: 985ea718c9fad14e4ab3c0fc77bea291bcc391c9df1f3a16994778ee529844cb
Contents?: true
Size: 588 Bytes
Versions: 21
Compression:
Stored size: 588 Bytes
Contents
require 'cantango' require 'cantango/permit_engine/util' module CanTango class Ability def initialize candidate, options = {} puts "\n\n! Using test variant of CanTango::Ability from spec/helpers !\n\n" raise "Candidate must be something!" if !candidate @candidate, @options = candidate, options @session = options[:session] || {} # seperate session cache for each type of user? @rules_cached = true and return if cached_rules? execute_engines! cache_rules! end def rules_cached? @rules_cached || false end end end
Version data entries
21 entries across 21 versions & 1 rubygems