Public | Automated Build

Last pushed: 2 years ago
Short Description
Short description is empty for this repo.
Full Description

#appium-and-emulator

  • Appium Server setup for android emulator
  • start a container by running either:
    • docker run -i -p 4723:4723 isonic1/appium-and-emulator:latest
    • docker run --privileged -v /dev/bus/usb:/dev/bus/usb -i -p 4723:4723 isonic1/appium-and-emulator:latest
  • Contains the following software:
    • ubuntu 14.04
    • openjdk 7
    • nodejs
    • appium server
    • android sdk 19.1.0
    • android emulator 19

#Test in IRB
$ irb

2.1.1 :199 > require 'appium_lib'

2.1.1 :199 > caps = {
caps: {
platformName: "Android",
deviceName: "ANDROID",
appActivity: 'your_app_activity',
appWaitActivity: 'your_app_wait_activity',
appPackage: 'your_app_package>',
app: 'http://url_to_your_app_location(e.g.localhost/webrick, s3, dropbox)',
newCommandTimeout: '9999'
},
appium_lib: {
server_url: 'http://your_docker_ip_address:4723/wd/hub',
wait: 300
}
}

2.1.1 :199 > Appium::Driver.new(caps).start_driver
2.1.1 :199 > Appium.promote_appium_methods Object

Docker Pull Command
Owner
isonic1
Source Repository

Comments (2)
ystreibel
4 months ago

Hi, I have this log error when I'm using the docker image

info: [debug] Cleaning up Chromedriver
error: Unhandled error: TypeError: Object function () { [native code] } has no method 'stop'
    at androidHybrid.cleanupChromedriver (/home/automator/appium/node_modules/appium/lib/devices/android/android-hybrid.js:198:18)
    at null.<anonymous> (/home/automator/appium/node_modules/appium/lib/devices/android/android.js:197:10)
    at null.<anonymous> (/home/automator/appium/node_modules/appium/lib/devices/android/android.js:219:9)
    at androidCommon.uninstallApp (/home/automator/appium/node_modules/appium/lib/devices/android/android-common.js:465:5)
    at null.<anonymous> (/home/automator/appium/node_modules/appium/lib/devices/android/android.js:217:12)
    at null.<anonymous> (/home/automator/appium/node_modules/appium/lib/devices/android/android.js:226:11)
    at /home/automator/appium/node_modules/appium/node_modules/appium-adb/lib/adb.js:902:7
    at null.<anonymous> (/home/automator/appium/node_modules/appium/node_modules/appium-adb/lib/adb.js:172:9)
    at ChildProcess.exithandler (child_process.js:646:7)
    at ChildProcess.emit (events.js:98:17) context: [POST /wd/hub/session {"desiredCapabilities":{"browserName":"Browser","javascriptEnabled":true,"acceptSslCerts":true,"platform":"ANY","deviceName":"ANDROID","platformName":"Android","name":"Login"}}]
info: <-- POST /wd/hub/session - - ms - -
muneermuhammed
a year ago

How can I run the emulator here? I am getting "bash: android: command not found" error when checking the emulator.