Test automation of mobile apps
Transcript of Test automation of mobile apps
Test automation of Mobile AppsRičardas Vaitkus
Mobile is taking over the world. But how do we scale mobile quality?scale mobile quality?scale mobile quality?scale mobile quality?
Native Web Hybrid apps
Hybrid apps maker
• PhoneGap
Mobile apps testing
• Appium is cross-platform solution for native and hybrid mobile automation
Appium philosophy
• Test the same app you submit to the market
• Write test in any language, using any framework
• Use standard automation specification and API
Support platforms
• Real devices
• Simulators
• Native apps
• Hybrid apps
• Mobile web
• Robots?!
Appium in space
iOS• Calabash-ios
• Frank
• UIAutomation
• ios-driver
• KeepItFunctional
Android• Calabash-android
• MonkeyTalk
• Robotium
• UiAutomator
• Selendroid
Selenium WebDriver• Is standard for browser automation, with libraries in
every* language
• Is used every single day by thousands of developers familiar with its model
• Is an HTTP API• POST /session
• POST /session/element
• GET /session/element/:id/:attr
• Is a W3C working draft
Languages • WebDriver compatible
• Java
• Objective-C
• JavaScript with Node.js
• PHP
• Python
• Ruby
• C#
• Perl
• Clojure
Appium architecture
• Appium is an HTTP server that creates and handles WebDriver sessions
• Appium starts a “test case” on the device that spawns a server and listens for proxiedcommands
Appium architecture
• On iOS, appium proxies commands to a UIAutomation script running in Istruments
Appium architecture
• On Android, appium proxies commands to a UiAutomator test case running on device
Automation frameworks
• iOS – UIAutomation
• Android >= 4.2 – UiAutomator
• Android < 4.2 & Hybrid – Selendroid
• FireFoxOS – Marionette
Gestures
• taptaptaptap (on screen or on element)
• flickflickflickflick (on screen or on element)
• swipe/dragswipe/dragswipe/dragswipe/drag (on screen or on element)
• scroll scroll scroll scroll totototo (element)
• sliderslidersliderslider
• shakeshakeshakeshake
• longTaplongTaplongTaplongTap (element)
Appium opens door to crosscrosscrosscross----platform mobile platform mobile platform mobile platform mobile testingtestingtestingtesting: one test, two mobile platforms