test-kitchen 2.3.4 → 2.4.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/kitchen.rb +30 -30
- data/lib/kitchen/cli.rb +2 -2
- data/lib/kitchen/command/action.rb +1 -1
- data/lib/kitchen/command/console.rb +1 -1
- data/lib/kitchen/command/diagnose.rb +2 -2
- data/lib/kitchen/command/doctor.rb +1 -1
- data/lib/kitchen/command/exec.rb +1 -1
- data/lib/kitchen/command/list.rb +1 -1
- data/lib/kitchen/command/login.rb +1 -1
- data/lib/kitchen/command/package.rb +1 -1
- data/lib/kitchen/command/sink.rb +1 -1
- data/lib/kitchen/command/test.rb +1 -1
- data/lib/kitchen/configurable.rb +7 -1
- data/lib/kitchen/data_munger.rb +1 -1
- data/lib/kitchen/diagnostic.rb +2 -2
- data/lib/kitchen/driver.rb +1 -1
- data/lib/kitchen/driver/base.rb +5 -5
- data/lib/kitchen/driver/dummy.rb +1 -1
- data/lib/kitchen/driver/exec.rb +4 -4
- data/lib/kitchen/driver/proxy.rb +2 -2
- data/lib/kitchen/driver/ssh_base.rb +1 -1
- data/lib/kitchen/generator/init.rb +2 -2
- data/lib/kitchen/lifecycle_hooks.rb +2 -2
- data/lib/kitchen/loader/yaml.rb +1 -1
- data/lib/kitchen/plugin.rb +2 -2
- data/lib/kitchen/provisioner.rb +1 -1
- data/lib/kitchen/provisioner/base.rb +3 -3
- data/lib/kitchen/provisioner/chef/berkshelf.rb +2 -2
- data/lib/kitchen/provisioner/chef/policyfile.rb +3 -3
- data/lib/kitchen/provisioner/chef_apply.rb +1 -1
- data/lib/kitchen/provisioner/chef_base.rb +4 -4
- data/lib/kitchen/provisioner/chef_solo.rb +1 -1
- data/lib/kitchen/provisioner/chef_zero.rb +1 -1
- data/lib/kitchen/provisioner/dummy.rb +1 -1
- data/lib/kitchen/provisioner/shell.rb +2 -2
- data/lib/kitchen/rake_tasks.rb +1 -1
- data/lib/kitchen/ssh.rb +2 -2
- data/lib/kitchen/thor_tasks.rb +1 -1
- data/lib/kitchen/transport.rb +1 -1
- data/lib/kitchen/transport/base.rb +5 -5
- data/lib/kitchen/transport/dummy.rb +1 -1
- data/lib/kitchen/transport/exec.rb +3 -3
- data/lib/kitchen/transport/ssh.rb +1 -1
- data/lib/kitchen/transport/winrm.rb +1 -1
- data/lib/kitchen/util.rb +1 -1
- data/lib/kitchen/verifier.rb +1 -1
- data/lib/kitchen/verifier/base.rb +10 -3
- data/lib/kitchen/verifier/busser.rb +1 -1
- data/lib/kitchen/verifier/dummy.rb +1 -1
- data/lib/kitchen/verifier/shell.rb +1 -1
- data/lib/kitchen/version.rb +1 -1
- data/templates/init/chefignore.erb +1 -0
- data/test-kitchen.gemspec +1 -1
- metadata +5 -5
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 13209f8ae2db3d98eefbf14798a6ac583d867ce4f8e0dd19615ed6a2bdc3b2a7
|
4
|
+
data.tar.gz: 9e4300e69c3873ef2310381ab3c4f52349683bf1635afa4ce7464d89d33c1874
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: f40db4a968197d9102ba4a651ce6dce9b5557cc6498a5fca8529fb0cad9c5467d99f3340f99ed6d25f1424c95edd3dda2676a16ea98ddc556d69514e6e7d9b9b
|
7
|
+
data.tar.gz: 14ea562a570a3263111942233bc5bbd53aba4c75128284a8e84e295c612612b86293036cf7d56f9b5860a486d5f3d450b92934334c81cc6eb6b21754ae9ae8de
|
data/lib/kitchen.rb
CHANGED
@@ -19,36 +19,36 @@
|
|
19
19
|
require "pathname"
|
20
20
|
require "thread"
|
21
21
|
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
|
34
|
-
|
35
|
-
|
36
|
-
|
37
|
-
|
38
|
-
|
39
|
-
|
40
|
-
|
41
|
-
|
42
|
-
|
43
|
-
|
44
|
-
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
|
49
|
-
|
50
|
-
|
51
|
-
|
22
|
+
require_relative "kitchen/errors"
|
23
|
+
require_relative "kitchen/logger"
|
24
|
+
require_relative "kitchen/logging"
|
25
|
+
require_relative "kitchen/shell_out"
|
26
|
+
require_relative "kitchen/configurable"
|
27
|
+
require_relative "kitchen/util"
|
28
|
+
|
29
|
+
require_relative "kitchen/provisioner"
|
30
|
+
require_relative "kitchen/provisioner/base"
|
31
|
+
require_relative "kitchen/color"
|
32
|
+
require_relative "kitchen/collection"
|
33
|
+
require_relative "kitchen/config"
|
34
|
+
require_relative "kitchen/data_munger"
|
35
|
+
require_relative "kitchen/driver"
|
36
|
+
require_relative "kitchen/driver/base"
|
37
|
+
require_relative "kitchen/driver/ssh_base"
|
38
|
+
require_relative "kitchen/driver/proxy"
|
39
|
+
require_relative "kitchen/instance"
|
40
|
+
require_relative "kitchen/lifecycle_hooks"
|
41
|
+
require_relative "kitchen/transport"
|
42
|
+
require_relative "kitchen/transport/base"
|
43
|
+
require_relative "kitchen/loader/yaml"
|
44
|
+
require_relative "kitchen/metadata_chopper"
|
45
|
+
require_relative "kitchen/platform"
|
46
|
+
require_relative "kitchen/state_file"
|
47
|
+
require_relative "kitchen/ssh"
|
48
|
+
require_relative "kitchen/suite"
|
49
|
+
require_relative "kitchen/verifier"
|
50
|
+
require_relative "kitchen/verifier/base"
|
51
|
+
require_relative "kitchen/version"
|
52
52
|
|
53
53
|
# Test Kitchen base module.
|
54
54
|
#
|
data/lib/kitchen/cli.rb
CHANGED
@@ -16,8 +16,8 @@
|
|
16
16
|
# See the License for the specific language governing permissions and
|
17
17
|
# limitations under the License.
|
18
18
|
|
19
|
-
|
20
|
-
|
19
|
+
require_relative "../command"
|
20
|
+
require_relative "../diagnostic"
|
21
21
|
|
22
22
|
require "yaml"
|
23
23
|
|
data/lib/kitchen/command/exec.rb
CHANGED
data/lib/kitchen/command/list.rb
CHANGED
data/lib/kitchen/command/sink.rb
CHANGED
data/lib/kitchen/command/test.rb
CHANGED
data/lib/kitchen/configurable.rb
CHANGED
@@ -18,7 +18,7 @@
|
|
18
18
|
|
19
19
|
require "thor/util"
|
20
20
|
|
21
|
-
|
21
|
+
require_relative "lazy_hash"
|
22
22
|
|
23
23
|
module Kitchen
|
24
24
|
# A mixin for providing configuration-related behavior such as default
|
@@ -349,6 +349,12 @@ module Kitchen
|
|
349
349
|
code_parts = resolve_proxy_settings_from_config
|
350
350
|
code_parts << shell_env_var("TEST_KITCHEN", 1)
|
351
351
|
code_parts << shell_env_var("CI", ENV["CI"]) if ENV["CI"]
|
352
|
+
code_parts << shell_env_var("CHEF_LICENSE", ENV["CHEF_LICENSE"]) if ENV["CHEF_LICENSE"]
|
353
|
+
ENV.select { |key, value| key.start_with?("TKENV_") }.each do |key, value|
|
354
|
+
env_var_name = "#{key}".sub!("TKENV_", "")
|
355
|
+
code_parts << shell_env_var(env_var_name, value)
|
356
|
+
end
|
357
|
+
|
352
358
|
code_parts << code
|
353
359
|
code_parts.join("\n")
|
354
360
|
end
|
data/lib/kitchen/data_munger.rb
CHANGED
@@ -16,7 +16,7 @@
|
|
16
16
|
# See the License for the specific language governing permissions and
|
17
17
|
# limitations under the License.
|
18
18
|
|
19
|
-
|
19
|
+
require_relative "../vendor/hash_recursive_merge"
|
20
20
|
|
21
21
|
module Kitchen
|
22
22
|
# Class to handle recursive merging of configuration between platforms,
|
data/lib/kitchen/diagnostic.rb
CHANGED
@@ -16,8 +16,8 @@
|
|
16
16
|
# See the License for the specific language governing permissions and
|
17
17
|
# limitations under the License.
|
18
18
|
|
19
|
-
|
20
|
-
|
19
|
+
require_relative "util"
|
20
|
+
require_relative "version"
|
21
21
|
|
22
22
|
module Kitchen
|
23
23
|
# Combines and compiles diagnostic information about a Test Kitchen
|
data/lib/kitchen/driver.rb
CHANGED
@@ -16,7 +16,7 @@
|
|
16
16
|
# See the License for the specific language governing permissions and
|
17
17
|
# limitations under the License.
|
18
18
|
|
19
|
-
|
19
|
+
require_relative "plugin"
|
20
20
|
|
21
21
|
module Kitchen
|
22
22
|
# A driver is responsible for carrying out the lifecycle activities of an
|
data/lib/kitchen/driver/base.rb
CHANGED
@@ -16,11 +16,11 @@
|
|
16
16
|
# See the License for the specific language governing permissions and
|
17
17
|
# limitations under the License.
|
18
18
|
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
|
19
|
+
require_relative "../configurable"
|
20
|
+
require_relative "../errors"
|
21
|
+
require_relative "../lazy_hash"
|
22
|
+
require_relative "../logging"
|
23
|
+
require_relative "../shell_out"
|
24
24
|
|
25
25
|
module Kitchen
|
26
26
|
module Driver
|
data/lib/kitchen/driver/dummy.rb
CHANGED
data/lib/kitchen/driver/exec.rb
CHANGED
@@ -13,10 +13,10 @@
|
|
13
13
|
# limitations under the License.
|
14
14
|
#
|
15
15
|
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
16
|
+
require_relative "base"
|
17
|
+
require_relative "../shell_out"
|
18
|
+
require_relative "../transport/exec"
|
19
|
+
require_relative "../version"
|
20
20
|
|
21
21
|
module Kitchen
|
22
22
|
module Driver
|
data/lib/kitchen/driver/proxy.rb
CHANGED
@@ -136,7 +136,7 @@ module Kitchen
|
|
136
136
|
rakedoc = <<-RAKE.gsub(/^ {10}/, "")
|
137
137
|
|
138
138
|
begin
|
139
|
-
|
139
|
+
require_relative '../rake_tasks'
|
140
140
|
Kitchen::RakeTasks.new
|
141
141
|
rescue LoadError
|
142
142
|
puts '>>>>> Kitchen gem not loaded, omitting tasks' unless ENV['CI']
|
@@ -154,7 +154,7 @@ module Kitchen
|
|
154
154
|
thordoc = <<-THOR.gsub(/^ {10}/, "")
|
155
155
|
|
156
156
|
begin
|
157
|
-
|
157
|
+
require_relative '../thor_tasks'
|
158
158
|
Kitchen::ThorTasks.new
|
159
159
|
rescue LoadError
|
160
160
|
puts '>>>>> Kitchen gem not loaded, omitting tasks' unless ENV['CI']
|
@@ -16,8 +16,8 @@
|
|
16
16
|
# See the License for the specific language governing permissions and
|
17
17
|
# limitations under the License.
|
18
18
|
|
19
|
-
|
20
|
-
|
19
|
+
require_relative "errors"
|
20
|
+
require_relative "shell_out"
|
21
21
|
|
22
22
|
module Kitchen
|
23
23
|
# A helper object used by {Instance} to coordinate lifecycle hook calls from
|
data/lib/kitchen/loader/yaml.rb
CHANGED
data/lib/kitchen/plugin.rb
CHANGED
@@ -17,8 +17,8 @@
|
|
17
17
|
# See the License for the specific language governing permissions and
|
18
18
|
# limitations under the License.
|
19
19
|
|
20
|
-
|
21
|
-
|
20
|
+
require_relative "errors"
|
21
|
+
require_relative "util"
|
22
22
|
|
23
23
|
module Kitchen
|
24
24
|
module Plugin
|
data/lib/kitchen/provisioner.rb
CHANGED
@@ -16,7 +16,7 @@
|
|
16
16
|
# See the License for the specific language governing permissions and
|
17
17
|
# limitations under the License.
|
18
18
|
|
19
|
-
|
19
|
+
require_relative "plugin"
|
20
20
|
|
21
21
|
module Kitchen
|
22
22
|
# A provisioner is responsible for generating the commands necessary to
|
@@ -16,9 +16,9 @@
|
|
16
16
|
# See the License for the specific language governing permissions and
|
17
17
|
# limitations under the License.
|
18
18
|
|
19
|
-
|
20
|
-
|
21
|
-
|
19
|
+
require_relative "../configurable"
|
20
|
+
require_relative "../errors"
|
21
|
+
require_relative "../logging"
|
22
22
|
|
23
23
|
module Kitchen
|
24
24
|
module Provisioner
|
@@ -16,8 +16,8 @@
|
|
16
16
|
# See the License for the specific language governing permissions and
|
17
17
|
# limitations under the License.
|
18
18
|
|
19
|
-
|
20
|
-
|
19
|
+
require_relative "../../errors"
|
20
|
+
require_relative "../../logging"
|
21
21
|
|
22
22
|
module Kitchen
|
23
23
|
module Provisioner
|
@@ -19,9 +19,9 @@
|
|
19
19
|
require "shellwords"
|
20
20
|
require "rbconfig"
|
21
21
|
|
22
|
-
|
23
|
-
|
24
|
-
|
22
|
+
require_relative "../../errors"
|
23
|
+
require_relative "../../logging"
|
24
|
+
require_relative "../../shell_out"
|
25
25
|
|
26
26
|
module Kitchen
|
27
27
|
module Provisioner
|
@@ -21,10 +21,10 @@ require "pathname"
|
|
21
21
|
require "json"
|
22
22
|
require "cgi"
|
23
23
|
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
24
|
+
require_relative "chef/policyfile"
|
25
|
+
require_relative "chef/berkshelf"
|
26
|
+
require_relative "chef/common_sandbox"
|
27
|
+
require_relative "../util"
|
28
28
|
require "mixlib/install"
|
29
29
|
require "mixlib/install/script_generator"
|
30
30
|
require "license_acceptance/acceptor"
|
data/lib/kitchen/rake_tasks.rb
CHANGED
data/lib/kitchen/ssh.rb
CHANGED
@@ -21,8 +21,8 @@ require "net/ssh"
|
|
21
21
|
require "net/scp"
|
22
22
|
require "socket"
|
23
23
|
|
24
|
-
|
25
|
-
|
24
|
+
require_relative "errors"
|
25
|
+
require_relative "login_command"
|
26
26
|
|
27
27
|
module Kitchen
|
28
28
|
# Wrapped exception for any internally raised SSH-related errors.
|
data/lib/kitchen/thor_tasks.rb
CHANGED
data/lib/kitchen/transport.rb
CHANGED
@@ -16,7 +16,7 @@
|
|
16
16
|
# See the License for the specific language governing permissions and
|
17
17
|
# limitations under the License.
|
18
18
|
|
19
|
-
|
19
|
+
require_relative "plugin"
|
20
20
|
|
21
21
|
module Kitchen
|
22
22
|
# A transport is responsible for the communication with an instance,
|
@@ -17,11 +17,11 @@
|
|
17
17
|
# See the License for the specific language governing permissions and
|
18
18
|
# limitations under the License.
|
19
19
|
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
20
|
+
require_relative "../configurable"
|
21
|
+
require_relative "../errors"
|
22
|
+
require_relative "../lazy_hash"
|
23
|
+
require_relative "../logging"
|
24
|
+
require_relative "../login_command"
|
25
25
|
|
26
26
|
module Kitchen
|
27
27
|
module Transport
|
@@ -14,9 +14,9 @@
|
|
14
14
|
|
15
15
|
require "fileutils"
|
16
16
|
|
17
|
-
|
18
|
-
|
19
|
-
|
17
|
+
require_relative "../shell_out"
|
18
|
+
require_relative "base"
|
19
|
+
require_relative "../version"
|
20
20
|
|
21
21
|
module Kitchen
|
22
22
|
module Transport
|
data/lib/kitchen/util.rb
CHANGED
data/lib/kitchen/verifier.rb
CHANGED
@@ -16,7 +16,7 @@
|
|
16
16
|
# See the License for the specific language governing permissions and
|
17
17
|
# limitations under the License.
|
18
18
|
|
19
|
-
|
19
|
+
require_relative "plugin"
|
20
20
|
|
21
21
|
module Kitchen
|
22
22
|
# A verifier is responsible for running tests post-converge to confirm that
|
@@ -16,9 +16,9 @@
|
|
16
16
|
# See the License for the specific language governing permissions and
|
17
17
|
# limitations under the License.
|
18
18
|
|
19
|
-
|
20
|
-
|
21
|
-
|
19
|
+
require_relative "../errors"
|
20
|
+
require_relative "../configurable"
|
21
|
+
require_relative "../logging"
|
22
22
|
|
23
23
|
module Kitchen
|
24
24
|
module Verifier
|
@@ -75,6 +75,13 @@ module Kitchen
|
|
75
75
|
debug("Transfer complete")
|
76
76
|
conn.execute(prepare_command)
|
77
77
|
conn.execute(run_command)
|
78
|
+
|
79
|
+
info("Downloading files from #{instance.to_str}")
|
80
|
+
config[:downloads].to_h.each do |remotes, local|
|
81
|
+
debug("Downloading #{Array(remotes).join(", ")} to #{local}")
|
82
|
+
conn.download(remotes, local)
|
83
|
+
end
|
84
|
+
debug("Download complete")
|
78
85
|
end
|
79
86
|
rescue Kitchen::Transport::TransportFailed => ex
|
80
87
|
raise ActionFailed, ex.message
|
data/lib/kitchen/version.rb
CHANGED
data/test-kitchen.gemspec
CHANGED
@@ -43,7 +43,7 @@ Gem::Specification.new do |gem|
|
|
43
43
|
gem.add_development_dependency "rake"
|
44
44
|
|
45
45
|
gem.add_development_dependency "aruba", "~> 0.11"
|
46
|
-
gem.add_development_dependency "fakefs", "~> 0
|
46
|
+
gem.add_development_dependency "fakefs", "~> 1.0"
|
47
47
|
gem.add_development_dependency "minitest", "~> 5.3", "< 5.12"
|
48
48
|
gem.add_development_dependency "mocha", "~> 1.1"
|
49
49
|
gem.add_development_dependency "cucumber", ">= 2.1", "< 4.0" # we just need to validate 4.0 when it comes out
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: test-kitchen
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.
|
4
|
+
version: 2.4.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Fletcher Nichol
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2020-03-04 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: mixlib-shellout
|
@@ -270,14 +270,14 @@ dependencies:
|
|
270
270
|
requirements:
|
271
271
|
- - "~>"
|
272
272
|
- !ruby/object:Gem::Version
|
273
|
-
version: '0
|
273
|
+
version: '1.0'
|
274
274
|
type: :development
|
275
275
|
prerelease: false
|
276
276
|
version_requirements: !ruby/object:Gem::Requirement
|
277
277
|
requirements:
|
278
278
|
- - "~>"
|
279
279
|
- !ruby/object:Gem::Version
|
280
|
-
version: '0
|
280
|
+
version: '1.0'
|
281
281
|
- !ruby/object:Gem::Dependency
|
282
282
|
name: minitest
|
283
283
|
requirement: !ruby/object:Gem::Requirement
|
@@ -487,7 +487,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
487
487
|
- !ruby/object:Gem::Version
|
488
488
|
version: '0'
|
489
489
|
requirements: []
|
490
|
-
rubygems_version: 3.
|
490
|
+
rubygems_version: 3.1.2
|
491
491
|
signing_key:
|
492
492
|
specification_version: 4
|
493
493
|
summary: Test Kitchen is an integration tool for developing and testing infrastructure
|