O slideshow foi denunciado.
Utilizamos seu perfil e dados de atividades no LinkedIn para personalizar e exibir anúncios mais relevantes. Altere suas preferências de anúncios quando desejar.
Calabash-Driver –
Test Automation for Android
Apps
Dominik Dary
Quality Engineering Europe
eBay International AG
FACTS ABOUT EBAY
EBAY INC. FACTS

•Founded in 1995

•Based in San Jose, California

•27770 Employees worldwide




                        ...
MOBILE FACTS

Mobile Facts                                   Mobile Fun Facts




100,000,000 downloads                   ...
WHO I AM


           Dominik Dary
           Staff Software Engineer in Test
           E-mail: ddary@ebay.com
          ...
CHALLENGES IN
MOBILE TESTING
FIRST CHALLENGE: LOCALIZATION




                    Calabash-Driver – Test Automation for Android Apps   7
SECOND CHALLENGE: DEVICE DIVERSITY




                   Calabash-Driver – Test Automation for Android Apps   8
DEVICES VS. EMULATORS




                   Calabash-Driver – Test Automation for Android Apps   9
MANUAL MOBILE TESTING

•Feature testing is done manual
•Concentrate on top 5 devices
• Functionality, Layout, User Experie...
OUR REQUIREMENTS
FOR MOBILE TEST
AUTOMATION
THE IMPORTANCE OF PARALLEL TEST
   EXECUTION
   •Multiple Apps
   •12 European Sites
   •iOS Devices
      –iPhone vs. iPa...
TECHNICAL HIGH LEVEL OVERVIEW OF
THE WEB TESTS




                   Calabash-Driver – Test Automation for Android Apps  ...
MOBILE TEST AUTOMATION
REQUIREMENTS

•Use the Load Balancer Features of the Selenium
 Grid2 to execute the End-to-End Test...
MOBILE TEST
AUTOMATION
IN PRACTICE
TESTING OF EBAY‘S MOBILE PRODUCTS
 Android Mobile Web   Android Native App                     iOS Native App




        ...
TEST AUTOMATION OF THE
ANDROID APPS
•We use calabash-android on the device and have
 created the Open Source project Calab...
TEST AUTOMATION OF ANDROID APPS


                                                           Selenium Grid
  TestNG       ...
CAPABILITIES ARE USED TO ENCAPSULATE
ANDROID PHONE DETAILS
                                                           Desc...
ANDROID APP TEST CASE
 Tests
 Flow Objects
Objects
Dialog




                   Calabash-Driver – Test Automation for And...
GRID
INTEGRATION
   DEMO
      Calabash-Driver – Test Automation for Android Apps   21
HOW TO WRITE ROBUST END-TO-END TESTS

NATIVE IDS                                  L10N SUPPORT
• Use the native ID like   ...
SPEED UP THE DEVELOPLMENT OF AUTOMATED
TESTS
INTERACTIVE RUBY SHELL                   DIALOG RUNTIME INSPECTION
• Interact...
BUILD IN SUPPORT FOR WEBVIEWS

•Build in support for
 entering text & click on
 buttons
•CSS Selectors are used
•WebView c...
SHOWCASE
https://github.com/DominikDary/gdg-devfest-zrh/




                           Calabash-Driver – Test Automation ...
ADVANTAGES OF USING
CALABASH-DRIVER
•Solution can be integrated into the Selenium Grid
 which enables us to scale
•The con...
FORK ME AT GITHUB




http://calabash-driver.github.com



                    Calabash-Driver – Test Automation for Andro...
CONCLUSION

•No single automation solution for mobile Web,
 Android and iOS apps – and that’s ok!
•Invest into Scalability...
Thank You!
Questions or Comments?



WE ARE HIRING IN
BERLIN!
Sounds interesting for you?
http://ebaycareers.com        Ca...
Próximos SlideShares
Carregando em…5
×

de

