fastlane-plugin-test_center 3.14.7 → 3.14.8
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: 290ab3e6fb5932555e74d834784e80cb441dc4b7e4feb49eda479382a603a1e5
|
4
|
+
data.tar.gz: f46250359e1d156d283dd033e6e8db8c851297ea7a6385d78da4e72a014d0ebd
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: aaf987944f48d6511755077c7e4e1c564f722ad8c7f69f8c4e0f24b7c5db62590edc9fc69372e98d19e0cc8b7466f8b3fd2ef2a1ddba472b37bc45c3ee0b12a5
|
7
|
+
data.tar.gz: e1eb52e0b8b396019fe9727af6895948ad675c574b80293c866dfd627752d0e2dc3c8dd11b3e8f7508a40f1f64732a4b2987b1f92938aa6cf21b98d9c0d731d7
|
@@ -8,7 +8,7 @@ module Fastlane
|
|
8
8
|
if report_filepaths.size == 1
|
9
9
|
FileUtils.cp(report_filepaths[0], params[:collated_report])
|
10
10
|
else
|
11
|
-
|
11
|
+
verbose("collate_junit_reports with #{report_filepaths}")
|
12
12
|
reports = report_filepaths.map { |report_filepath| REXML::Document.new(File.new(report_filepath)) }
|
13
13
|
packages = reports.map { |r| r.root.attribute('name').value }.uniq
|
14
14
|
combine_multiple_targets = packages.size > 1
|
@@ -23,7 +23,7 @@ module Fastlane
|
|
23
23
|
increment_testable_tries(target_report.root, report.root)
|
24
24
|
package = report.root.attribute('name').value
|
25
25
|
preprocess_testsuites(report, package, combine_multiple_targets)
|
26
|
-
|
26
|
+
verbose("> collating last report file #{report_filepaths.last}")
|
27
27
|
report.elements.each('//testsuite') do |testsuite|
|
28
28
|
testsuite_name = testsuite.attribute('name').value
|
29
29
|
package_attribute = ''
|
@@ -32,15 +32,15 @@ module Fastlane
|
|
32
32
|
end
|
33
33
|
target_testsuite = REXML::XPath.first(target_report, "//testsuite[@name='#{testsuite_name}' #{package_attribute}]")
|
34
34
|
if target_testsuite
|
35
|
-
|
35
|
+
verbose(" > collating testsuite #{testsuite_name}")
|
36
36
|
collate_testsuite(target_testsuite, testsuite)
|
37
|
-
|
37
|
+
verbose(" < collating testsuite #{testsuite_name}")
|
38
38
|
else
|
39
39
|
testable = REXML::XPath.first(target_report, "//testsuites")
|
40
40
|
testable << testsuite
|
41
41
|
end
|
42
42
|
end
|
43
|
-
|
43
|
+
verbose("< collating last report file #{report_filepaths.last}")
|
44
44
|
end
|
45
45
|
target_report.elements.each('//testsuite') do |testsuite|
|
46
46
|
update_testsuite_counts(testsuite)
|
@@ -83,12 +83,12 @@ module Fastlane
|
|
83
83
|
testsuite_name = testsuite.attribute('name').value
|
84
84
|
duplicate_testsuites = REXML::XPath.match(report, "//testsuite[@name='#{testsuite_name}']")
|
85
85
|
if duplicate_testsuites.size > 1
|
86
|
-
|
86
|
+
verbose(" > flattening_duplicate_testsuites")
|
87
87
|
duplicate_testsuites.drop(1).each do |duplicate_testsuite|
|
88
88
|
collate_testsuite(testsuite, duplicate_testsuite)
|
89
89
|
duplicate_testsuite.parent.delete_element(duplicate_testsuite)
|
90
90
|
end
|
91
|
-
|
91
|
+
verbose(" < flattening_duplicate_testsuites")
|
92
92
|
end
|
93
93
|
update_testsuite_counts(testsuite)
|
94
94
|
end
|
@@ -108,14 +108,14 @@ module Fastlane
|
|
108
108
|
target_testcase = REXML::XPath.first(target_testsuite, "testcase[@name='#{name}' and @classname='#{classname}']")
|
109
109
|
# Replace target_testcase with testcase
|
110
110
|
if target_testcase
|
111
|
-
|
112
|
-
|
111
|
+
verbose(" collate_testsuite with testcase #{name}")
|
112
|
+
verbose(" replacing \"#{target_testcase}\" with \"#{testcase}\"")
|
113
113
|
parent = target_testcase.parent
|
114
114
|
increment_testcase_tries(target_testcase, testcase) unless testcase.root == target_testcase.root
|
115
115
|
parent.insert_after(target_testcase, testcase)
|
116
116
|
parent.delete_element(target_testcase)
|
117
|
-
|
118
|
-
|
117
|
+
verbose("")
|
118
|
+
verbose(" target_testcase after replacement \"#{parent}\"")
|
119
119
|
else
|
120
120
|
target_testsuite << testcase
|
121
121
|
end
|
@@ -165,6 +165,12 @@ module Fastlane
|
|
165
165
|
(value1 + value2).to_s
|
166
166
|
end
|
167
167
|
|
168
|
+
def self.verbose(message)
|
169
|
+
return if ENV.fetch('COLLATE_JUNIT_REPORTS_VERBOSITY', 1).to_i.zero?
|
170
|
+
|
171
|
+
UI.verbose(message)
|
172
|
+
end
|
173
|
+
|
168
174
|
#####################################################
|
169
175
|
# @!group Documentation
|
170
176
|
#####################################################
|
@@ -1,6 +1,13 @@
|
|
1
1
|
module TestCenter
|
2
2
|
module Helper
|
3
3
|
module HtmlTestReport
|
4
|
+
|
5
|
+
def self.verbose(message)
|
6
|
+
return if ENV.fetch('COLLATE_HTML_REPORTS_VERBOSITY', 1).to_i.zero?
|
7
|
+
|
8
|
+
FastlaneCore::UI.verbose(message)
|
9
|
+
end
|
10
|
+
|
4
11
|
class Report
|
5
12
|
require 'rexml/formatters/transitive'
|
6
13
|
|
@@ -24,16 +31,16 @@ module TestCenter
|
|
24
31
|
def collate_report(report)
|
25
32
|
testsuites.each(&:remove_duplicate_testcases)
|
26
33
|
report.testsuites.each(&:remove_duplicate_testcases)
|
27
|
-
|
34
|
+
HtmlTestReport.verbose("TestCenter::Helper::HtmlTestReport::Report.collate_report to report:\n\t#{@root}")
|
28
35
|
report.testsuites.each do |given_testsuite|
|
29
36
|
existing_testsuite = testsuite_with_title(given_testsuite.title)
|
30
37
|
if existing_testsuite.nil?
|
31
|
-
|
38
|
+
HtmlTestReport.verbose("\tadding testsuite\n\t\t#{given_testsuite}")
|
32
39
|
add_testsuite(given_testsuite)
|
33
40
|
else
|
34
|
-
|
41
|
+
HtmlTestReport.verbose("\tcollating testsuite\n\t\t#{given_testsuite.root}")
|
35
42
|
existing_testsuite.collate_testsuite(given_testsuite)
|
36
|
-
|
43
|
+
HtmlTestReport.verbose("\tafter collation exiting testsuite\n\t\t#{existing_testsuite.root}")
|
37
44
|
end
|
38
45
|
end
|
39
46
|
update_test_count
|
@@ -210,15 +217,15 @@ module TestCenter
|
|
210
217
|
given_testcases.each do |given_testcase|
|
211
218
|
existing_testcase = testcase_with_title(given_testcase.title)
|
212
219
|
if existing_testcase.nil?
|
213
|
-
|
220
|
+
HtmlTestReport.verbose("\t\tadding testcase\n\t\t\t#{given_testcase.root}")
|
214
221
|
unless given_testcase.passing?
|
215
|
-
|
222
|
+
HtmlTestReport.verbose("\t\t\twith failure:\n\t\t\t\t#{given_testcase.failure_details}")
|
216
223
|
end
|
217
224
|
add_testcase(given_testcase)
|
218
225
|
else
|
219
|
-
|
226
|
+
HtmlTestReport.verbose("\t\tupdating testcase\n\t\t\t#{existing_testcase.root}")
|
220
227
|
unless given_testcase.passing?
|
221
|
-
|
228
|
+
HtmlTestReport.verbose("\t\t\twith failure:\n\t\t\t\t#{given_testcase.failure_details}")
|
222
229
|
end
|
223
230
|
existing_testcase.update_testcase(given_testcase)
|
224
231
|
end
|
@@ -275,7 +282,7 @@ module TestCenter
|
|
275
282
|
color = row_color
|
276
283
|
failure = failure_details
|
277
284
|
if failure.nil? && !passing?
|
278
|
-
|
285
|
+
HtmlTestReport.error("\t\t\t\tupdating failing test case that does not have failure_details")
|
279
286
|
end
|
280
287
|
parent = @root.parent
|
281
288
|
|
@@ -283,7 +290,7 @@ module TestCenter
|
|
283
290
|
|
284
291
|
new_failure = testcase.failure_details
|
285
292
|
if new_failure && testcase.passing?
|
286
|
-
|
293
|
+
HtmlTestReport.error("\t\t\t\tswapping passing failing test case that _does_have_ failure_details")
|
287
294
|
end
|
288
295
|
|
289
296
|
parent.replace_child(@root, testcase.root)
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: fastlane-plugin-test_center
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 3.14.
|
4
|
+
version: 3.14.8
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Lyndsey Ferguson
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2020-
|
11
|
+
date: 2020-11-13 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: json
|