fastlane-plugin-accessibility_test 0.1.0 → 0.1.1

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: 42f17b7ed13f8635921271d919a2cd82ca81c900
4
- data.tar.gz: 7118da68aae6a03277e8167a4db453ef4ceb7407
3
+ metadata.gz: e6823b3a8793d496cf722f1af9bc2746866b28a5
4
+ data.tar.gz: 40642a652f4131bdcd6886e96cd5f77368c76913
5
5
  SHA512:
6
- metadata.gz: d6a7343e61be863dea59f6b25a0dbba39fb3d6993e09d9262c5e0a70bfa6281435dbed17f2e11b025df0d7647909d286b57cf63e178d2fb33ccb994248206a94
7
- data.tar.gz: a055ca9cd34639467a2d32255b0025a5e50d5e37c258b959cb84e3f9d8b1309d1a2d9c9ea2be0e02687994d3c8b20356c57f4eb73564734b6eed30d52036af2c
6
+ metadata.gz: bf4c2dbd7652561ec6ccbe90de54497f71a8a052d9cfbcd9808df55679e3c4d766990de9716055b7ea3ac1715a0eb023e3bf81298d25f66c51238fb47cca5e09
7
+ data.tar.gz: bae68741e3741fbf0c19126413c443ec954500a06587c4fbaa726de04ae5adf1e25256f1c4d3600314fed00df760888c4e10df690fdb0c7be9d23c0e0a48fcca
@@ -56,7 +56,8 @@ module Fastlane
56
56
  {
57
57
  title: proto.title,
58
58
  message: proto.message,
59
- image: Helper.firebase_object_url(firebase_test_lab_results_bucket, "#{firebase_test_lab_results_dir}/#{device_name}/artifacts/#{File.basename(filePath, ".meta")}.png")
59
+ image: Helper.firebase_object_url(firebase_test_lab_results_bucket, "#{firebase_test_lab_results_dir}/#{device_name}/artifacts/#{File.basename(filePath, ".meta")}.png"),
60
+ type: proto.result_type
60
61
  }
61
62
  )
62
63
  end
@@ -69,9 +70,16 @@ module Fastlane
69
70
 
70
71
  def self.notify_github(params, results)
71
72
  return if params[:github_pr_number] == nil
73
+ errors = results.select { |result| result[:type] == :ERROR }
74
+ warnings = results.select { |result| result[:type] == :WARNING }
72
75
 
73
- summary = results.empty? ? "### :white_check_mark: All test passed" : "### :x: #{results.length} error found."
74
- cells = results.map {|result|
76
+ summary = errors.empty? ?
77
+ "### :white_check_mark: All test passed (with #{warnings.length} warnings)" :
78
+ "### :x: #{errors.length} error found. (with #{errors.length} warnings)"
79
+ error_cells = errors.map {|result|
80
+ "|<img src=\"#{result[:image]}\">|**#{result[:title]}**<br/>#{result[:message]}|\n"
81
+ }.inject(&:+)
82
+ warning_cells = warnings.map {|result|
75
83
  "|<img src=\"#{result[:image]}\">|**#{result[:title]}**<br/>#{result[:message]}|\n"
76
84
  }.inject(&:+)
77
85
 
@@ -81,7 +89,16 @@ module Fastlane
81
89
 
82
90
  |Screenshot|message|
83
91
  |-|-|
84
- #{cells}
92
+ #{error_cells}
93
+
94
+ <details>
95
+ <summary>#{warnings.length} warnings. Click here to see details.</summary>
96
+
97
+ |Screenshot|message|
98
+ |-|-|
99
+ #{warning_cells}
100
+
101
+ </details>
85
102
  EOS
86
103
 
87
104
  UI.message message
@@ -1,5 +1,5 @@
1
1
  module Fastlane
2
2
  module AccessibilityTest
3
- VERSION = "0.1.0"
3
+ VERSION = "0.1.1"
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: fastlane-plugin-accessibility_test
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0
4
+ version: 0.1.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Takeshi Tsukamoto
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2019-09-03 00:00:00.000000000 Z
11
+ date: 2019-09-04 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: pry