fastlane-plugin-test_center 0.1.0 → 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:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: c77c5cf68c2039fd54bbac8a3e0eb1b8aac0f217
|
4
|
+
data.tar.gz: c0bbb9e7501440b95e910bab387d6844e779f681
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 99799b11ad1794a18dae6924ca7165710690f42e22c3658e3350669fe94410a700b8993cb14bd014bace14bfbb3bb514c3661cbf1152264d0dc3fc2988575328
|
7
|
+
data.tar.gz: bb66c18c3f7f9582481e080ca789ea1932385df03377e8559de4b0b7e209d2dbedb087abbb7313ed3d88a6f627caa0dddfe308ffd8430d5a0355e85b058470a1
|
@@ -0,0 +1,103 @@
|
|
1
|
+
module Fastlane
|
2
|
+
module Actions
|
3
|
+
module SharedValues
|
4
|
+
SUPPRESSED_TESTS_CUSTOM_VALUE = :SUPPRESSED_TESTS_CUSTOM_VALUE
|
5
|
+
end
|
6
|
+
|
7
|
+
class SuppressedTestsAction < Action
|
8
|
+
require 'set'
|
9
|
+
|
10
|
+
def self.run(params)
|
11
|
+
project_path = params[:xcodeproj]
|
12
|
+
scheme = params[:scheme]
|
13
|
+
|
14
|
+
scheme_filepaths = Dir.glob("#{project_path}/{xcshareddata,xcuserdata}/**/xcschemes/#{scheme || '*'}.xcscheme")
|
15
|
+
if scheme_filepaths.length.zero?
|
16
|
+
UI.user_error!("Error: cannot find any scheme named #{scheme}") unless scheme.nil?
|
17
|
+
UI.user_error!("Error: cannot find any schemes in the Xcode project")
|
18
|
+
end
|
19
|
+
|
20
|
+
skipped_tests = Set.new
|
21
|
+
scheme_filepaths.each do |scheme_filepath|
|
22
|
+
xcscheme = Xcodeproj::XCScheme.new(scheme_filepath)
|
23
|
+
xcscheme.test_action.testables.each do |testable|
|
24
|
+
testable.skipped_tests.map do |skipped_test|
|
25
|
+
skipped_tests.add(skipped_test.identifier)
|
26
|
+
end
|
27
|
+
end
|
28
|
+
end
|
29
|
+
skipped_tests.to_a
|
30
|
+
end
|
31
|
+
|
32
|
+
#####################################################
|
33
|
+
# @!group Documentation
|
34
|
+
#####################################################
|
35
|
+
|
36
|
+
def self.description
|
37
|
+
"A short description with <= 80 characters of what this action does"
|
38
|
+
end
|
39
|
+
|
40
|
+
def self.details
|
41
|
+
# Optional:
|
42
|
+
# this is your chance to provide a more detailed description of this action
|
43
|
+
"You can use this action to do cool things..."
|
44
|
+
end
|
45
|
+
|
46
|
+
def self.available_options
|
47
|
+
# Define all options your action supports.
|
48
|
+
|
49
|
+
# Below a few examples
|
50
|
+
[
|
51
|
+
FastlaneCore::ConfigItem.new(
|
52
|
+
key: :xcodeproj,
|
53
|
+
env_name: "FL_SUPPRESSED_TESTS_XCODE_PROJECT", # The name of the environment variable
|
54
|
+
description: "The file path to the Xcode project file to read the skipped tests from", # a short description of this parameter
|
55
|
+
verify_block: proc do |path|
|
56
|
+
UI.user_error!("Error: Xcode project file path not given!") unless path and !path.empty?
|
57
|
+
UI.user_error!("Error: Xcode project '#{path}' not found!") unless Dir.exist?(path)
|
58
|
+
end
|
59
|
+
),
|
60
|
+
FastlaneCore::ConfigItem.new(
|
61
|
+
key: :scheme,
|
62
|
+
optional: true,
|
63
|
+
env_name: "FL_SUPPRESSED_TESTS_SCHEME_TO_UPDATE", # The name of the environment variable
|
64
|
+
description: "The Xcode scheme where the suppressed tests may be", # a short description of this parameter
|
65
|
+
verify_block: proc do |scheme_name|
|
66
|
+
UI.user_error!("Error: Xcode Scheme '#{scheme_name}' is not valid!") if scheme_name and scheme_name.empty?
|
67
|
+
end
|
68
|
+
)
|
69
|
+
]
|
70
|
+
end
|
71
|
+
|
72
|
+
def self.output
|
73
|
+
# Define the shared values you are going to provide
|
74
|
+
# Example
|
75
|
+
[
|
76
|
+
['SUPPRESSED_TESTS_CUSTOM_VALUE', 'A description of what this value contains']
|
77
|
+
]
|
78
|
+
end
|
79
|
+
|
80
|
+
def self.return_value
|
81
|
+
# If your method provides a return value, you can describe here what it does
|
82
|
+
end
|
83
|
+
|
84
|
+
def self.authors
|
85
|
+
# So no one will ever forget your contribution to fastlane :) You are awesome btw!
|
86
|
+
["Your GitHub/Twitter Name"]
|
87
|
+
end
|
88
|
+
|
89
|
+
def self.is_supported?(platform)
|
90
|
+
# you can do things like
|
91
|
+
#
|
92
|
+
# true
|
93
|
+
#
|
94
|
+
# platform == :ios
|
95
|
+
#
|
96
|
+
# [:ios, :mac].include?(platform)
|
97
|
+
#
|
98
|
+
|
99
|
+
platform == :ios
|
100
|
+
end
|
101
|
+
end
|
102
|
+
end
|
103
|
+
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: 0.
|
4
|
+
version: 0.2.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Lyndsey Ferguson
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2017-10-
|
11
|
+
date: 2017-10-30 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|
@@ -132,6 +132,7 @@ files:
|
|
132
132
|
- README.md
|
133
133
|
- lib/fastlane/plugin/test_center.rb
|
134
134
|
- lib/fastlane/plugin/test_center/actions/suppress_tests.rb
|
135
|
+
- lib/fastlane/plugin/test_center/actions/suppressed_tests.rb
|
135
136
|
- lib/fastlane/plugin/test_center/actions/test_center_action.rb
|
136
137
|
- lib/fastlane/plugin/test_center/helper/test_center_helper.rb
|
137
138
|
- lib/fastlane/plugin/test_center/version.rb
|
@@ -160,3 +161,4 @@ signing_key:
|
|
160
161
|
specification_version: 4
|
161
162
|
summary: Makes testing your iOS app easier
|
162
163
|
test_files: []
|
164
|
+
has_rdoc:
|