invitational 1.4.1 → 1.4.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +10 -1
- data/lib/invitational/cancan.rb +2 -0
- data/lib/invitational/version.rb +1 -1
- data/spec/internal/app/models/ability.rb +1 -0
- data/spec/internal/db/combustion_test.sqlite +0 -0
- data/spec/internal/log/test.log +17058 -0
- data/spec/invitational/models/ability_spec.rb +11 -0
- metadata +2 -2
@@ -43,6 +43,17 @@ describe Ability do
|
|
43
43
|
And { i.should_not be_able_to(:read, entity1) }
|
44
44
|
end
|
45
45
|
|
46
|
+
context "Any Role (wildcard)" do
|
47
|
+
Given (:user) { Ability.new(user1) }
|
48
|
+
Given (:admin) { Ability.new(user2) }
|
49
|
+
When (:role) {:*}
|
50
|
+
|
51
|
+
Then { user.should be_able_to(:validate, entity1) }
|
52
|
+
And { user.should_not be_able_to(:validate, entity2) }
|
53
|
+
And { admin.should be_able_to(:validate, entity2) }
|
54
|
+
And { admin.should_not be_able_to(:validate, entity1) }
|
55
|
+
end
|
56
|
+
|
46
57
|
context "System - Employer" do
|
47
58
|
Given (:i) { Ability.new(user4) }
|
48
59
|
When (:role) {:employer}
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: invitational
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.4.
|
4
|
+
version: 1.4.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Dave Goerlich
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2020-01-27 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rails
|