fastlane-plugin-setup_fragile_tests_for_rescan 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: cc520076d6839fad491f10e5744e146b6cef60cb
4
- data.tar.gz: '011269f1e5758259d139e321cdd7ce68c75bce19'
3
+ metadata.gz: 557fef7f513fde4f3de38598da039a33ec049f68
4
+ data.tar.gz: e434a406c5d51131d7bf71b37ba01d14f886cd44
5
5
  SHA512:
6
- metadata.gz: 5f0888622cc94b6c24de323407ee94d2052470526536f2ee1d9356b418eacba7abf78b54053e54dc24e6a95e4743b9b3d02c935c9b80dee8dcd073f74792d670
7
- data.tar.gz: 49c3e2268346a698b50a44de8f5acbbb24a29c1afbbbb47a4a06d0b7b53367158bc4f0f507b59c6786ed891bb21f388a03fceed14229b67f61f7b4bc45da76c7
6
+ metadata.gz: d814ddba9a369090685423a3fc88657b45acead4b4d56d006d5b773878cb91ae37feb827476e72005be08f020445e68edd9a4610a112be1f673c0d6c6e406bbd
7
+ data.tar.gz: ec20dc5fc30aa47a1ad59cf20381bfea57b1e927b0330ec2e2d2ceb9fb9faa0d25812e48e1315d28d71ea4d17745586172fb4d39c02ad1f113f0eb480c789229
@@ -28,7 +28,7 @@ module Fastlane
28
28
 
29
29
  report_file.xpath('//testcase').each do |testcase|
30
30
  skipped_test = Xcodeproj::XCScheme::TestAction::TestableReference::SkippedTest.new
31
- skipped_test.identifier = "#{testcase['classname']}/#{testcase['name']}"
31
+ skipped_test.identifier = skipped_test_identifier(testcase['classname'], testcase['name'])
32
32
  testable.add_skipped_test(skipped_test)
33
33
  is_dirty = true
34
34
  summary << [skipped_test.identifier]
@@ -36,13 +36,15 @@ module Fastlane
36
36
  end
37
37
  end
38
38
  if is_dirty
39
+ scheme.save!
39
40
  table = Terminal::Table.new(
40
41
  title: 'setup_fragile_tests_for_rescan suppressed the following tests',
41
42
  rows: summary
42
43
  )
43
44
  UI.success("\n#{table}")
45
+ else
46
+ UI.error('No passing tests found for suppression')
44
47
  end
45
- scheme.save!
46
48
  end
47
49
 
48
50
  def self.xcscheme(params)
@@ -58,6 +60,13 @@ module Fastlane
58
60
  Xcodeproj::XCScheme.new(scheme_filepath)
59
61
  end
60
62
 
63
+ def self.skipped_test_identifier(testcase_class, testcase_testmethod)
64
+ is_swift = testcase_class.include?('.')
65
+ testcase_class.gsub!(/.*\./, '')
66
+ testcase_testmethod << '()' if is_swift
67
+ "#{testcase_class}/#{testcase_testmethod}"
68
+ end
69
+
61
70
  def self.description
62
71
  "Suppress stabile tests so that 'scan' can run the fragile tests again"
63
72
  end
@@ -1,5 +1,5 @@
1
1
  module Fastlane
2
2
  module SetupFragileTestsForRescan
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-setup_fragile_tests_for_rescan
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
  - Lyndsey Ferguson
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-01-12 00:00:00.000000000 Z
11
+ date: 2017-01-14 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: nokogiri