Search code examples
javaseleniumcucumberappium

Possibilities on integrating existing cucumber framework with appium


I have an existing automated suite for web browser based application on cucumber framework using selenium and java. We are now planning to run the same test scripts for the mobile app of same application. 1. Is it possible to migrate or extend the existing web-based scripts to appium with limited code changes? 2. If option 1 is not possible, then will we have to right the entire scripts again using appium parameters or is it possible to use selenium parameters for identifying the elements of click, textbox etc.? 3. Any guidance or material on this enhancement/integration would be of much help.


Solution

  • 1. Is it possible to migrate or extend the existing web-based scripts to appium with limited code changes?

    The Framework structure could be retained .However i suggest you to create separate suite and test cases to handle appium. Appium takes several parameter to start a session with a particular device and the session value is passed to the scripts , its like the driver being passed to Selenium scripts.

    2. If option 1 is not possible, then will we have to right the entire scripts again using appium parameters or is it possible to use selenium parameters for identifying the elements of click, textbox etc.?

    Appium is an extended version of selenium , so the command like Click element will work , However , i am not sure if the locator value will be same for Web element and App element. You can try to locate your APP locator using Appium Desktop Appium Desktop for locating Elements and verify its values with locators from Web elements .

    Any guidance or material on this enhancement/integration would be of much help.

    Here is a tutorial if you want to learn Appium Appium