SlideShare a Scribd company logo
1 of 49
Download to read offline
iOS Automation:
The Trifecta
Elizabeth Taylor
Staff QA Engineer, Digimarc Corp.
@blackstonefinn
Agenda
•    Introduction
•    Why automate
•    What to automate
•    How to automate using Xcode Instruments
     •  The Trifecta
     •  Sample Code examples
     •  Demo
Why Automate?
•    Integration testing
•    Catches bugs manual testing can miss
•    Exploratory Testing
•    Automation <3 Stress Tests!
•    Tie it to build system for check-in
•    Regression testing
•    Fast < 10 min per functional area
•    And most of all … it’s FUN J
What to automate?
•  Ask….    is it BBB?


•  Basic App Functionality
•  Boring stuff – copy & legal
•  “Break it” stuff – stress tests & bugs
Automation Framework
•  Xcode > Developer Tool > Instruments
•  Java Script API
•  UI Automation Java Script Reference
Script Framework - Trifecta
1. Navigate Functions

2. Validate Functions

3. Test Suite
Script Framework - Trifecta
1.  Navigate functions
      •  Identify UI Elements
      •  common navigation paths
      •  wrap functions
2.  Validate functions
      •  UI element validation
      •  functional tests
      •  stress tests
3.  Test Suite
      •  import libraries – navigate and validate
      •  list validate functions
Digimarc Discover UI
Digimarc Discover UI
Navigation Functions
Navigation Functions - Purpose

•  Frequently used paths, actions
•  Separate test setup v. feature test
•  Contain iPhone v. iPad UI differences
Creating Nav Functions
1.  ID App UI elements
2.  Write functions - code, debug, code
3.  Wrap functions
Creating Nav Functions
1.  Identify UI elements



               logElementTree();
ID UI Elements
Listen – UI Elements
Navigate Function - goToTab
•  Frequently used paths, actions
Navigate Function - Back
ID UI Elements
Help UI Elements
Navigate Function – Tap Cell
•  Separate test setup v. test logic
Logging



UIAlogger.logMessage(“Song Selected”);
Navigate Function – History List

