Download the PHP package tajawal/codeception-appium without Composer
On this page you can find all versions of the php package tajawal/codeception-appium. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download tajawal/codeception-appium
More information about tajawal/codeception-appium
Files in tajawal/codeception-appium
Package codeception-appium
Short Description appium driver for codeception framework
License MIT
Informations about the package codeception-appium
Appium Driver for Codeception
Appium driver for codeception for writing mobile tests.
Requirement
- PHP >= 7.0
- Appium
- Inspect App with Appium Desktop
-
Devices:
- Android
-
iOS
-
Install Xcode from the following link or run the following command inside your terminal:
- Install the Carthage dependency manager:
-
Table of Contents
- Install
- Tests
- Writing tests for Android
- Writing tests for iOS
- Generating Actor classes
- Your First Android Test
- Your First iOS Test
- Running tests
Install
Just add me-io/appium-driver-codeception
to your project's composer.json file:
and then run composer install
. This will install codeception appium driver and all it's dependencies. Or run the following command
Tests
Now lets run the following command at the root directory of your project:
This command will creates a configuration file for codeception and tests directory and default test suites.
Writing tests for Android
Now, lets create a new configuration file android.suite.yml
inside tests directory and put the following contents inside of it.
Note:
deviceName
should be set asAndroid device
only for real device. For Android Emulator use the name of the virtual device.
Writing tests for iOS
Now, lets create a new configuration file ios.suite.yml
inside tests directory and put the following contents inside of it.
Generating Actor classes
Now we need to generate actor class for the AndroidGuy
/IosGuy
that we defined in android.suite.yml
/ios.suite.yml
. To generate the actor class for AndroidGuy
/IosGuy
run the following command inside your terminal:
Your First Android Test
To create your first android test create a new directory android
inside tests
folder. After creating the android
folder create a new file FirstAndroidCest.php
and put the following contents inside of it:
Your First iOS Test
To create your first iOS test create a new directory ios
inside tests
folder. After creating the ios
directory create a new file FirstIosCest.php
and put the following contents inside of it:
Running tests
Run the appium server by running the following command:
NOTE: If you want to change IP/Port run the appium command like this:
After running the appium server now you need to start android emulator and install the application that you want to test. If you don't know how to start the emulator you can follow the following guide Setup Genymotion Android Emulators on Mac OS
Now run the following command inside your terminal to run the tests:
Note: While following the steps that are mentioned here if you get
codecept command not found
error try to runcodecept
command like this./vendor/bin/codecept
.
Contributors
A huge thanks to all of our contributors:
Mohamed Meabed 💻 📢 |
Zeeshan Ahmad 💻 🐛 ⚠️ 📖 |
---|
License
The code is available under the MIT license.
All versions of codeception-appium with dependencies
codeception/codeception Version ~2
phpunit/phpunit-selenium Version ~4
symfony/console Version ~4
squizlabs/php_codesniffer Version *