androidjenkinsandroid-emulatorjenkins-pluginscalabash-android

calabash-android - error installing APK - remote Read-only file system


I am trying to run calabash-android tests on my Android APK, on one machine with one emulator the tests run fine, however on another machine with the same code but a different emulator I get an error.

Here are the commands I run in a .sh file:

rm -rf screenshot*
rm -rf test_servers
bundle exec calabash-android build "jenkins.apk"
bundle exec calabash-android run "jenkins.apk" -p android -v

And here is the error log:

2017-04-28 14:03:36 - Installing: test_servers/0124c485b6b2589f08b4f8d4e6c01c05_0.9.0.apk 2017-04-28 14:03:36 - [ 10%] /data/local/tmp/0124c485b6b2589f08b4f8d4e6c01c05_0.9.0.apk [ 21%] /data/local/tmp/0124c485b6b2589f08b4f8d4e6c01c05_0.9.0.apk [ 32%] /data/local/tmp/0124c485b6b2589f08b4f8d4e6c01c05_0.9.0.apk [ 43%] /data/local/tmp/0124c485b6b2589f08b4f8d4e6c01c05_0.9.0.apk [ 53%] /data/local/tmp/0124c485b6b2589f08b4f8d4e6c01c05_0.9.0.apk [ 64%] /data/local/tmp/0124c485b6b2589f08b4f8d4e6c01c05_0.9.0.apk [ 75%] /data/local/tmp/0124c485b6b2589f08b4f8d4e6c01c05_0.9.0.apk [ 86%] /data/local/tmp/0124c485b6b2589f08b4f8d4e6c01c05_0.9.0.apk [ 96%] /data/local/tmp/0124c485b6b2589f08b4f8d4e6c01c05_0.9.0.apk [100%] /data/local/tmp/0124c485b6b2589f08b4f8d4e6c01c05_0.9.0.apk adb: error: failed to copy 'test_servers/0124c485b6b2589f08b4f8d4e6c01c05_0.9.0.apk' to '/data/local/tmp/0124c485b6b2589f08b4f8d4e6c01c05_0.9.0.apk': remote Read-only file system test_servers/0124c485b6b2589f08b4f8d4e6c01c05_0.9.0.apk: 0 files pushed. 11.6 MB/s (609369 bytes in 0.050s) 2017-04-28 14:03:40 - java -jar "/usr/local/lib/ruby/gems/2.4.0/gems/calabash-android-0.9.0/lib/calabash-android/lib/screenshotTaker.jar" emulator-5744 "screenshot_0.png" 2017-04-28 14:03:41 - It looks like your app is no longer running. It could be because of a crash or because your test script shut it down. 2017-04-28 14:03:41 - Server not responding. Moving on. Build step 'Execute shell' marked build as failure

Can anyone explain why the apk won't install on this emulator, why does it have a "Remote Read-Only file system?

EDIT: I have tried adding the following:

adb remount

But I still get the same error.


Solution

  • Can you try

    adb shell
    su
    mount -o remount,rw /system
    

    and let me know what that does? Credit