Sha256: e5d1ddb387700497f74e36bbf5e7d6dd00e9c86a7866aa2f69b12fc0180c62ef

Contents?: true

Size: 681 Bytes

Versions: 6

Compression:

Stored size: 681 Bytes

Contents

require 'spec_helper'

use_roles_strategy :roles_mask

class User
  include Mongoid::Document  
  include Roles::Mongoid 
  
  strategy :roles_mask, :default

  valid_roles_are :admin, :guest, :user
end

def api_name
  :roles_mask
end

load 'roles_mongoid/strategy/api_examples.rb'



# require 'spec_helper'
# use_roles_strategy :roles_mask
# 
# class User 
#   include Mongoid::Document  
#   include Roles::Mongoid 
#   
#   strategy :roles_mask, :default
#   valid_roles_are :admin, :guest   
# 
#   field :name, :type => String 
# end
# 
# describe "Roles for Mongoid: :roles_mask strategy" do  
#   load "roles_mongoid/user_setup"
#   load "roles_generic/rspec/api"
# end
# 

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
roles_mongoid-0.3.6 spec/roles_mongoid/strategy/multi/roles_mask_spec.rb
roles_mongoid-0.3.5 spec/roles_mongoid/strategy/multi/roles_mask_spec.rb
roles_mongoid-0.3.4 spec/roles_mongoid/strategy/multi/roles_mask_spec.rb
roles_mongoid-0.3.3 spec/roles_mongoid/strategy/multi/roles_mask_spec.rb
roles_mongoid-0.3.2 spec/roles_mongoid/strategy/multi/roles_mask_spec.rb
roles_mongoid-0.3.1 spec/roles_mongoid/strategy/multi/roles_mask_spec.rb