fastlane-plugin-automated_test_emulator_run 0.5.12 → 0.5.13
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: 3070c7dec3e0bcf261efbf9e2608910a0fe068f4
|
4
|
+
data.tar.gz: 9c4fdb8f55df7c2e980d4e785159269d9b33246d
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 4cb6bf31416caba2297db471f4a2881244af67d767833963fada9ec28cf88cbde741cc2cc3bfc48bd68375f71f9fcfa9083f5edb4cb19fc7fdb344d45068cd80
|
7
|
+
data.tar.gz: 1e35fbc09bd0ba8bc96541f30a8af42da7f7deaa47d1d2a3b483a2775e243c36cb9a1e13ba114acdec6737c22fd56c48638318c3763dc6a833ef2e660652eaf6
|
data/lib/fastlane/plugin/automated_test_emulator_run/actions/automated_test_emulator_run_action.rb
CHANGED
@@ -125,6 +125,11 @@ module Fastlane
|
|
125
125
|
UI.message("Emulator loading took more than 3 minutes. Restarting emulator launch until.".yellow)
|
126
126
|
adb_devices_result = Action.sh(sdkRoot + "/platform-tools/adb devices")
|
127
127
|
if adb_devices_result.include? "offline"
|
128
|
+
kill_emulator(sdkRoot, port, params)
|
129
|
+
|
130
|
+
delayInSeconds = 20.0
|
131
|
+
sleep(delayInSeconds)
|
132
|
+
|
128
133
|
launchEmulator(start_avd_command, sdkRoot, port, params)
|
129
134
|
break
|
130
135
|
end
|
@@ -145,17 +150,25 @@ module Fastlane
|
|
145
150
|
Action.sh(sdkRoot + "/platform-tools/adb start-server")
|
146
151
|
end
|
147
152
|
|
148
|
-
def self.
|
153
|
+
def self.kill_emulator(sdkRoot, port, params)
|
149
154
|
UI.message("Shutting down emulator...".green)
|
150
155
|
Action.sh(sdkRoot + "/platform-tools/adb -s " + ["emulator-", port].join("") + " emu kill &>/dev/null")
|
156
|
+
end
|
151
157
|
|
152
|
-
|
153
|
-
sleep(delayInSeconds)
|
154
|
-
|
158
|
+
def self.delete_emulator(sdkRoot, port, params)
|
155
159
|
UI.message("Deleting emulator....".green)
|
156
160
|
Action.sh(sdkRoot + "/tools/android delete avd -n #{params[:avd_name]}")
|
157
161
|
end
|
158
162
|
|
163
|
+
def self.waitFor_emulatorStop(sdkRoot, port, params)
|
164
|
+
kill_emulator(sdkRoot, port, params)
|
165
|
+
|
166
|
+
delayInSeconds = 20.0
|
167
|
+
sleep(delayInSeconds)
|
168
|
+
|
169
|
+
delete_emulator(sdkRoot, port, params)
|
170
|
+
end
|
171
|
+
|
159
172
|
def self.available_options
|
160
173
|
[
|
161
174
|
FastlaneCore::ConfigItem.new(key: :avd_name,
|