Calabash-Driver – Test Automation for Android Apps Slide 1 Calabash-Driver – Test Automation for Android Apps Slide 2 Calabash-Driver – Test Automation for Android Apps Slide 3 Calabash-Driver – Test Automation for Android Apps Slide 4 Calabash-Driver – Test Automation for Android Apps Slide 5 Calabash-Driver – Test Automation for Android Apps Slide 6 Calabash-Driver – Test Automation for Android Apps Slide 7 Calabash-Driver – Test Automation for Android Apps Slide 8 Calabash-Driver – Test Automation for Android Apps Slide 9 Calabash-Driver – Test Automation for Android Apps Slide 10 Calabash-Driver – Test Automation for Android Apps Slide 11 Calabash-Driver – Test Automation for Android Apps Slide 12 Calabash-Driver – Test Automation for Android Apps Slide 13 Calabash-Driver – Test Automation for Android Apps Slide 14 Calabash-Driver – Test Automation for Android Apps Slide 15 Calabash-Driver – Test Automation for Android Apps Slide 16 Calabash-Driver – Test Automation for Android Apps Slide 17 Calabash-Driver – Test Automation for Android Apps Slide 18 Calabash-Driver – Test Automation for Android Apps Slide 19 Calabash-Driver – Test Automation for Android Apps Slide 20 Calabash-Driver – Test Automation for Android Apps Slide 21 Calabash-Driver – Test Automation for Android Apps Slide 22 Calabash-Driver – Test Automation for Android Apps Slide 23 Calabash-Driver – Test Automation for Android Apps Slide 24 Calabash-Driver – Test Automation for Android Apps Slide 25 Calabash-Driver – Test Automation for Android Apps Slide 26 Calabash-Driver – Test Automation for Android Apps Slide 27 Calabash-Driver – Test Automation for Android Apps Slide 28 Calabash-Driver – Test Automation for Android Apps Slide 29
Próximos SlideShares
Mobile WebDriver Selendroid
Avançar

6 gostaram

Compartilhar

Calabash-Driver – Test Automation for Android Apps

Presentation is about how to automate native Android apps using Calabash-Driver and how to leverage an existing selenium grid architecture to allow scaling and parallel testing.
Calabash-Driver Homepage:
http://calabash-driver.github.com

GDG DevFest Showcase Source Code:
https://github.com/DominikDary/gdg-devfest-zrh

