aptible-auth 0.11.0 → 0.11.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/aptible-auth.gemspec +1 -0
- data/lib/aptible/auth/organization.rb +5 -0
- data/lib/aptible/auth/version.rb +1 -1
- data/spec/aptible/auth/organization_spec.rb +30 -0
- metadata +17 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 5e4f0de847d45813da39ecd56360515cf2c3e912
|
4
|
+
data.tar.gz: 447e42672717fd9e2302fa80a07c3f8d13a21cf5
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: afa807cc4efd327be1d168b0c6311339ab28de386f14f5776ca11095d6f132eeca34e52edfff26839baf63a82576141b328319c58279829dc988738878fcd48b
|
7
|
+
data.tar.gz: b70cbe5569b929daadaa474d7c282964827488bd892236544cc5875b9541b088d359de8611c8d1ef173f869d82db68d6b5621d33d81f7c8f38b680f1adcbfd0c
|
data/aptible-auth.gemspec
CHANGED
@@ -29,5 +29,6 @@ Gem::Specification.new do |spec|
|
|
29
29
|
spec.add_development_dependency 'aptible-tasks', '>= 0.2.0'
|
30
30
|
spec.add_development_dependency 'rake'
|
31
31
|
spec.add_development_dependency 'rspec', '~> 2.0'
|
32
|
+
spec.add_development_dependency 'rspec-its'
|
32
33
|
spec.add_development_dependency 'pry'
|
33
34
|
end
|
data/lib/aptible/auth/version.rb
CHANGED
@@ -1,6 +1,36 @@
|
|
1
1
|
require 'spec_helper'
|
2
2
|
|
3
3
|
describe Aptible::Auth::Organization do
|
4
|
+
describe '#can_manage_compliance?' do
|
5
|
+
before { subject.stub(:billing_detail) { billing_detail } }
|
6
|
+
|
7
|
+
context 'without a billing detail' do
|
8
|
+
let(:billing_detail) { nil }
|
9
|
+
it 'should return false' do
|
10
|
+
expect(subject.can_manage_compliance?).to eq false
|
11
|
+
end
|
12
|
+
end
|
13
|
+
|
14
|
+
context 'with a billing detail' do
|
15
|
+
let(:billing_detail) { double Aptible::Billing::BillingDetail }
|
16
|
+
|
17
|
+
it 'should return true with production plan' do
|
18
|
+
billing_detail.stub(:plan) { 'production' }
|
19
|
+
expect(subject.can_manage_compliance?).to eq true
|
20
|
+
end
|
21
|
+
|
22
|
+
it 'should return false with development plan' do
|
23
|
+
billing_detail.stub(:plan) { 'development' }
|
24
|
+
expect(subject.can_manage_compliance?).to eq false
|
25
|
+
end
|
26
|
+
|
27
|
+
it 'should return false with platform plan' do
|
28
|
+
billing_detail.stub(:plan) { 'platform' }
|
29
|
+
expect(subject.can_manage_compliance?).to eq false
|
30
|
+
end
|
31
|
+
end
|
32
|
+
end
|
33
|
+
|
4
34
|
describe '#security_officer' do
|
5
35
|
let(:user) { double 'Aptible::Auth::User' }
|
6
36
|
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: aptible-auth
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.11.
|
4
|
+
version: 0.11.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Frank Macreery
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2015-
|
11
|
+
date: 2015-11-23 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: aptible-billing
|
@@ -136,6 +136,20 @@ dependencies:
|
|
136
136
|
- - ~>
|
137
137
|
- !ruby/object:Gem::Version
|
138
138
|
version: '2.0'
|
139
|
+
- !ruby/object:Gem::Dependency
|
140
|
+
name: rspec-its
|
141
|
+
requirement: !ruby/object:Gem::Requirement
|
142
|
+
requirements:
|
143
|
+
- - '>='
|
144
|
+
- !ruby/object:Gem::Version
|
145
|
+
version: '0'
|
146
|
+
type: :development
|
147
|
+
prerelease: false
|
148
|
+
version_requirements: !ruby/object:Gem::Requirement
|
149
|
+
requirements:
|
150
|
+
- - '>='
|
151
|
+
- !ruby/object:Gem::Version
|
152
|
+
version: '0'
|
139
153
|
- !ruby/object:Gem::Dependency
|
140
154
|
name: pry
|
141
155
|
requirement: !ruby/object:Gem::Requirement
|
@@ -207,7 +221,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
207
221
|
version: '0'
|
208
222
|
requirements: []
|
209
223
|
rubyforge_project:
|
210
|
-
rubygems_version: 2.4.
|
224
|
+
rubygems_version: 2.4.6
|
211
225
|
signing_key:
|
212
226
|
specification_version: 4
|
213
227
|
summary: Ruby client for auth.aptible.com
|