npm install
, hack with Appium, or contributeto Appium, you will need Node.js and NPM (usenvm,n, or brew install node
to installNode.js. Make sure you have not installed Node or Appium with sudo
, otherwiseyou'll run into problems). We recommend the latest stable version, thoughAppium supports Node 10+.appium-doctor
. Install it with npm install -g appium-doctor
, then run theappium-doctor
command, supplying the --ios
or --android
flags to verifythat all of the dependencies are set up correctly.4723
). Thisport information is vital since you will have to direct your test client tomake sure to connect to Appium on this port. If you want to change, the port,you can do so by using the -p
flag when starting Appium (be sure to check outthe full list of serverparameters).webdriverio
:index.js
, and initialize theclient object:wdio.remote()
with them. Desired Capabilities are just a set of keys andvalues that get sent to the Appium server during session initialization, thattell Appium what kind of thing we want to automate. The minimum set of requiredcapabilities for any Appium driver should include:platformName
: the name of the platform to automateplatformVersion
: the version of the platform to automatedeviceName
: the kind of device to automateapp
: the path to the app you want to automate (but use the browserName
capability instead in the case of automating a web browser)automationName
: the name of the driver you wish to usewebdriverio
and now have a client object which will represent theconnection to the Appium server. From here, we can go ahead and start thesession, perform some test commands, and end the session. In our case, we willsimply type into a text field and check that the correct text was entered:node
: