fastlane-plugin-automated_test_emulator_run 0.5.2 → 0.5.3
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: aa3a66de57bf5bb865a477d3f642629298171254
|
4
|
+
data.tar.gz: b848f216520196fe02289ec984e72bb5e1c000a0
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 726f4227a2cf7686549d71442481995e5c594951c9bde5855a233ee2531d8263aa2b80b703f49d2191b10e6a493ec244c20db6fabfe2dcc70abf922c1339f7a2
|
7
|
+
data.tar.gz: a7c189d180bb62d63d7fca9f6d96aa53c1c52bb25091ed9a43d0afa413a6e12589f4e0b2fd134c047a165f8595edc9991435cf41110f9b1db7c36451c11cb29d
|
data/lib/fastlane/plugin/automated_test_emulator_run/actions/automated_test_emulator_run_action.rb
CHANGED
@@ -67,10 +67,8 @@ module Fastlane
|
|
67
67
|
# Starting AVD
|
68
68
|
UI.message("Starting AVD....".yellow)
|
69
69
|
|
70
|
-
emulatorStarted = false
|
71
|
-
|
72
70
|
Action.sh(start_avd_command)
|
73
|
-
|
71
|
+
waitFor_emulatorBoot(sdkRoot, port, params)
|
74
72
|
|
75
73
|
UI.message("Starting tests".green)
|
76
74
|
begin
|
@@ -85,9 +83,7 @@ module Fastlane
|
|
85
83
|
end
|
86
84
|
end
|
87
85
|
|
88
|
-
|
89
|
-
waitFor_emulatorStop(sdkRoot, port, params)
|
90
|
-
end
|
86
|
+
waitFor_emulatorStop(sdkRoot, port, params)
|
91
87
|
end
|
92
88
|
|
93
89
|
def self.getUnusedTcpPort
|
@@ -113,14 +109,14 @@ module Fastlane
|
|
113
109
|
Action.sh("adb devices")
|
114
110
|
return true
|
115
111
|
else
|
116
|
-
timeoutInSeconds=
|
112
|
+
timeoutInSeconds= 180.0
|
117
113
|
startTime = Time.now
|
118
114
|
loop do
|
119
115
|
stdout, _stdeerr, _status = Open3.capture3(sdkRoot + ["/platform-tools/adb -s emulator-", port].join("") + " shell getprop sys.boot_completed")
|
120
116
|
currentTime = Time.now
|
121
117
|
|
122
118
|
if (currentTime - startTime) >= timeoutInSeconds
|
123
|
-
UI.message("Emulator loading took more than
|
119
|
+
UI.message("Emulator loading took more than 3 minutes. Not waiting anymore and trying to run with devices only!".yellow)
|
124
120
|
return false
|
125
121
|
end
|
126
122
|
|
@@ -133,10 +129,8 @@ module Fastlane
|
|
133
129
|
end
|
134
130
|
|
135
131
|
def self.waitFor_emulatorStop(sdkRoot, port, params)
|
136
|
-
adb = Helper::AdbHelper.new(adb_path: sdkRoot + "/platform-tools/adb")
|
137
|
-
|
138
132
|
UI.message("Shutting down emulator...".green)
|
139
|
-
|
133
|
+
Action.sh(sdkRoot + "/platform-tools/adb emu kill &>/dev/null")
|
140
134
|
|
141
135
|
UI.message("Deleting emulator....".green)
|
142
136
|
Action.sh(sdkRoot + "/tools/android delete avd -n #{params[:avd_name]}")
|