@@ -145,15 +145,39 @@ workflows:
145145 - name : Launch emulator for instrumented tests
146146 script : |
147147 cd $ANDROID_HOME/tools
148- emulator -avd emulator-35 -memory 4096 &
148+
149+ emulator -avd emulator-36 \
150+ -memory 8192 \
151+ -no-window \
152+ -no-audio \
153+ -no-boot-anim \
154+ -no-snapshot \
155+ -wipe-data \
156+ -cores 2 &
157+
149158 adb wait-for-device
159+
160+ echo "Booting emulator..."
161+ until [[ "$(adb shell getprop sys.boot_completed 2>/dev/null)" == "1" ]]; do
162+ printf '.'
163+ sleep 5
164+ done
165+ echo " Emulator booted!"
166+
167+ sleep 5
168+
169+ echo "Emulator is ready"
150170 when :
151171 condition : ${{ inputs.enableTests_input }}
152172 - name : Run instrumented tests
153173 script : |
154174 set -e
155175 cd $CM_BUILD_DIR
156- ./gradlew connectedDebugAndroidTest -Dorg.gradle.jvmargs="-Xmx4g"
176+
177+ ./gradlew connectedDebugAndroidTest \
178+ -Dorg.gradle.jvmargs="-Xmx4g" \
179+ -Dorg.gradle.daemon=false
180+
157181 adb logcat -d > emulator.log
158182 when :
159183 condition : ${{ inputs.enableTests_input }}
@@ -245,13 +269,37 @@ workflows:
245269 - name : Launch emulator for instrumented tests
246270 script : |
247271 cd $ANDROID_HOME/tools
248- emulator -avd emulator-35 -memory 4096 &
272+
273+ emulator -avd emulator-36 \
274+ -memory 8192 \
275+ -no-window \
276+ -no-audio \
277+ -no-boot-anim \
278+ -no-snapshot \
279+ -wipe-data \
280+ -cores 2 &
281+
249282 adb wait-for-device
283+
284+ echo "Booting emulator..."
285+ until [[ "$(adb shell getprop sys.boot_completed 2>/dev/null)" == "1" ]]; do
286+ printf '.'
287+ sleep 5
288+ done
289+ echo " Emulator booted!"
290+
291+ sleep 5
292+
293+ echo "Emulator is ready"
250294 - name : Run instrumented tests
251295 script : |
252296 set -e
253297 cd $CM_BUILD_DIR
254- ./gradlew clean connectedDebugAndroidTest -Dorg.gradle.jvmargs="-Xmx4g"
298+
299+ ./gradlew connectedDebugAndroidTest \
300+ -Dorg.gradle.jvmargs="-Xmx4g" \
301+ -Dorg.gradle.daemon=false
302+
255303 adb logcat -d > emulator.log
256304 - name : Build RIA DigiDoc
257305 script : |
0 commit comments