fastlane-plugin-android_testlab_script_swit 0.1.914 → 0.1.916

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
  SHA256:
3
- metadata.gz: 98dd87d5fba0d3ea3b0875c3b3ff477037d6e0dfe5c04a18d52fc4a86729a31f
4
- data.tar.gz: 5e0ca28409ced3a40dadf5779f7b52b73f2186a1042fcf573ffb968ad9370083
3
+ metadata.gz: 16f5b4ce741d819dd105c9a915259481e748a9d1f7d70d33021d58768eafac30
4
+ data.tar.gz: c13498ef4f0e1a6ae7b9c061277fcef6e4dbb64aa4551d8e49265bb3a2154cea
5
5
  SHA512:
6
- metadata.gz: 12eb582f3ca20ab110c9261fc9bf6d28ba09accf5dcc9aa2652b457833cfd1311c41df374d15d037dac675eaba2a8b5e5a7ae8aa270a9228e4fda34be22ae4f7
7
- data.tar.gz: 4b392f1be62944f7cd1de6caa565004eef3a962e1d35f160c75c2ee0031ac0528b579016a23fb911db4bb56a2bac1ef66bb79dce15819e381ccc9a97fa5d4012
6
+ metadata.gz: 704fdef9c914610f101d009c2f1eb3188768af7a719bb7736e16db30901da875b90f4492d15e3f5e39c297ec0dbccd81b925d3999653670ec7e6b2d3518a124b
7
+ data.tar.gz: 314ee9bd65b0e47a96153aba54839ed55d50337b9987f622e3ccc2e92cfb9ea8722086772c07efb3f29f4a000f8adb0e0653fb1d8c23a4db0140b6d8b56c4fb7
@@ -50,25 +50,6 @@ module Fastlane
50
50
  # Firebase Test Lab Result Json
51
51
  resultJson = JSON.parse(File.read(params[:console_log_file_name]))
52
52
 
53
- # 각 JSON 객체에 대해 반복
54
- # resultJson.each do |item|
55
- # # 정보 추출하기
56
- # axis_value = item["axis_value"]
57
- # outcome = item["outcome"]
58
- # test_details = item["test_details"]
59
- #
60
- # # 'axis_value' 분리하기
61
- # parts = axis_value.split('-')
62
- #
63
- # parts.each_with_index do |part, index|
64
- # swit_device_payload += "{\"type\":\"rt_section\",\"indent\":1,\"elements\":[{\"type\":\"rt_text\",\"content\":\"Device#{index + 1}\"}]},
65
- # {\"type\": \"rt_section\",\"indent\":2,\"elements\":[{\"type\":\"rt_text\",\"content\":\"Part : #{parts[index]}\"}]},
66
- # {\"type\":\"rt_section\",\"indent\":2,\"elements\":[{\"type\":\"rt_text\",\"content":"Result : #{outcome}\"}]}"
67
- #
68
- # swit_device_payload += "," unless index == parts.length - 1
69
- # end
70
- # end
71
-
72
53
  resultJson.each_with_index do |item, device_index|
73
54
  # 정보 추출하기
74
55
  axis_value = item["axis_value"]
@@ -81,23 +62,46 @@ module Fastlane
81
62
  swit_device_payload += "{\"type\":\"rt_section\",\"indent\":1,\"elements\":[{\"type\":\"rt_text\",\"content\":\"Device#{device_index + 1}\"}]},"
82
63
 
83
64
  parts.each_with_index do |part, part_index|
84
- swit_device_payload += "{\"type\": \"rt_section\",\"indent\":2,\"elements\":[{\"type\":\"rt_text\",\"content\":\"Part : #{parts[index]}\"}]},"
65
+ swit_device_payload += "{\"type\": \"rt_section\",\"indent\":2,\"elements\":[{\"type\":\"rt_text\",\"content\":\"Part : #{part}\"}]}"
85
66
 
86
67
  if part_index == (parts.length -1)
87
- swit_device_payload += "{\"type\":\"rt_section\",\"indent\":2,\"elements\":[{\"type\":\"rt_text\",\"content\":\"Result : #{outcome}\"}]}"
68
+ safe_outcome = outcome.to_json
69
+ swit_device_payload += ",{\"type\":\"rt_section\",\"indent\":2,\"elements\":[{\"type\":\"rt_text\",\"content\": #{safe_outcome}}]}"
70
+ else
71
+ swit_device_payload += ","
88
72
  end
89
73
  end
90
-
91
- swit_device_payload += "," unless device_index == (resultJson.length - 1) && part_index == (parts.length - 1)
74
+
75
+ swit_device_payload += "," unless device_index == (resultJson.length -1)
92
76
  end
93
77
 
94
78
  # remove the last comma if it exists
95
79
  swit_device_payload.chomp!(',')
96
80
 
81
+
97
82
 
83
+ # 각 JSON 객체에 대해 반복
84
+ # resultJson.each do |item|
85
+ # # 정보 추출하기
86
+ # axis_value = item["axis_value"]
87
+ # outcome = item["outcome"]
88
+ # test_details = item["test_details"]
89
+ #
90
+ # # 'axis_value' 분리하기
91
+ # parts = axis_value.split('-')
92
+ #
93
+ # parts.each_with_index do |part, index|
94
+ # swit_device_payload += "{\"type\":\"rt_section\",\"indent\":1,\"elements\":[{\"type\":\"rt_text\",\"content\":\"Device#{index + 1}\"}]},
95
+ # {\"type\": \"rt_section\",\"indent\":2,\"elements\":[{\"type\":\"rt_text\",\"content\":\"Part : #{parts[index]}\"}]},
96
+ # {\"type\":\"rt_section\",\"indent\":2,\"elements\":[{\"type\":\"rt_text\",\"content":"Result : #{outcome}\"}]}"
97
+ #
98
+ # swit_device_payload += "," unless index == parts.length - 1
99
+ # end
100
+ # end
101
+
102
+
98
103
 
99
-
100
-
104
+
101
105
 
102
106
  # 중간 체크
103
107
  UI.message(swit_device_payload)
@@ -1,5 +1,5 @@
1
1
  module Fastlane
2
2
  module AndroidTestlabScriptSwit
3
- VERSION = "0.1.914"
3
+ VERSION = "0.1.916"
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: fastlane-plugin-android_testlab_script_swit
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.914
4
+ version: 0.1.916
5
5
  platform: ruby
6
6
  authors:
7
7
  - 나비이쁜이