beaker 4.2.0 → 4.3.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +8 -1
- data/lib/beaker/host/unix/pkg.rb +1 -1
- data/lib/beaker/options/command_line_parser.rb +6 -0
- data/lib/beaker/options/presets.rb +1 -0
- data/lib/beaker/subcommand.rb +1 -0
- data/lib/beaker/test_suite.rb +3 -0
- data/lib/beaker/test_suite_result.rb +11 -0
- data/lib/beaker/version.rb +1 -1
- 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: 42f1138cc5ec8c7a9061bc89231e3eaeb8eec7f8
|
4
|
+
data.tar.gz: b9bc35774979598ad0b93cfc6034a5112a47c637
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 58a79da7a9579907481842211a661163c4fd82cf6f4da34c644e32997fb5c2193f7064cfce6832e014c4c9405163176898d4fe94593333530985bfa100bbb2a2
|
7
|
+
data.tar.gz: 1ef6ae9adb6da65eb28bdc01c7e920b55d633debc1036dfe62d0778b852dbd5d3c394b2829e1709a934acb0f1f0138ca681f5d5324b92614263c4085cf2b4f7c
|
data/CHANGELOG.md
CHANGED
@@ -11,7 +11,14 @@ Tracking in this Changelog began for this project in version 3.25.0.
|
|
11
11
|
If you're looking for changes from before this, refer to the project's
|
12
12
|
git logs & PR history.
|
13
13
|
|
14
|
-
# [Unreleased](https://github.com/puppetlabs/beaker/compare/4.
|
14
|
+
# [Unreleased](https://github.com/puppetlabs/beaker/compare/4.3.0...master)
|
15
|
+
|
16
|
+
# [4.3.0](https://github.com/puppetlabs/beaker/compare/4.2.0...4.3.0) - 2018.12.12
|
17
|
+
|
18
|
+
### Added
|
19
|
+
|
20
|
+
- Use zypper to install RPM packages on SLES (PA-2336)
|
21
|
+
- Add only-fails capability to beaker (BKR-1523)
|
15
22
|
|
16
23
|
# [4.2.0](https://github.com/puppetlabs/beaker/compare/4.1.0...4.2.0) - 2018.11.28
|
17
24
|
|
data/lib/beaker/host/unix/pkg.rb
CHANGED
@@ -514,7 +514,7 @@ module Unix::Pkg
|
|
514
514
|
command_name = 'dnf 'if variant == 'fedora' && version > 21 && version <= 29
|
515
515
|
execute("#{command_name} --nogpgcheck localinstall -y #{onhost_package_file}")
|
516
516
|
when /^(sles)$/
|
517
|
-
execute("
|
517
|
+
execute("zypper --non-interactive --no-gpg-checks in #{onhost_package_file}")
|
518
518
|
when /^(debian|ubuntu|cumulus)$/
|
519
519
|
execute("dpkg -i --force-all #{onhost_package_file}")
|
520
520
|
execute("apt-get update")
|
@@ -194,6 +194,12 @@ module Beaker
|
|
194
194
|
@cmd_options[:fail_mode] = mode =~ /stop/ ? 'fast' : mode
|
195
195
|
end
|
196
196
|
|
197
|
+
opts.on '--test-results-file /FILE/TO/SAVE/TO.rb',
|
198
|
+
'Path to persist errors/failures from the current run to',
|
199
|
+
'(default: not saved)' do |value|
|
200
|
+
@cmd_options[:test_results_file] = value
|
201
|
+
end
|
202
|
+
|
197
203
|
opts.on '--[no-]ntp',
|
198
204
|
'Sync time on SUTs before testing',
|
199
205
|
'(default: false)' do |bool|
|
data/lib/beaker/subcommand.rb
CHANGED
@@ -43,6 +43,7 @@ module Beaker
|
|
43
43
|
class_option :'log-prefix', :type => :string, :group => 'Beaker run'
|
44
44
|
class_option :'dry-run', :type => :boolean, :group => 'Beaker run'
|
45
45
|
class_option :'fail-mode', :type => :string, :group => 'Beaker run'
|
46
|
+
class_option :'test-results-file', :type => :string, :group => 'Beaker run'
|
46
47
|
class_option :ntp, :type => :boolean, :group => 'Beaker run'
|
47
48
|
class_option :'repo-proxy', :type => :boolean, :group => 'Beaker run'
|
48
49
|
class_option :'add-el-extras', :type => :boolean, :group => 'Beaker run'
|
data/lib/beaker/test_suite.rb
CHANGED
@@ -98,6 +98,9 @@ module Beaker
|
|
98
98
|
else
|
99
99
|
@test_suite_results.write_junit_xml( junit_file_log )
|
100
100
|
end
|
101
|
+
|
102
|
+
@test_suite_results.persist_test_results(@options[:test_results_file])
|
103
|
+
|
101
104
|
#All done with this run, remove run log
|
102
105
|
@logger.remove_destination(run_log)
|
103
106
|
|
@@ -150,6 +150,17 @@ module Beaker
|
|
150
150
|
" Test Case #{test_case.path} #{test_reported}"
|
151
151
|
end
|
152
152
|
|
153
|
+
# Saves failure and error cases as a JSON file for only-failures processing
|
154
|
+
#
|
155
|
+
# @param [String] filepath Where to put the results
|
156
|
+
#
|
157
|
+
def persist_test_results(filepath)
|
158
|
+
return if filepath.empty?
|
159
|
+
|
160
|
+
results = @test_cases.select { |c| [:fail, :error].include? c.test_status }.map(&:path)
|
161
|
+
File.open(filepath, 'w') { |file| file.puts JSON.dump(results) }
|
162
|
+
end
|
163
|
+
|
153
164
|
# Writes Junit XML of this {TestSuiteResult}
|
154
165
|
#
|
155
166
|
# @param [String] xml_file Path to the XML file (from Beaker's running directory)
|
data/lib/beaker/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: beaker
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 4.
|
4
|
+
version: 4.3.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Puppet
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2018-
|
11
|
+
date: 2018-12-12 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rspec
|