SlideShare ist ein Scribd-Unternehmen logo
1 von 22
Hello I’m

Utsav
SOFTWARE DEVELOPMENT DONE RIGHT
Netherlands | USA | India | France | UK

www.xebia.in; Blog :http://.xebee.xebia.in
Mobile App
Automated
Acceptance
Testing
Utsav Sinha
Problems
• Development and Maintenance
• Adaptable to changes

• Accuracy
• Completeness
Automated Testing Desiderata
• Use Cases are the Test Cases.
• Robust
• Realistic Environment
(Real Devices, Multiple OS Versions….)
• Continuous Integration
• Comprehensive Test report for each step.
•

Flexible Report output formats.
• Cucumber Provides
o a framework for writing software specifications
o a tool for executing those specifications.

• Specifications are written DSLs
• Works with Ruby, Java, .NET, Flex and many more
• http://cukes.info/
Example – Feature
Step Definition
• Make Cucumber Tests come alive.
• Written in various Programming Language (mostly
Ruby)
Calabash
• One Interface Cucumber for iOS and Android
o Reuse of Test Cross Platform (iOS and Android)

•
•
•
•
•

Targets Native and Hybrid apps for Android and iOS
Runs on Physical Device
Support for Hybrid Apps (embedded web-views)
Open Source Tool
Cross Platform Testing
Calabash iOS architecture
•

Calabash tests are executed with the
Cucumber tool and consist of two parts:

•

Client Library written in Ruby

•

Calabash.framework, a server
framework written in Objective-C
Calabash iOS
• To use Calabash we make a special test target in
Xcode that links with calabash.framework
• The Server Framework starts HTTP Server inside the
App, that listens to the request from Client Library.
• The Cucumber tool executes the feature file that
represents the intended behaviour of the App
Under Test.
• The Feature Files contains steps (Predefined or
Custom)
Calabash Androidarchitecture
• Features
• Step-Definitions
• Instrumentation Test
Server: This is another
app which will be
installed and executed
into device.
Calabash iOS
• App is built for Testing by linking a static library
(calabash-server)
o Uses a combination of UIAutomation and other APIs

• Supports Interactive test-development
• Based on Frank but changes some core parts.
o Setting up Frank Requires modification of the app source, inclusion of static
resources and source files manually, where as Calabash has Automated Set
Up. 3 commands and we are done

• Touch Synthesis supports multi-touch, gestures
• Can use device accessibility for identifying views
Queries
•
•
•
•

Explore the App Interactively
Run Command „calabash-ios console‟
It gives us a Calabash console (it is just a Ruby irb with calabash
loaded)
Example irb(main):001:0> query("button")
[0] {

},

"class" => "UIButton",
"frame" => {
"y" => 20,
"width" => 101,
"x" => 20,
"height" => 101

"UIType" => "UIControl",
"description" => "<UIButton: 0x4cc1120; frame = (20 20; 101 101); opaque = NO; autoresize =
RM+BM; layer = <CALayer: 0x4c89cc0>>"
},
Returns an array with objects that are descriptions of the buttons in the current screen in your app
Queries
• The query function
o takes a string query as an argument.
o the query argument is similar to a css selector

• The syntax for queries is based on UIScript,
o but is a new implementation with additional features added (and some
removed).

• UIScript gives a nice "CSS-selector" like approach to
finding view objects in your app screens.
irb(main):001:0> query("tabBarButton").count
=> 4
irb(main):002:0> query("tabBarButton")[0]
=> {"class"=>"UITabBarButton", "frame"=>{"y"=>1, "width"=>76, "x"=>2, "height"=>48},
"UIType"=>"UIControl", "description"=>"<UITabBarButton: 0x856a820; frame = (2 1; 76
48); opaque = NO; layer = <CALayer: 0x856d210>>" }
Let’s test…
Prototype gestures
• Calabash iOS has a number of built-in event
sequences that can be played back.
o (touch, swipe, pinch, etc)

• Events can be relocated (translated) to different
views, and optionally offsets.
• Extensible: you can record your own gestures if
none of the built in suits you.
Summary
•

Calabash iOS tradeoffs and mitigations DSLs: Cucumber, and Query
language (decl, high level)

•

Full power of Ruby in tests

•

Advanced touch synthesis
o
o

recordings give some brittleness, which is
mitigated by supporting relocating and manipulating of recorded event sequences (which are just lists of
dictionaries).

•

Interactive development experience

•

Requires linking of a framework

