simp-beaker-helpers 1.14.1 → 1.14.2
Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 2f0c1802b035c9aab8eb25b91d2434e11d3c755be99e51fe281931e369f23cfc
|
4
|
+
data.tar.gz: 8453b9c5d98d067103f977f45d5e2f06f7d265c38ecbbfdab3ddbc47fbe19e95
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: a39140d24b4e7fe16e62c9e7220801670349082ef539dc62eabc381fb8cc902e751c340cff05b230127b1272a35d7bc909b4eeb3af23b0264a2df1ee8d7cd7b8
|
7
|
+
data.tar.gz: bcff7a3c524f8f753da48848562cd6d1b9ea0994a737058cd2c846dbe2081408c807dfd14b00dea77afa8a8f720f4c2f5726a18a521f715101584b62aa7f283f
|
data/.gitlab-ci.yml
CHANGED
@@ -98,21 +98,6 @@ default:
|
|
98
98
|
- beaker
|
99
99
|
<<: *cache_bundler
|
100
100
|
<<: *setup_bundler_env
|
101
|
-
variables:
|
102
|
-
PUPPET_VERSION: '~> 4.10.10'
|
103
|
-
script:
|
104
|
-
- bundle exec rake spec_clean
|
105
|
-
- bundle exec rake beaker:suites[default]
|
106
|
-
|
107
|
-
default-puppet5:
|
108
|
-
stage: acceptance
|
109
|
-
tags:
|
110
|
-
- beaker
|
111
|
-
<<: *cache_bundler
|
112
|
-
<<: *setup_bundler_env
|
113
|
-
variables:
|
114
|
-
PUPPET_VERSION: '~> 5.3'
|
115
|
-
BEAKER_PUPPET_COLLECTION: 'puppet5'
|
116
101
|
script:
|
117
102
|
- bundle exec rake spec_clean
|
118
103
|
- bundle exec rake beaker:suites[default]
|
data/CHANGELOG.md
CHANGED
@@ -1,3 +1,10 @@
|
|
1
|
+
### 1.14.2 / 2019-05-16
|
2
|
+
* Move the minimum supported puppet version to Puppet 5 since Puppet 4 has been
|
3
|
+
removed from the download servers completely. Beaker may re-add support for
|
4
|
+
the new location so not removing the mappings at this time.
|
5
|
+
* Fixed a bug where a hash item was incorrect and not properly passing along
|
6
|
+
configuration items.
|
7
|
+
|
1
8
|
### 1.14.1 / 2019-04-15
|
2
9
|
* Handle license acceptance option needed for new versions of inspec.
|
3
10
|
|
data/lib/simp/beaker_helpers.rb
CHANGED
@@ -19,7 +19,7 @@ module Simp::BeakerHelpers
|
|
19
19
|
#
|
20
20
|
# This is done so that we know if some new thing that we're using breaks the
|
21
21
|
# oldest system that we support.
|
22
|
-
DEFAULT_PUPPET_AGENT_VERSION = '
|
22
|
+
DEFAULT_PUPPET_AGENT_VERSION = '~> 5.0'
|
23
23
|
|
24
24
|
# We can't cache this because it may change during a run
|
25
25
|
def fips_enabled(sut)
|
@@ -889,7 +889,7 @@ done
|
|
889
889
|
return result
|
890
890
|
end
|
891
891
|
|
892
|
-
# returns hash with :puppet_install_version, :
|
892
|
+
# returns hash with :puppet_install_version, :puppet_collection,
|
893
893
|
# and :puppet_install_type keys determined from environment variables,
|
894
894
|
# host settings, and/or defaults
|
895
895
|
#
|
@@ -916,7 +916,7 @@ done
|
|
916
916
|
raise("Error: Puppet Collection '#{puppet_collection}' must match /puppet(\\d+)/")
|
917
917
|
end
|
918
918
|
else
|
919
|
-
puppet_agent_version = DEFAULT_PUPPET_AGENT_VERSION
|
919
|
+
puppet_agent_version = latest_puppet_agent_version_for(DEFAULT_PUPPET_AGENT_VERSION)
|
920
920
|
end
|
921
921
|
end
|
922
922
|
|
@@ -925,9 +925,10 @@ done
|
|
925
925
|
puppet_collection = "puppet#{base_version}" if base_version >= 5
|
926
926
|
end
|
927
927
|
|
928
|
-
{
|
929
|
-
:
|
930
|
-
:
|
928
|
+
{
|
929
|
+
:puppet_install_version => puppet_agent_version,
|
930
|
+
:puppet_collection => puppet_collection,
|
931
|
+
:puppet_install_type => ENV.fetch('PUPPET_INSTALL_TYPE', 'agent')
|
931
932
|
}
|
932
933
|
end
|
933
934
|
|
@@ -938,7 +939,7 @@ done
|
|
938
939
|
|
939
940
|
# In case Beaker needs this info internally
|
940
941
|
ENV['PUPPET_INSTALL_VERSION'] = install_info[:puppet_install_version]
|
941
|
-
|
942
|
+
if install_info[:puppet_collection]
|
942
943
|
ENV['BEAKER_PUPPET_COLLECTION'] = install_info[:puppet_collection]
|
943
944
|
end
|
944
945
|
|
@@ -14,8 +14,8 @@ hosts.each do |host|
|
|
14
14
|
expect(client_puppet_version.split('.').first).to eq(puppet_collection_version)
|
15
15
|
end
|
16
16
|
else
|
17
|
-
it 'should not be running puppet 5
|
18
|
-
expect(client_puppet_version.split('.').first).to
|
17
|
+
it 'should not be running puppet 5' do
|
18
|
+
expect(client_puppet_version.split('.').first).to eq '5'
|
19
19
|
end
|
20
20
|
end
|
21
21
|
end
|
@@ -103,20 +103,17 @@ describe 'Simp::BeakerHelpers' do
|
|
103
103
|
end
|
104
104
|
|
105
105
|
it 'uses defaults when no environment variables are set' do
|
106
|
-
|
107
|
-
:
|
108
|
-
:
|
109
|
-
:puppet_install_type => 'agent'
|
110
|
-
}
|
111
|
-
expect( @helper.get_puppet_install_info ).to eq expected
|
106
|
+
expect( @helper.get_puppet_install_info[:puppet_install_version] ).to match(/^5\./)
|
107
|
+
expect( @helper.get_puppet_install_info[:puppet_collection] ).to eq('puppet5')
|
108
|
+
expect( @helper.get_puppet_install_info[:puppet_install_type] ).to eq('agent')
|
112
109
|
end
|
113
110
|
|
114
111
|
it 'extracts info from PUPPET_INSTALL_VERSION for Puppet 4' do
|
115
112
|
ENV['PUPPET_INSTALL_VERSION']= '4.10.5'
|
116
113
|
expected = {
|
117
|
-
|
118
|
-
|
119
|
-
|
114
|
+
:puppet_install_version => '1.10.5',
|
115
|
+
:puppet_collection => nil,
|
116
|
+
:puppet_install_type => 'agent'
|
120
117
|
}
|
121
118
|
expect( @helper.get_puppet_install_info ).to eq expected
|
122
119
|
end
|
@@ -125,9 +122,9 @@ describe 'Simp::BeakerHelpers' do
|
|
125
122
|
allow(@helper).to receive(:`).with('gem search -ra -e puppet').and_return(gem_search_results)
|
126
123
|
ENV['PUPPET_INSTALL_VERSION']= '5.5.0'
|
127
124
|
expected = {
|
128
|
-
|
129
|
-
|
130
|
-
|
125
|
+
:puppet_install_version => '5.5.0',
|
126
|
+
:puppet_collection => 'puppet5',
|
127
|
+
:puppet_install_type => 'agent'
|
131
128
|
}
|
132
129
|
expect( @helper.get_puppet_install_info ).to eq expected
|
133
130
|
end
|
@@ -137,9 +134,9 @@ describe 'Simp::BeakerHelpers' do
|
|
137
134
|
ENV['PUPPET_INSTALL_VERSION']= '5.5.0'
|
138
135
|
ENV['BEAKER_PUPPET_COLLECTION']= 'puppet6'
|
139
136
|
expected = {
|
140
|
-
|
141
|
-
|
142
|
-
|
137
|
+
:puppet_install_version => '5.5.0',
|
138
|
+
:puppet_collection => 'puppet5',
|
139
|
+
:puppet_install_type => 'agent'
|
143
140
|
}
|
144
141
|
expect( @helper.get_puppet_install_info ).to eq expected
|
145
142
|
end
|
@@ -149,9 +146,9 @@ describe 'Simp::BeakerHelpers' do
|
|
149
146
|
ENV['PUPPET_INSTALL_VERSION']= '5.5.0'
|
150
147
|
@helper.host.options = {'puppet_collection' => 'puppet6'}
|
151
148
|
expected = {
|
152
|
-
|
153
|
-
|
154
|
-
|
149
|
+
:puppet_install_version => '5.5.0',
|
150
|
+
:puppet_collection => 'puppet5',
|
151
|
+
:puppet_install_type => 'agent'
|
155
152
|
}
|
156
153
|
expect( @helper.get_puppet_install_info ).to eq expected
|
157
154
|
end
|
@@ -159,9 +156,9 @@ describe 'Simp::BeakerHelpers' do
|
|
159
156
|
it 'extracts info from BEAKER_PUPPET_AGENT_VERSION' do
|
160
157
|
ENV['BEAKER_PUPPET_AGENT_VERSION']= '4.10.5'
|
161
158
|
expected = {
|
162
|
-
|
163
|
-
|
164
|
-
|
159
|
+
:puppet_install_version => '1.10.5',
|
160
|
+
:puppet_collection => nil,
|
161
|
+
:puppet_install_type => 'agent'
|
165
162
|
}
|
166
163
|
expect( @helper.get_puppet_install_info ).to eq expected
|
167
164
|
end
|
@@ -169,9 +166,9 @@ describe 'Simp::BeakerHelpers' do
|
|
169
166
|
it 'extracts info from PUPPET_VERSION' do
|
170
167
|
ENV['PUPPET_VERSION']= '4.10.5'
|
171
168
|
expected = {
|
172
|
-
|
173
|
-
|
174
|
-
|
169
|
+
:puppet_install_version => '1.10.5',
|
170
|
+
:puppet_collection => nil,
|
171
|
+
:puppet_install_type => 'agent'
|
175
172
|
}
|
176
173
|
expect( @helper.get_puppet_install_info ).to eq expected
|
177
174
|
end
|
@@ -180,9 +177,9 @@ describe 'Simp::BeakerHelpers' do
|
|
180
177
|
allow(@helper).to receive(:`).with('gem search -ra -e puppet').and_return(gem_search_results)
|
181
178
|
ENV['BEAKER_PUPPET_COLLECTION']= 'puppet5'
|
182
179
|
expected = {
|
183
|
-
|
184
|
-
|
185
|
-
|
180
|
+
:puppet_install_version => '5.5.1',
|
181
|
+
:puppet_collection => 'puppet5',
|
182
|
+
:puppet_install_type => 'agent'
|
186
183
|
}
|
187
184
|
expect( @helper.get_puppet_install_info ).to eq expected
|
188
185
|
end
|
@@ -191,21 +188,19 @@ describe 'Simp::BeakerHelpers' do
|
|
191
188
|
allow(@helper).to receive(:`).with('gem search -ra -e puppet').and_return(gem_search_results)
|
192
189
|
@helper.host.options = {'puppet_collection' => 'puppet5'}
|
193
190
|
expected = {
|
194
|
-
|
195
|
-
|
196
|
-
|
191
|
+
:puppet_install_version => '5.5.1',
|
192
|
+
:puppet_collection => 'puppet5',
|
193
|
+
:puppet_install_type => 'agent'
|
197
194
|
}
|
198
195
|
expect( @helper.get_puppet_install_info ).to eq expected
|
199
196
|
end
|
200
197
|
|
201
198
|
it 'extracts info from PUPPET_INSTALL_TYPE' do
|
202
199
|
ENV['PUPPET_INSTALL_TYPE'] = 'pe'
|
203
|
-
|
204
|
-
:
|
205
|
-
:
|
206
|
-
:
|
207
|
-
}
|
208
|
-
expect( @helper.get_puppet_install_info ).to eq expected
|
200
|
+
|
201
|
+
expect( @helper.get_puppet_install_info[:puppet_collection] ).to eq('puppet5')
|
202
|
+
expect( @helper.get_puppet_install_info[:puppet_install_type] ).to eq('pe')
|
203
|
+
expect( @helper.get_puppet_install_info[:puppet_install_version] ).to match(/^5\./)
|
209
204
|
end
|
210
205
|
|
211
206
|
it 'fails when BEAKER_PUPPET_COLLECTION is invalid' do
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: simp-beaker-helpers
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.14.
|
4
|
+
version: 1.14.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Chris Tessmer
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2019-
|
12
|
+
date: 2019-05-17 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: beaker
|