Sha256: 995ebefc1d3b8b17ee7ac3ede8f2b827c1e5fbe42162481a818d48b5eee969d7
Contents?: true
Size: 821 Bytes
Versions: 22
Compression:
Stored size: 821 Bytes
Contents
require 'spec_helper' shared_examples_for "Having permissions" do it 'should contain bloggers permission allowing to read Comments' do store.role_groups_permissions['bloggers'].static_rules.can.read.should include('Article') end it 'should contain editors permission allowing to write Posts' do store.role_groups_permissions['editors'].static_rules.cannot.write.should include('Post') end end shared_examples_for "Having compiled permissions" do it 'should contain bloggers permission allowing to read Comments' do store.role_groups_rules.bloggers.can.should == %|can(:read, Article)\ncan(:read, Comment)| end it 'should contain editors permission allowing to write Posts' do store.role_groups_rules.editors.cannot.should == %|cannot(:write, Article)\ncannot(:write, Post)| end end
Version data entries
22 entries across 22 versions & 1 rubygems