•

Not good for some games (randomness, “gameplay” & “feel”, timing
critical)

•

Not good for Phone-to-Phone coordination (call, text, bluetooth)
Thank You!!
Utsav Sinha
usinha@xebia.com
References
• https://github.com/calabash
• https://github.com/calabash/calabash-ios
• https://github.com/calabash/calabash-ios/wiki
• https://github.com/calabash/calabash-ios-server
Agile Testing

Current Competencies
Mobile Testing: Appium, Calabash
Performance Testing Tools: JMeter, LoadUI

Automation Frameworks in place
- Selenium/Webdriver keyword driven
- SoapUI

ATDD Tools: Cucumber, Fitnesse, JBehave,
Geb
Language Proficiencies: Java, Ruby, Groovy, Python
Functional automation Tools: Selenium/Webdriver, AUTO IT, SoapUI, QTP
Knowledge Sharing: Speakers in national and international conferences
Contact us @

Websites

www.xebia.in
www.xebia.com
www.xebia.fr

Xebia India

infoindia@xebia.com

Thought
Leadership

Htto://xebee.xebia.in
http://blog.xebia.com
http://podcast.xebia.com

Weitere ähnliche Inhalte

Mehr von Xebia IT Architects

#Continuous delivery with #Deployit
#Continuous delivery with #Deployit#Continuous delivery with #Deployit
#Continuous delivery with #DeployitXebia IT Architects
 
Continuous integration using thucydides(bdd) with selenium
Continuous integration using thucydides(bdd) with seleniumContinuous integration using thucydides(bdd) with selenium
Continuous integration using thucydides(bdd) with seleniumXebia IT Architects
 
Xebia-Agile consulting and training offerings
Xebia-Agile consulting and training offeringsXebia-Agile consulting and training offerings
Xebia-Agile consulting and training offeringsXebia IT Architects
 
Xebia e-Commerce / mCommerce Solutions
Xebia e-Commerce / mCommerce SolutionsXebia e-Commerce / mCommerce Solutions
Xebia e-Commerce / mCommerce SolutionsXebia IT Architects
 
A warm and prosperous Happy Diwali to all our clients
A warm and prosperous Happy Diwali to all our clientsA warm and prosperous Happy Diwali to all our clients
A warm and prosperous Happy Diwali to all our clientsXebia IT Architects
 
"We Plan to double our headcount" - MD, Xebia India
"We Plan to double our headcount" - MD, Xebia India"We Plan to double our headcount" - MD, Xebia India
"We Plan to double our headcount" - MD, Xebia IndiaXebia IT Architects
 
Agile FAQs by Shrikant Vashishtha
Agile FAQs by Shrikant VashishthaAgile FAQs by Shrikant Vashishtha
Agile FAQs by Shrikant VashishthaXebia IT Architects
 
Agile Team Dynamics by Bhavin Chandulal Javia
Agile Team Dynamics by Bhavin Chandulal JaviaAgile Team Dynamics by Bhavin Chandulal Javia
Agile Team Dynamics by Bhavin Chandulal JaviaXebia IT Architects
 
Practicing Agile in Offshore Environment by Himanshu Seth & Imran Mir
Practicing Agile in Offshore Environment by Himanshu Seth & Imran MirPracticing Agile in Offshore Environment by Himanshu Seth & Imran Mir
Practicing Agile in Offshore Environment by Himanshu Seth & Imran MirXebia IT Architects
 
Moving Gradually to Agile Development by Kavita Gupta
Moving Gradually to Agile Development by Kavita GuptaMoving Gradually to Agile Development by Kavita Gupta
Moving Gradually to Agile Development by Kavita GuptaXebia IT Architects
 
Agile vs Waterfall From A Tester's Eyes by Shweta Parashar & Abhishek Agrawal
Agile vs Waterfall From A Tester's Eyes by Shweta Parashar & Abhishek AgrawalAgile vs Waterfall From A Tester's Eyes by Shweta Parashar & Abhishek Agrawal
Agile vs Waterfall From A Tester's Eyes by Shweta Parashar & Abhishek AgrawalXebia IT Architects
 
What Made Paul A Great Product Owner
What Made Paul A Great Product OwnerWhat Made Paul A Great Product Owner
What Made Paul A Great Product OwnerXebia IT Architects
 
Scaling Agile Hurts by Vibhu Srinivasan
Scaling Agile Hurts by Vibhu SrinivasanScaling Agile Hurts by Vibhu Srinivasan
Scaling Agile Hurts by Vibhu SrinivasanXebia IT Architects
 