Calabash-Driver – Test Automation for Android Apps

  1. 1. Calabash-Driver – Test Automation for Android Apps Dominik Dary Quality Engineering Europe eBay International AG
  2. 2. FACTS ABOUT EBAY
  3. 3. EBAY INC. FACTS •Founded in 1995 •Based in San Jose, California •27770 Employees worldwide Calabash-Driver – Test Automation for Android Apps 3
  4. 4. MOBILE FACTS Mobile Facts Mobile Fun Facts 100,000,000 downloads Every 30 seconds, a woman’s handbag is purchased on of eBay Inc’s apps eBay Mobile. Mobile transaction volume Every 2 minutes, a tablet is bought through eBay Mobile. will double in 2012 to 10 billion USD 1,7 million items Every week, more than 8,000 cars and 340,000 car parts are listed with using mobile apps every week are sold through eBay’s mobile apps. Calabash-Driver – Test Automation for Android Apps 4
  5. 5. WHO I AM Dominik Dary Staff Software Engineer in Test E-mail: ddary@ebay.com G+: Dominik Dary Twitter: @DomeLG Calabash-Driver – Test Automation for Android Apps 5
  6. 6. CHALLENGES IN MOBILE TESTING
  7. 7. FIRST CHALLENGE: LOCALIZATION Calabash-Driver – Test Automation for Android Apps 7
  8. 8. SECOND CHALLENGE: DEVICE DIVERSITY Calabash-Driver – Test Automation for Android Apps 8
  9. 9. DEVICES VS. EMULATORS Calabash-Driver – Test Automation for Android Apps 9
  10. 10. MANUAL MOBILE TESTING •Feature testing is done manual •Concentrate on top 5 devices • Functionality, Layout, User Experience and Localization •In depth EU specific domain knowledge Calabash-Driver – Test Automation for Android Apps 10
  11. 11. OUR REQUIREMENTS FOR MOBILE TEST AUTOMATION
  12. 12. THE IMPORTANCE OF PARALLEL TEST EXECUTION •Multiple Apps •12 European Sites •iOS Devices –iPhone vs. iPad –Version •Android Devices –Manufactures –Screen Sizes –OS Modifications Picture Source: http://www.flickr.com/photos/ippei-janine/483345027/ Calabash-Driver – Test Automation for Android Apps 12
  13. 13. TECHNICAL HIGH LEVEL OVERVIEW OF THE WEB TESTS Calabash-Driver – Test Automation for Android Apps 13
  14. 14. MOBILE TEST AUTOMATION REQUIREMENTS •Use the Load Balancer Features of the Selenium Grid2 to execute the End-to-End Tests in parallel •Manage multiple applications / versions / languages •The Mobile App should not need to be modified (e.g. like adding a test server) •Mobile App Runtime Inspection Support Calabash-Driver – Test Automation for Android Apps 14
  15. 15. MOBILE TEST AUTOMATION IN PRACTICE
  16. 16. TESTING OF EBAY‘S MOBILE PRODUCTS Android Mobile Web Android Native App iOS Native App Calabash-Driver – Test Automation for Android Apps 16
  17. 17. TEST AUTOMATION OF THE ANDROID APPS •We use calabash-android on the device and have created the Open Source project Calabash-Driver •Calabash-Driver integrates the existing open source project Calabash-Android into the Selenium Grid •Calabash-Driver offers a convenient Webdriver like Java API for writing tests http://calabash-driver.github.com/ Calabash-Driver – Test Automation for Android Apps 17
  18. 18. TEST AUTOMATION OF ANDROID APPS Selenium Grid TestNG Hub Test http http Instrumentation http Backend** Calabash Calabash Android Jetty Server Driver Connecto r eBay App ADB Connec- USB tion QE Machine Device Calabash Server Backend ** Component by the open source project Calabash-Android: http://calaba.sh Calabash-Driver – Test Automation for Android Apps 18
  19. 19. CAPABILITIES ARE USED TO ENCAPSULATE ANDROID PHONE DETAILS Described by Capabilities: "locale":"en_GB", "deviceId":"emulator-5556", "sdkVersion":"4.0.3", "aut":"eBayMobile:1.8.1.5" Instrumentation Instrumentation Server Server en_UK de_DE Calabash-Driver Client Calabash-Driver Server Selenium Grid Hub Calabash-Driver – Test Automation for Android Apps 19
  20. 20. ANDROID APP TEST CASE Tests Flow Objects Objects Dialog Calabash-Driver – Test Automation for Android Apps 20
  21. 21. GRID INTEGRATION DEMO Calabash-Driver – Test Automation for Android Apps 21
  22. 22. HOW TO WRITE ROBUST END-TO-END TESTS NATIVE IDS L10N SUPPORT • Use the native ID like • Strings in the Android app can be ‘‘event_list_item_title” to interact with localized for different locales an UI element (string.xml) • driver.findViewById("event_list_item_titl • It is hard to maintain this strings in a e").click(); multi locale test project • Native ids are much more stable in • We use the localisation (l10n) key of multi locale environments the resource file to interact with UI elements • driver.findL10nElement(By.l10nElement ("title_event_details")).waitFor(); Calabash-Driver – Test Automation for Android Apps 22
  23. 23. SPEED UP THE DEVELOPLMENT OF AUTOMATED TESTS INTERACTIVE RUBY SHELL DIALOG RUNTIME INSPECTION • Interactive Command execution • Interactive Debugging of the current • Results are immediately displayed screen • The app can be used to navigate to the • Convenient way to retrieve the Element dialog you want to automate. IDs • Much Faster to use as Hierarchyviewer Calabash-Driver – Test Automation for Android Apps 23
  24. 24. BUILD IN SUPPORT FOR WEBVIEWS •Build in support for entering text & click on buttons •CSS Selectors are used •WebView can be inspected for defining CSS selectors •API: driver.webview(By.css(".button #login")).click(); Calabash-Driver – Test Automation for Android Apps 24
  25. 25. SHOWCASE https://github.com/DominikDary/gdg-devfest-zrh/ Calabash-Driver – Test Automation for Android Apps 25
  26. 26. ADVANTAGES OF USING CALABASH-DRIVER •Solution can be integrated into the Selenium Grid which enables us to scale •The concept of automated testing the Web, Win32, mobile Web and native apps is the same •Fast Rampup for the testers and quick return on investment •Calabash-Driver supports the interaction with elements based on the Localization (L10n) resource bundle key Calabash-Driver – Test Automation for Android Apps 26
  27. 27. FORK ME AT GITHUB http://calabash-driver.github.com Calabash-Driver – Test Automation for Android Apps 27
  28. 28. CONCLUSION •No single automation solution for mobile Web, Android and iOS apps – and that’s ok! •Invest into Scalability by Virtualization •Buy the top devices •Open source is your best friend! Interested in Calabash-Driver? Contribute to our project! Calabash-Driver – Test Automation for Android Apps 28
  29. 29. Thank You! Questions or Comments? WE ARE HIRING IN BERLIN! Sounds interesting for you? http://ebaycareers.com Calabash-Driver – Test Automation for Android Apps 29
  • nikituk1

    Mar. 13, 2017
  • dictcp

    Aug. 13, 2015
  • qytera

    Apr. 4, 2014
  • SriramAngajala

    Jan. 17, 2014
  • adamallidina

    Dec. 13, 2012
  • georgidanov

    Oct. 23, 2012

Presentation is about how to automate native Android apps using Calabash-Driver and how to leverage an existing selenium grid architecture to allow scaling and parallel testing. Calabash-Driver Homepage: http://calabash-driver.github.com GDG DevFest Showcase Source Code: https://github.com/DominikDary/gdg-devfest-zrh

Vistos

Vistos totais

20.262

No Slideshare

0

De incorporações

0

Número de incorporações

11.754

Ações

Baixados

0

Compartilhados

0

Comentários

0

Curtir

6

×