•  Contain iPhone v. iPad differences
Wrapping Functions
1.  Readability of test script
2.  Fix or change in one place
Target.delay(#)
Navigate Functions ctd.
1.  Rotation
2.  Set App state at end of test
Script Framework - Trifecta
ü  Navigate functions
      •  Identify UI Elements
      •  common navigation paths
      •  wrap functions
2.  Validate functions
      •  UI element validation
      •  functional tests
      •  stress tests
3.  Test Suite
      •  import libraries – navigate and validate
      •  list validate functions
Validation Functions
Validation Functions - Purpose
1.  Validate UI elements are correct
    •  Buttons, Headers
    •  Copy / Strings
    •  Images
2.  Validate functionality
3.  Stress tests
Validate – UI Elements
Validate - Listen UI Elements
Listen UI
Validate – Help UI Elements
Help UI
Logging
1.  Make results easy to view
    •  Test name w/in each function
2.  Create using Log Message
3.  Pass fail logging
4.  Screen shots
5.  Output name of test
Validate – Feedback UI Elements
Submit Feedback
Validate – UI Elements



         >
Validate Functions ctd.
1.  Help –
    •  Submitting Feedback email
2.  History –
    •  Payoff rendering in-app browser
    •  Sharing functionality
    •  Deleting history list items
3.  Stress Tests
Stress Test Candidates
1.    Repeated navigation across the app
2.    Drilling down into nested views
3.    Adding Rotation into the mix
4.    Exit and returning to the application
5.    Repeated item selection - history list*
Script Framework - Trifecta
ü  Navigate functions
      •  Identify UI Elements
      •  common navigation paths
      •  wrap functions
ü  Validate functions
      •  UI element validation
      •  functional tests
      •  stress tests
3.  Test Suite
      •  import libraries – navigate and validate
      •  list validate functions
Test Suites
Test Suites
1.    Import Navigation lib
2.    Import Validation lib for area
3.    Organize by functional areas*
4.    Simple list of validation functions
5.    Logging for output readability
Help - Test Suite
Help Test Suite Results
Script Framework - Trifecta
ü  Navigate functions
      •  Identify UI Elements
      •  common navigation paths
      •  wrap functions
ü  Validate functions
      •  UI element validation
      •  functional tests
      •  stress tests
ü  Test Suite
      •  import libraries – navigate and validate
      •  list validate functions
Demo
Questions &
Feedback
Thank you!

@blackstonefinn

More Related Content

Similar to iOS Automation: The Trifecta

Qtp training session I
Qtp training session IQtp training session I
Qtp training session I
Aisha Mazhar
 
Implementing Test Automation in Agile Projects
Implementing Test Automation in Agile ProjectsImplementing Test Automation in Agile Projects
Implementing Test Automation in Agile Projects
Michael Palotas
 
2 rft simplified_scripting_shinoj_z
2 rft simplified_scripting_shinoj_z2 rft simplified_scripting_shinoj_z
2 rft simplified_scripting_shinoj_z
IBM
 
RFT Simplified Scripting- Shinoj Z
RFT Simplified Scripting- Shinoj ZRFT Simplified Scripting- Shinoj Z
RFT Simplified Scripting- Shinoj Z
Roopa Nadkarni
 
Acceptance Testing of Web UI
Acceptance Testing of Web UIAcceptance Testing of Web UI
Acceptance Testing of Web UI
Vladimir Tsukur
 
Lighting talk CiviCon London 2013
Lighting talk CiviCon London 2013Lighting talk CiviCon London 2013
Lighting talk CiviCon London 2013
erawat
 

Similar to iOS Automation: The Trifecta (20)

iOS UIAutomation
iOS UIAutomation iOS UIAutomation
iOS UIAutomation
 
Infinum Android Talks #13 - Developing Android Apps Like Navy Seals by Ivan Kušt
Infinum Android Talks #13 - Developing Android Apps Like Navy Seals by Ivan KuštInfinum Android Talks #13 - Developing Android Apps Like Navy Seals by Ivan Kušt
Infinum Android Talks #13 - Developing Android Apps Like Navy Seals by Ivan Kušt
 
Qtp training session I
Qtp training session IQtp training session I
Qtp training session I
 
Reliable mobile test automation
Reliable mobile test automationReliable mobile test automation
Reliable mobile test automation
 
Implementing Test Automation in Agile Projects
Implementing Test Automation in Agile ProjectsImplementing Test Automation in Agile Projects
Implementing Test Automation in Agile Projects
 
Implementing Test Automation in Agile Projects
Implementing Test Automation in Agile ProjectsImplementing Test Automation in Agile Projects
Implementing Test Automation in Agile Projects
 
Shift left mobile application testing
Shift left  mobile  application testingShift left  mobile  application testing
Shift left mobile application testing
 
2 rft simplified_scripting_shinoj_z
2 rft simplified_scripting_shinoj_z2 rft simplified_scripting_shinoj_z
2 rft simplified_scripting_shinoj_z
 
RFT Simplified Scripting- Shinoj Z
RFT Simplified Scripting- Shinoj ZRFT Simplified Scripting- Shinoj Z
RFT Simplified Scripting- Shinoj Z
 
How to build a JavaScript toolkit
How to build a JavaScript toolkitHow to build a JavaScript toolkit
How to build a JavaScript toolkit
 
Acceptance Testing of Web UI
Acceptance Testing of Web UIAcceptance Testing of Web UI
Acceptance Testing of Web UI
 
Test automation proposal
Test automation proposalTest automation proposal
Test automation proposal
 
What is an Automation Framework ?
What is an Automation Framework ?�What is an Automation Framework ?�
What is an Automation Framework ?
 
Suparna - Shift Left Testing in Mobile.pptx
Suparna - Shift Left Testing in Mobile.pptxSuparna - Shift Left Testing in Mobile.pptx
Suparna - Shift Left Testing in Mobile.pptx
 
Lighting talk CiviCon London 2013
Lighting talk CiviCon London 2013Lighting talk CiviCon London 2013
Lighting talk CiviCon London 2013
 
Automating Mobile Applications
Automating Mobile ApplicationsAutomating Mobile Applications
Automating Mobile Applications
 
Unit4wt
Unit4wtUnit4wt
Unit4wt
 
Test automation lesson
Test automation lessonTest automation lesson
Test automation lesson
 
Unleashing the Java Tooling in Eclipse IDE - Tips & Tricks!
Unleashing the Java Tooling in Eclipse IDE - Tips & Tricks!Unleashing the Java Tooling in Eclipse IDE - Tips & Tricks!
Unleashing the Java Tooling in Eclipse IDE - Tips & Tricks!
 
Unit4wt
Unit4wtUnit4wt
Unit4wt
 

Recently uploaded

+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
?#DUbAI#??##{{(☎️+971_581248768%)**%*]'#abortion pills for sale in dubai@
 
Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and Myths
Joaquim Jorge
 

Recently uploaded (20)

Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdf
 
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘
 
Strategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherStrategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a Fresher
 
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
 
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
 
A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt Robison
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day Presentation
 
Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
 
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUnderstanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
 
Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...
 
Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and Myths
 
Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processors
 

iOS Automation: The Trifecta