Agile Team Smells : Early Detection and Fixes by Anurag Shrivastava
Agile Team Smells : Early Detection and Fixes by Anurag ShrivastavaAgile Team Smells : Early Detection and Fixes by Anurag Shrivastava
Agile Team Smells : Early Detection and Fixes by Anurag ShrivastavaXebia IT Architects
 

Mehr von Xebia IT Architects (20)

#Continuous delivery with #Deployit
#Continuous delivery with #Deployit#Continuous delivery with #Deployit
#Continuous delivery with #Deployit
 
Continuous integration using thucydides(bdd) with selenium
Continuous integration using thucydides(bdd) with seleniumContinuous integration using thucydides(bdd) with selenium
Continuous integration using thucydides(bdd) with selenium
 
Battlefield agility
Battlefield agilityBattlefield agility
Battlefield agility
 
Fish!ing for agile teams
Fish!ing for agile teamsFish!ing for agile teams
Fish!ing for agile teams
 
Xebia-Agile consulting and training offerings
Xebia-Agile consulting and training offeringsXebia-Agile consulting and training offerings
Xebia-Agile consulting and training offerings
 
Xebia e-Commerce / mCommerce Solutions
Xebia e-Commerce / mCommerce SolutionsXebia e-Commerce / mCommerce Solutions
Xebia e-Commerce / mCommerce Solutions
 
Growth at Xebia
Growth at XebiaGrowth at Xebia
Growth at Xebia
 
A warm and prosperous Happy Diwali to all our clients
A warm and prosperous Happy Diwali to all our clientsA warm and prosperous Happy Diwali to all our clients
A warm and prosperous Happy Diwali to all our clients
 
"We Plan to double our headcount" - MD, Xebia India
"We Plan to double our headcount" - MD, Xebia India"We Plan to double our headcount" - MD, Xebia India
"We Plan to double our headcount" - MD, Xebia India
 
Agile 2.0 - Our Road to Mastery
Agile 2.0 - Our Road to MasteryAgile 2.0 - Our Road to Mastery
Agile 2.0 - Our Road to Mastery
 
Agile FAQs by Shrikant Vashishtha
Agile FAQs by Shrikant VashishthaAgile FAQs by Shrikant Vashishtha
Agile FAQs by Shrikant Vashishtha
 
Agile Team Dynamics by Bhavin Chandulal Javia
Agile Team Dynamics by Bhavin Chandulal JaviaAgile Team Dynamics by Bhavin Chandulal Javia
Agile Team Dynamics by Bhavin Chandulal Javia
 
Practicing Agile in Offshore Environment by Himanshu Seth & Imran Mir
Practicing Agile in Offshore Environment by Himanshu Seth & Imran MirPracticing Agile in Offshore Environment by Himanshu Seth & Imran Mir
Practicing Agile in Offshore Environment by Himanshu Seth & Imran Mir
 
Moving Gradually to Agile Development by Kavita Gupta
Moving Gradually to Agile Development by Kavita GuptaMoving Gradually to Agile Development by Kavita Gupta
Moving Gradually to Agile Development by Kavita Gupta
 
AgileNCR 2010 coverage
AgileNCR 2010 coverageAgileNCR 2010 coverage
AgileNCR 2010 coverage
 
Kanban by Mayur Gupta
Kanban by Mayur GuptaKanban by Mayur Gupta
Kanban by Mayur Gupta
 
Agile vs Waterfall From A Tester's Eyes by Shweta Parashar & Abhishek Agrawal
Agile vs Waterfall From A Tester's Eyes by Shweta Parashar & Abhishek AgrawalAgile vs Waterfall From A Tester's Eyes by Shweta Parashar & Abhishek Agrawal
Agile vs Waterfall From A Tester's Eyes by Shweta Parashar & Abhishek Agrawal
 
What Made Paul A Great Product Owner
What Made Paul A Great Product OwnerWhat Made Paul A Great Product Owner
What Made Paul A Great Product Owner
 
Scaling Agile Hurts by Vibhu Srinivasan
Scaling Agile Hurts by Vibhu SrinivasanScaling Agile Hurts by Vibhu Srinivasan
Scaling Agile Hurts by Vibhu Srinivasan
 
