sanction 2.1.2 → 2.1.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/sanction/blacklist/null_node.rb +1 -0
- data/lib/sanction/version.rb +1 -1
- data/lib/sanction/whitelist/null_node.rb +1 -0
- data/spec/application_spec.rb +20 -0
- data/spec/spec_helper.rb +1 -0
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: a5fdf471eac63b74eeabe3808203eb4ae30b8bf4
|
4
|
+
data.tar.gz: bc0591b4a12d9a6b1e8aa5b66da842b8310cb42c
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 399445b870a0c670fd4a14f9c818b2299f491e62bd76860570dbb5d741db504097e76173be218f4faffc9863de6044fe8faa95b3777eab4920f31a78c584c556
|
7
|
+
data.tar.gz: e0b915c4f81038dab6ff3e00028841022a9277928918ece7fec858884e7abcb4f015a59bd2a8344f2f1e325518609ade81ec780bfde69cf2fc73d79953932175
|
data/lib/sanction/version.rb
CHANGED
data/spec/application_spec.rb
CHANGED
@@ -41,6 +41,26 @@ describe 'application issues' do
|
|
41
41
|
permission.path[:shelf][1234].permitted?.must_equal true
|
42
42
|
end
|
43
43
|
end
|
44
|
+
|
45
|
+
describe "allowing deeply nested objects" do
|
46
|
+
before do
|
47
|
+
permission.path[:shelf][1234][:pack][12].allow!
|
48
|
+
end
|
49
|
+
|
50
|
+
it 'should allow access to the pack' do
|
51
|
+
permission.path[:shelf][1234][:pack][12].permitted?.must_equal true
|
52
|
+
end
|
53
|
+
end
|
54
|
+
|
55
|
+
describe "denying deeply nested objects" do
|
56
|
+
before do
|
57
|
+
permission.path[:shelf][1234][:pack][12].deny!
|
58
|
+
end
|
59
|
+
|
60
|
+
it 'should allow access to the pack' do
|
61
|
+
permission.path[:shelf][1234][:pack][12].permitted?.must_equal false
|
62
|
+
end
|
63
|
+
end
|
44
64
|
end
|
45
65
|
|
46
66
|
describe 'admin user with one banned bookcase' do
|
data/spec/spec_helper.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: sanction
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.1.
|
4
|
+
version: 2.1.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Adam Carlile
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2015-03-
|
12
|
+
date: 2015-03-19 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: activesupport
|