https://github.com/openstf/stf-appium-example
Run Appium test on OpenSTF Device
https://github.com/openstf/stf-appium-example
Last synced: about 1 year ago
JSON representation
Run Appium test on OpenSTF Device
- Host: GitHub
- URL: https://github.com/openstf/stf-appium-example
- Owner: openstf
- Created: 2016-04-10T18:55:44.000Z (about 10 years ago)
- Default Branch: master
- Last Pushed: 2017-11-22T03:37:31.000Z (over 8 years ago)
- Last Synced: 2024-03-25T22:05:58.108Z (about 2 years ago)
- Language: Ruby
- Size: 3.64 MB
- Stars: 106
- Watchers: 9
- Forks: 42
- Open Issues: 6
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
- awesome-appium - Appium Tests in OpenSTF Device Farm - Sample Appium tests runs on STF Device Farm. (Cloud and Docker Solutions)
README
# STF Appium Example

In this tutorial, I am going to explain how to integrate [Appium](http://appium.io/) automated test to OpenSTF device using its [REST API](). Theoretically, it is possible to run automated test of any tool on OpenSTF device. The reason for choosing Appium here is because it is one of the most widely used mobile automated testing tool.
# Prerequisites
- Your device farm is ready and you are using v2.0 or above.
- You have read [OpenSTF API Doc](https://github.com/openstf/stf/blob/master/doc/API.md).
- You know about [Appium](http://appium.io/) and its usages.
# Dependencies
- [NodeJS](https://nodejs.org/en/)
- [Ruby](https://www.ruby-lang.org/en/) > v2.2
# Installation
1. Git clone
```bash
git clone git@github.com:openstf/stf-appium-example.git
```
2. Install appium & other node dependencies
```bash
npm install
```
**Note** You will also need to install all the [Appium Dependencies for Android](https://github.com/appium/appium#android-requirements)
3. Install ruby dependencies
```bash
bundle install --path=bundler/vendor
## In case bundler is not installed, installed it using below command
gem install bundler
```
# Running example tests
1. Update `SWAGGER_URL` in [stf_connect.js](scripts/stf_connect.js) & [stf_disconnect.js](scripts/stf_disconnect.js) with your domain.
2. Create a new Access Token from Settings > Keys > Access Tokens and update [stf_connect.js](scripts/stf_connect.js) & [stf_disconnect.js](scripts/stf_disconnect.js)
3. Run below command
```bash
DEVICE_SERIAL=YOUR_DEVICE_SERIAL ./scripts/run_integration_test.sh
```
4. [Sample test result](./doc/results/result.html)