Agile Team Smells : Early Detection and Fixes by Anurag Shrivastava
Agile Team Smells : Early Detection and Fixes by Anurag ShrivastavaAgile Team Smells : Early Detection and Fixes by Anurag Shrivastava
Agile Team Smells : Early Detection and Fixes by Anurag Shrivastava
 

Kürzlich hochgeladen

AWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of TerraformAWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of TerraformAndrey Devyatkin
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityPrincipled Technologies
 
Tech Trends Report 2024 Future Today Institute.pdf
Tech Trends Report 2024 Future Today Institute.pdfTech Trends Report 2024 Future Today Institute.pdf
Tech Trends Report 2024 Future Today Institute.pdfhans926745
 
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 WorkerThousandEyes
 
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 DevelopmentsTrustArc
 
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationSafe Software
 
What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?Antenna Manufacturer Coco
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationRadu Cotescu
 
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 FresherRemote DBA Services
 
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...apidays
 
HTML Injection Attacks: Impact and Mitigation Strategies
HTML Injection Attacks: Impact and Mitigation StrategiesHTML Injection Attacks: Impact and Mitigation Strategies
HTML Injection Attacks: Impact and Mitigation StrategiesBoston Institute of Analytics
 
Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsJoaquim Jorge
 
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...apidays
 
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 2024The Digital Insurer
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Scriptwesley chun
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...Martijn de Jong
 
presentation ICT roal in 21st century education
presentation ICT roal in 21st century educationpresentation ICT roal in 21st century education
presentation ICT roal in 21st century educationjfdjdjcjdnsjd
 
Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024The Digital Insurer
 
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.pdfUK Journal
 

Kürzlich hochgeladen (20)

AWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of TerraformAWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of Terraform
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivity
 
Tech Trends Report 2024 Future Today Institute.pdf
Tech Trends Report 2024 Future Today Institute.pdfTech Trends Report 2024 Future Today Institute.pdf
Tech Trends Report 2024 Future Today Institute.pdf
 
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
 
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
 
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
 
What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organization
 
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
 
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...
 
HTML Injection Attacks: Impact and Mitigation Strategies
HTML Injection Attacks: Impact and Mitigation StrategiesHTML Injection Attacks: Impact and Mitigation Strategies
HTML Injection Attacks: Impact and Mitigation Strategies
 
Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and Myths
 
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...
 
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
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Script
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...
 
presentation ICT roal in 21st century education
presentation ICT roal in 21st century educationpresentation ICT roal in 21st century education
presentation ICT roal in 21st century education
 
Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024
 
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
 

