fastlane-plugin-trainer 0.1.3 → 0.2.0

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
  SHA1:
3
- metadata.gz: b179a131a685c39c47d7a9f755cb92d27fbb5f24
4
- data.tar.gz: c6ccc5a5c5006ab6f9a428153f7b361d1dce4d1d
3
+ metadata.gz: f0a464261118132526739d08017c9399d688f267
4
+ data.tar.gz: cfbd2004223e6c976e5d3ee2a98b77fdca5c6623
5
5
  SHA512:
6
- metadata.gz: f7d91c7a03cafd3dfb63c41fea00fd0e85877fb69071837bae755bb370f7a3a96fe83cbd52584c84f9a595008b9c8565596bf8d3220866db6ae2f9027c7b1672
7
- data.tar.gz: 73e8b5790a8dfa0da8f8f84bfbac2620dcb79497edfc7e52feb2492b407e20d24ede91544eb80aae5df4908f14c7689bf8876dd8ffe04baee94af53d8176b188
6
+ metadata.gz: 4a56fae8f5fca3a3d6f21fde9f085926ebe1d3f67cbe879de7c715346c2954dd74b15bd35e979471ffee0962d4299937476e39ecd161f8ff8a913ed6e4dfc04e
7
+ data.tar.gz: 204e08f583d0c22a464f117ac7f0b4f8efaf92c59bfdcec20d330fbf22a2699c12d47e22e56e901c05c5a4af1f40e6c90a5ee13ad0daa21b514a9c458e160682
data/README.md CHANGED
@@ -16,10 +16,14 @@ To use `trainer` in your lane, add the following to your `Fastfile`:
16
16
 
17
17
  ```ruby
18
18
  lane :test do
19
- scan(workspace: "MyApp.xcworkspace",
20
- output_types: "",
21
- derived_data_path: "/tmp/fastlane/#{Time.now.to_i}")
22
- trainer
19
+ begin
20
+ scan(workspace: "Themoji.xcworkspace", scheme: "ThemojiUITests", output_types: "")
21
+ rescue => ex
22
+ failure = ex
23
+ end
24
+
25
+ trainer(output_directory: "/tmp/fastlane_trainer/#{Time.now.to_i}")
26
+ raise failure if failure
23
27
  end
24
28
  ```
25
29
 
@@ -4,13 +4,19 @@ module Fastlane
4
4
  def self.run(params)
5
5
  require "trainer"
6
6
 
7
- params[:path] = Actions.lane_context[Actions::SharedValues::SCAN_DERIVED_DATA_PATH] if Actions.lane_context[Actions::SharedValues::SCAN_DERIVED_DATA_PATH]
7
+ params[:path] = Actions.lane_context[Actions::SharedValues::SCAN_GENERATED_PLIST_FILE] if Actions.lane_context[Actions::SharedValues::SCAN_GENERATED_PLIST_FILE]
8
+ params[:path] ||= Actions.lane_context[Actions::SharedValues::SCAN_DERIVED_DATA_PATH] if Actions.lane_context[Actions::SharedValues::SCAN_DERIVED_DATA_PATH]
8
9
 
9
- return ::Trainer::TestParser.auto_convert(params)
10
+ resulting_paths = ::Trainer::TestParser.auto_convert(params)
11
+ resulting_paths.each do |path, test_successful|
12
+ UI.user_error!("Unit tests failed", show_github_issues: false) unless test_successful
13
+ end
14
+
15
+ return resulting_paths
10
16
  end
11
17
 
12
18
  def self.description
13
- "Convert the Xcode plist log to a JUnit report"
19
+ "Convert the Xcode plist log to a JUnit report. This will raise an exception if the tests failed"
14
20
  end
15
21
 
16
22
  def self.authors
@@ -18,7 +24,7 @@ module Fastlane
18
24
  end
19
25
 
20
26
  def self.return_value
21
- ""
27
+ "A hash with the key being the path of the generated file, the value being if the tests were successful"
22
28
  end
23
29
 
24
30
  def self.available_options
@@ -1,5 +1,5 @@
1
1
  module Fastlane
2
2
  module Trainer
3
- VERSION = "0.1.3"
3
+ VERSION = "0.2.0"
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: fastlane-plugin-trainer
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.3
4
+ version: 0.2.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - KrauseFx
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-08-02 00:00:00.000000000 Z
11
+ date: 2016-08-10 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: trainer
@@ -16,14 +16,14 @@ dependencies:
16
16
  requirements:
17
17
  - - ">="
18
18
  - !ruby/object:Gem::Version
19
- version: 0.1.3
19
+ version: 0.2.0
20
20
  type: :runtime
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
24
  - - ">="
25
25
  - !ruby/object:Gem::Version
26
- version: 0.1.3
26
+ version: 0.2.0
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: pry
29
29
  requirement: !ruby/object:Gem::Requirement
@@ -140,9 +140,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
140
140
  version: '0'
141
141
  requirements: []
142
142
  rubyforge_project:
143
- rubygems_version: 2.6.6
143
+ rubygems_version: 2.5.1
144
144
  signing_key:
145
145
  specification_version: 4
146
146
  summary: Convert xcodebuild plist files to JUnit reports
147
147
  test_files: []
148
- has_rdoc: