Giter Site home page Giter Site logo

cchongxd / appiumiosautomation Goto Github PK

View Code? Open in Web Editor NEW

This project forked from smritituteja/appiumiosautomation

0.0 2.0 0.0 322 KB

This repository contains sample scripts for iOS Mobile Automation (using a sample Recipe app) using Appium

Java 100.00%

appiumiosautomation's Introduction

iOS Automation using Appium

This repository contains sample scripts for iOS Mobile Automation (using a sample Recipe app) using Appium on MacOSX.

Why Appium:

  1. You don't need to modify it in any way in order to automate it as Appium uses vendor-provided automation frameworks under the hood -
  • iOS: Apple’s UIAutomation
  • Android 4.2+: Google’s UiAutomator
  • Android 2.3+: Google’s Instrumentation (Instrumentation support is provided by bundling a separate project, Selendroid)
  1. You are not locked into a specific language or framework to write and run your tests as the vendor-provided frameworks are wrapped in WebDriver (aka “Selenium WebDriver”) API.
  2. There is no need to reinvent the wheel for automation APIs as WebDriver protocol is extended with extra API methods useful for mobile automation.
  3. Appium is open source. To know more about Appium design and concepts, please refer: http://appium.io/slate/en/master/?java#about-appium

Prerequisites:

  1. MacOSX: 10.7 or higher
  2. Xcode (>= 4.6.3) and command line tools:
  1. Brew:
  1. Node.js and Appium:
  • brew install node # get node.js
  • npm install -g appium # get appium
  • npm install wd # get appium client
  • appium-doctor # check if everything is correctly set
  1. Appium.app (for Appium Inspector) - https://bitbucket.org/appium/appium.app/downloads/
  2. Any IDE, say Eclipse: http://www.eclipse.org/downloads/

Executing a Basic Script

Create a Sample Project:

  1. Launch Eclipse. Click on File -> New -> Other -> Maven project.
  2. Select workspace and archetype-quickstart.
  3. Provide Group and Artifact ID.
  4. Click 'Finish'.
  5. Add Appium Java Client Dependency: You can add appium java client dependency (which is a java language binding for writing Appium tests) in pom.xml as -

Desired Capabilities (for running on Real Device):

  1. DEVICE_NAME: The kind of mobile device to use (iPhone 6, iPhone 5s etc.)
  2. APP: The absolute local path or remote http URL to a .ipa file.
  3. BUNDLE_ID: Unique bundle identifier for the iOS app you want to run (say- com.smriti.myApp). This capability is not required for if you specify 'APP' capability.
  4. UDID: Unique device identifier of your phone (You can get this from iTunes from device details when you connect your phone)

Desired Capabilities (for running on Simulator):

  1. DEVICE_NAME: The kind of mulator to use (iPhone Simulator etc.)
  2. APP: The absolute local path or remote http URL to a .app file.

All other Appium capabilties details can be found here - https://github.com/appium/appium/blob/master/docs/en/writing-running-appium/caps.md

Launch Appium and Run Scripts:

  1. Launch Appium Server: appium &
  2. Run your scripts
  3. To View any element id : Launch Appium Inspector

appiumiosautomation's People

Contributors

smritituteja avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.