Mobile App Automated Testing

  • 2. SOFTWARE DEVELOPMENT DONE RIGHT Netherlands | USA | India | France | UK www.xebia.in; Blog :http://.xebee.xebia.in
  • 4. Problems • Development and Maintenance • Adaptable to changes • Accuracy • Completeness
  • 5. Automated Testing Desiderata • Use Cases are the Test Cases. • Robust • Realistic Environment (Real Devices, Multiple OS Versions….) • Continuous Integration • Comprehensive Test report for each step. • Flexible Report output formats.
  • 6. • Cucumber Provides o a framework for writing software specifications o a tool for executing those specifications. • Specifications are written DSLs • Works with Ruby, Java, .NET, Flex and many more • http://cukes.info/
  • 8. Step Definition • Make Cucumber Tests come alive. • Written in various Programming Language (mostly Ruby)
  • 9. Calabash • One Interface Cucumber for iOS and Android o Reuse of Test Cross Platform (iOS and Android) • • • • • Targets Native and Hybrid apps for Android and iOS Runs on Physical Device Support for Hybrid Apps (embedded web-views) Open Source Tool Cross Platform Testing
  • 10. Calabash iOS architecture • Calabash tests are executed with the Cucumber tool and consist of two parts: • Client Library written in Ruby • Calabash.framework, a server framework written in Objective-C
  • 11. Calabash iOS • To use Calabash we make a special test target in Xcode that links with calabash.framework • The Server Framework starts HTTP Server inside the App, that listens to the request from Client Library. • The Cucumber tool executes the feature file that represents the intended behaviour of the App Under Test. • The Feature Files contains steps (Predefined or Custom)
  • 12. Calabash Androidarchitecture • Features • Step-Definitions • Instrumentation Test Server: This is another app which will be installed and executed into device.
  • 13. Calabash iOS • App is built for Testing by linking a static library (calabash-server) o Uses a combination of UIAutomation and other APIs • Supports Interactive test-development • Based on Frank but changes some core parts. o Setting up Frank Requires modification of the app source, inclusion of static resources and source files manually, where as Calabash has Automated Set Up. 3 commands and we are done • Touch Synthesis supports multi-touch, gestures • Can use device accessibility for identifying views
  • 14. Queries • • • • Explore the App Interactively Run Command „calabash-ios console‟ It gives us a Calabash console (it is just a Ruby irb with calabash loaded) Example irb(main):001:0> query("button") [0] { }, "class" => "UIButton", "frame" => { "y" => 20, "width" => 101, "x" => 20, "height" => 101 "UIType" => "UIControl", "description" => "<UIButton: 0x4cc1120; frame = (20 20; 101 101); opaque = NO; autoresize = RM+BM; layer = <CALayer: 0x4c89cc0>>" }, Returns an array with objects that are descriptions of the buttons in the current screen in your app
  • 15. Queries • The query function o takes a string query as an argument. o the query argument is similar to a css selector • The syntax for queries is based on UIScript, o but is a new implementation with additional features added (and some removed). • UIScript gives a nice "CSS-selector" like approach to finding view objects in your app screens. irb(main):001:0> query("tabBarButton").count => 4 irb(main):002:0> query("tabBarButton")[0] => {"class"=>"UITabBarButton", "frame"=>{"y"=>1, "width"=>76, "x"=>2, "height"=>48}, "UIType"=>"UIControl", "description"=>"<UITabBarButton: 0x856a820; frame = (2 1; 76 48); opaque = NO; layer = <CALayer: 0x856d210>>" }
  • 17. Prototype gestures • Calabash iOS has a number of built-in event sequences that can be played back. o (touch, swipe, pinch, etc) • Events can be relocated (translated) to different views, and optionally offsets. • Extensible: you can record your own gestures if none of the built in suits you.
  • 18. Summary • Calabash iOS tradeoffs and mitigations DSLs: Cucumber, and Query language (decl, high level) • Full power of Ruby in tests • Advanced touch synthesis o o recordings give some brittleness, which is mitigated by supporting relocating and manipulating of recorded event sequences (which are just lists of dictionaries). • Interactive development experience • Requires linking of a framework • Not good for some games (randomness, “gameplay” & “feel”, timing critical) • Not good for Phone-to-Phone coordination (call, text, bluetooth)
  • 20. References • https://github.com/calabash • https://github.com/calabash/calabash-ios • https://github.com/calabash/calabash-ios/wiki • https://github.com/calabash/calabash-ios-server
  • 21. Agile Testing Current Competencies Mobile Testing: Appium, Calabash Performance Testing Tools: JMeter, LoadUI Automation Frameworks in place - Selenium/Webdriver keyword driven - SoapUI ATDD Tools: Cucumber, Fitnesse, JBehave, Geb Language Proficiencies: Java, Ruby, Groovy, Python Functional automation Tools: Selenium/Webdriver, AUTO IT, SoapUI, QTP Knowledge Sharing: Speakers in national and international conferences
  • 22. Contact us @ Websites www.xebia.in www.xebia.com www.xebia.fr Xebia India infoindia@xebia.com Thought Leadership Htto://xebee.xebia.in http://blog.xebia.com http://podcast.xebia.com

Hinweis der Redaktion

  1. Functional and Acceptance tests• Actual app, as opposed to an isolated component• Often based on use-cases written in natural (domain) language• Visual appearance of app screens matter! (Design guidelines, etc)• As realistic an environment as practically possibleoften a manual process: repetitive, expensive• Many devices, screens, OS versions, languages
  2. Minimal Distance between Use Cases and Test Cases High Level (robust against minor UI changes)Supports Testing in Realistic Environment (Real Devices, Multiple OS Versions….)Supports Continuous IntegrationExecuting a test produces a test report for each step, did it succeed or not exception/error message if presentFlexible Report output formats Machine readable (XML, JSON,...) Human readable, console
  3. Cucumber Providesa framework for writing software specificationsa tool for executing those specifications. Specifications are written in a business readable language (DSL) that is close to natural language.Works with Ruby, Java, .NET, Flex or web applications written in any language. It has been translated to over 40 spoken languages.http://cukes.info/
  4. NarrativeIn order to ‘Conditon’As a RoleI want to ‘Verify’
  5. The Calabash client library makes HTTP requests to the server when it wants to do something with the current viewFeature files. The feature files describe the app use-cases you want to test. They are simultaneously a specification of the behaviour of your app and an executable test suite.