Failing Android Instrumental Test CI job without failing any tests

I currently try to build a GitLab CI script for Android development.

It runs on shared runners currently, planning on registering a runner I use for a private GitLab atm as well. Build’s and unit tests’ jobs pass.

It already runs the tests and saves artifacts as I expect it to, but currently, the instrumental tests’ job fails, even though the artifacts say it passed, while executing every command without a failing one. Anyone know why? I don’t have any idea what is happening there. See below for my .gitlab-ci.yml and job console output.

End of Job console output (full output below)
BUILD SUCCESSFUL in 4m 19s
49 actionable tasks: 49 executed
$ adb -s testAVD emu kill
Uploading artifacts...
android/app/build/reports/androidTests/: found 10 matching files 
Uploading artifacts to coordinator... ok            id=65765493 responseStatus=201 Created token=xS4FJgBh
ERROR: Job failed: exit code 1

.gitlab-ci.yml - about 115 lines

Full job console outpout - about 2400 lines

Edit: link to instrumental test result broken

I found the error. adb -s testAVD emu kill should kill our emulator. Since -s looks for the emulator id, but testAVD is the emulator name, this returns 1. Our solution (since we only have one emulator and in this case adb executes every command for that emulator) was to simply use adb emu kill.