fastlane-plugin-test_center 3.1.2 → 3.1.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: f119b2325ee765910138d7f6b2ebe56827a5878b
4
- data.tar.gz: def9b17c46634e4b39a1c87a1d8ed999dd8a3468
3
+ metadata.gz: b0486d5117e1539891943e8ea57c81984fbf67b3
4
+ data.tar.gz: 255a3287ae7045eb149d5009e38bb68dd4c6767c
5
5
  SHA512:
6
- metadata.gz: f40ad69b618f3cf3294adccbe56a9b47a6374907349b143e0bbab6605b0b084d7cabe50da8e6e52fd4a639f654e7d3bddc6273581f62a05ae13aa0b6badafeca
7
- data.tar.gz: 9f776036eece1eb3a66dfe149033d2d12d9d61b14aac4d7688a965300c0d4bbd04c0da54fcc790b7b94fe12c502d04b11a25f1f9da472039efbfc07401dd48e5
6
+ metadata.gz: a44d876d906e83f449dd63f09c335b1bad8db33e3006b02b18cdbef9bc122a5b9dbe1ee35020414c1f3143644aa5e29125285baa041c6d564082eaa66b98c896
7
+ data.tar.gz: 6963a55aaac02d7ce83fdf5d98a7d2ffb998f3b26f276318308c4f2e8c84211c6e518e7ab5ebe75ce5c4b855c079e6391fc1d5565cf96702d02fb0730faba7ac
@@ -57,6 +57,11 @@ module TestCenter
57
57
  output_directory = File.join(@output_directory, "results-#{testable}")
58
58
  end
59
59
  FastlaneCore::UI.header("Starting test run on testable '#{testable}'")
60
+ if @scan_options[:result_bundle]
61
+ FastlaneCore::UI.message("Clearing out previous test_result bundles in #{output_directory}")
62
+ FileUtils.rm_rf(Dir.glob("#{output_directory}/*.test_result"))
63
+ end
64
+
60
65
  tests_passed = correcting_scan(
61
66
  {
62
67
  only_testing: tests_batch,
@@ -79,6 +84,13 @@ module TestCenter
79
84
  tests_passed
80
85
  end
81
86
 
87
+ def test_result_bundlepaths(output_directory, reportnamer)
88
+ [
89
+ File.join(output_directory, @scan_options[:scheme]) + '.test_result',
90
+ File.join(output_directory, @scan_options[:scheme]) + "_#{reportnamer.report_count}.test_result"
91
+ ]
92
+ end
93
+
82
94
  def collate_reports(output_directory, reportnamer)
83
95
  report_files = Dir.glob("#{output_directory}/*#{reportnamer.junit_filextension}").map do |relative_filepath|
84
96
  File.absolute_path(relative_filepath)
@@ -124,6 +136,12 @@ module TestCenter
124
136
  )
125
137
  scan_options[:only_testing] = info[:failed].map(&:shellescape)
126
138
  FastlaneCore::UI.message('Re-running scan on only failed tests')
139
+ if @scan_options[:result_bundle]
140
+ built_test_result, moved_test_result = test_result_bundlepaths(
141
+ scan_options[:output_directory], reportnamer
142
+ )
143
+ FileUtils.mv(built_test_result, moved_test_result)
144
+ end
127
145
  reportnamer.increment
128
146
  retry
129
147
  end
@@ -3,6 +3,8 @@ module TestCenter
3
3
  require 'fastlane_core/ui/ui.rb'
4
4
 
5
5
  class ReportNameHelper
6
+ attr_reader :report_count
7
+
6
8
  def initialize(output_types = nil, output_files = nil, custom_report_file_name = nil)
7
9
  @output_types = output_types || 'junit'
8
10
  @output_files = output_files || custom_report_file_name
@@ -1,5 +1,5 @@
1
1
  module Fastlane
2
2
  module TestCenter
3
- VERSION = "3.1.2"
3
+ VERSION = "3.1.3"
4
4
  end
5
5
  end
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.1.2
4
+ version: 3.1.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Lyndsey Ferguson
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2018-03-26 00:00:00.000000000 Z
11
+ date: 2018-03-27 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: plist