fastlane-plugin-android_testlab_script_swit 0.1.903 → 0.1.904
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 9a2582b2a34e80b4848b07e4f96d9209ad884c83303c7deee64a17d2cf28343b
|
4
|
+
data.tar.gz: a5855348551c3cdfa0dbae1d9a7fc92af974301ad0ba0b4aa88352c0bb4eaf2d
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: df36431785eda5980be928b76008702a6531b3e04c361b074d2f795652954b43fdc48075a805d0cf33a84ca3818a805e3964ba975cb59ab5091021d01c919b69
|
7
|
+
data.tar.gz: 4beea81db53274aaddaf82cf275a5e656c7aa36cb409a5412fcfddb3b6adcc1c91bff10aec485d3fd0b17abc30f5c6a00e0f7bdee0fc69cb734c60f2f5752cdd
|
data/lib/fastlane/plugin/android_testlab_script_swit/actions/android_testlab_script_swit_action.rb
CHANGED
@@ -12,8 +12,9 @@ module Fastlane
|
|
12
12
|
def self.run(params)
|
13
13
|
UI.message("********************************")
|
14
14
|
UI.message("Start Action")
|
15
|
-
UI.message(
|
16
|
-
|
15
|
+
UI.message("********************************")
|
16
|
+
UI.message("GCloudChannel :: ", params[:gcloud_components_channel])
|
17
|
+
UI.message("********************************")
|
17
18
|
|
18
19
|
# Result Bucket & Dir
|
19
20
|
results_bucket = params[:firebase_test_lab_results_bucket] || "#{params[:project_id]}_test_results"
|
@@ -28,8 +29,11 @@ module Fastlane
|
|
28
29
|
# RoboScriptOption
|
29
30
|
robo_script_option = params[:robo_script_path].nil? ? "" : "--robo-script #{params[:robo_script_path]} "
|
30
31
|
|
31
|
-
# Swit PayLoad
|
32
|
-
|
32
|
+
# Swit Result PayLoad
|
33
|
+
swit_device_payload = ""
|
34
|
+
|
35
|
+
# Swit Send PayLoad
|
36
|
+
swit_webhook_payload = params[:swit_webhook_payload][0..-5] + ','
|
33
37
|
|
34
38
|
# Run Firebase Test Lab
|
35
39
|
Helper.run_tests(params[:gcloud_components_channel], "--type #{params[:type]} "\
|
@@ -70,14 +74,14 @@ module Fastlane
|
|
70
74
|
|
71
75
|
results.each do |result|
|
72
76
|
result[:parts].each_with_index do |part, index|
|
73
|
-
|
74
|
-
{\"type\": \"rt_section\",\"indent\":2,\"elements\":[{\"type\":\"rt_text\",\"content\":\"model : #{
|
77
|
+
swit_device_payload += "{\"type\":\"rt_section\",\"indent\":1,\"elements\":[{\"type\":\"rt_text\",\"content\":\"Device#{index + 1}\"}]},
|
78
|
+
{\"type\": \"rt_section\",\"indent\":2,\"elements\":[{\"type\":\"rt_text\",\"content\":\"model : #{result[:parts].join(', ')}\"}]},
|
75
79
|
{\"type\":\"rt_section\",\"indent\":2,\"elements\":[{\"type\":\"rt_text\",\"content\":\"OS Version : #{part[:version]}\"}]},
|
76
80
|
{\"type\":\"rt_section\",\"indent\":2,\"elements\":[{\"type\":\"rt_text\",\"content\":\"locale : #{part[:locale]}\"}]},
|
77
81
|
{\"type\":\"rt_section\",\"indent\":2,\"elements\":[{\"type\":\"rt_text\",\"content\":\"orientation : #{part[:orientation]}\"}]},
|
78
82
|
{\"type\":\"rt_section\",\"indent\":2,\"elements\":[{\"type\":\"rt_text\",\"content\":\"Result : #{result[:outcome]}\"}]}"
|
79
83
|
|
80
|
-
|
84
|
+
swit_device_payload += "," unless index == result[:parts].length - 1
|
81
85
|
end
|
82
86
|
end
|
83
87
|
|
@@ -96,13 +100,10 @@ module Fastlane
|
|
96
100
|
end
|
97
101
|
end
|
98
102
|
|
99
|
-
#
|
100
|
-
swit_webhook_payload
|
101
|
-
|
102
|
-
# Add the additional payload and close the square bracket
|
103
|
-
swit_webhook_payload += new_payload + ']}]}'
|
103
|
+
# Swit PayLoad 병합
|
104
|
+
swit_webhook_payload += swit_device_payload + ']}]}'
|
104
105
|
|
105
|
-
# Swit
|
106
|
+
# Swit WebHook
|
106
107
|
HTTParty.post(params[:swit_webhook_url], body: { body_text: swit_webhook_payload }.to_json, headers: { 'Content-Type' => 'application/json' })
|
107
108
|
|
108
109
|
UI.message("********************************")
|