Skip to content

Instantly share code, notes, and snippets.

@m4rtinpf
m4rtinpf / test-ci.sh
Created May 10, 2024 02:44
Record screen for reactivecircus/android-emulator-runner gh action
#!/bin/sh
set -x
echo "Starting the screen recording..."
adb shell "screenrecord --bugreport /data/local/tmp/testRecording.mp4 & echo \$! > /data/local/tmp/screenrecord_pid.txt" &
set +e
npm run test
TEST_STATUS=$?
echo "Test run completed with status $TEST_STATUS"
adb shell "kill -2 \$(cat /data/local/tmp/screenrecord_pid.txt)"