SlideShare a Scribd company logo
1 of 13
Download to read offline
XCTest
UITesting in Xcode
ABOUT ME
Sergeev Maxim
QA engineer of 2nd category
@raincoven
raincoven@gmail.com
msergeev@thumbtack.net
2
BRIEFLY ABOUT XCTEST UI
• UI Automation framework by Apple
• Blackbox
• Swift 2.* / ObjectiveC
• iOS9 / Xcode 7 / OS X 10.11
3
FEATURES
• Designed by Apple for Apple
developers
• Test recording
• Test run reports
• Really simple syntax
• Fast test scenario development
4
LET’S START
• open your project in Xcode
• add new testing target
• …
• PROFIT!
5
GENERATED STRUCTURE
6
GENERATED CODE
7
import XCTest
class ListerUITests: XCTestCase {
override func setUp() {
super.setUp()
continueAfterFailure = false
XCUIApplication().launch()
}
override func tearDown() {
super.tearDown()
}
func testExample() {
// Use recording to get started writing UI tests.
}
}
LETS RECORD SOMETEST
8
DISADVANTAGES
• Sometimes selector for element may be very complex
• No page object
• One trait testing
• No documentation
• Only latest iOS version
• Requires separate target
9
SHOULD I USE IT ON MY
PROJECT?
10
LINKS
app: https://developer.apple.com/sample-code/swift/
downloads/Start-Dev-iOS-Apps-10.zip
ClassReferences: http://kumarsc.github.io/index.html
Cheat Sheet: http://masilotti.com/ui-testing-cheat-sheet/
WWDC Presentation: https://developer.apple.com/
videos/play/wwdc2015-406/
11
QUESTIONS?
12
THANKS FOR ATTENTION!
13

More Related Content

What's hot

UI Testing with Earl Grey
UI Testing with Earl GreyUI Testing with Earl Grey
UI Testing with Earl GreyShyam Bhat
 
Make XCUITest Great Again
Make XCUITest Great AgainMake XCUITest Great Again
Make XCUITest Great AgainKenneth Poon
 
XCUITest Introduction: Test Automation University
XCUITest Introduction: Test Automation University XCUITest Introduction: Test Automation University
XCUITest Introduction: Test Automation University Shashikant Jagtap
 
Robotium framework & Jenkins CI tools - TdT@Cluj #19
Robotium framework & Jenkins CI tools - TdT@Cluj #19Robotium framework & Jenkins CI tools - TdT@Cluj #19
Robotium framework & Jenkins CI tools - TdT@Cluj #19Tabăra de Testare
 
[XCode] Automating UI Testing
[XCode] Automating UI Testing[XCode] Automating UI Testing
[XCode] Automating UI TestingPhineas Huang
 
Beginning iPhone Development
Beginning iPhone DevelopmentBeginning iPhone Development
Beginning iPhone Developmentsgleadow
 
Developing Java SWT Applications - A Starter
Developing Java SWT Applications - A StarterDeveloping Java SWT Applications - A Starter
Developing Java SWT Applications - A Startervcaselli
 
Android Building, Testing and reversing
Android Building, Testing and reversingAndroid Building, Testing and reversing
Android Building, Testing and reversingEnrique López Mañas
 
Custom cell in objective c
Custom cell in objective cCustom cell in objective c
Custom cell in objective cVishal Verma
 
Robotium at Android Only 2010-09-29
Robotium at Android Only 2010-09-29Robotium at Android Only 2010-09-29
Robotium at Android Only 2010-09-29Hugo Josefson
 
SwtBot: Unit Testing Made Easy
SwtBot: Unit Testing Made EasySwtBot: Unit Testing Made Easy
SwtBot: Unit Testing Made EasyAnkit Goel
 
Seven Versions of One Web Application
Seven Versions of One Web ApplicationSeven Versions of One Web Application
Seven Versions of One Web ApplicationYakov Fain
 
Testing the User Interface - Coded UI Tests with Visual Studio 2010
Testing the User Interface - Coded UI Tests with Visual Studio 2010Testing the User Interface - Coded UI Tests with Visual Studio 2010
Testing the User Interface - Coded UI Tests with Visual Studio 2010Eric D. Boyd
 
Functional Testing made easy with SWTBot for Developers and Testers
Functional Testing made easy with SWTBot for Developers and TestersFunctional Testing made easy with SWTBot for Developers and Testers
Functional Testing made easy with SWTBot for Developers and TestersAurélien Pupier
 
WinAppDriver - Windows Store Apps Test Automation
WinAppDriver - Windows Store Apps Test AutomationWinAppDriver - Windows Store Apps Test Automation
WinAppDriver - Windows Store Apps Test AutomationJeremy Kao
 
How to configure Appium with android IDE & eclipse
How to configure Appium with android IDE & eclipseHow to configure Appium with android IDE & eclipse
How to configure Appium with android IDE & eclipseHaitham Refaat
 

What's hot (20)

UI Testing with Earl Grey
UI Testing with Earl GreyUI Testing with Earl Grey
UI Testing with Earl Grey
 
Make XCUITest Great Again
Make XCUITest Great AgainMake XCUITest Great Again
Make XCUITest Great Again
 
XCUITest Introduction: Test Automation University
XCUITest Introduction: Test Automation University XCUITest Introduction: Test Automation University
XCUITest Introduction: Test Automation University
 
Robotium framework & Jenkins CI tools - TdT@Cluj #19
Robotium framework & Jenkins CI tools - TdT@Cluj #19Robotium framework & Jenkins CI tools - TdT@Cluj #19
Robotium framework & Jenkins CI tools - TdT@Cluj #19
 
[XCode] Automating UI Testing
[XCode] Automating UI Testing[XCode] Automating UI Testing
[XCode] Automating UI Testing
 
Beginning iPhone Development
Beginning iPhone DevelopmentBeginning iPhone Development
Beginning iPhone Development
 
Developing Java SWT Applications - A Starter
Developing Java SWT Applications - A StarterDeveloping Java SWT Applications - A Starter
Developing Java SWT Applications - A Starter
 
Robotium Tutorial
Robotium TutorialRobotium Tutorial
Robotium Tutorial
 
Android Building, Testing and reversing
Android Building, Testing and reversingAndroid Building, Testing and reversing
Android Building, Testing and reversing
 
Custom cell in objective c
Custom cell in objective cCustom cell in objective c
Custom cell in objective c
 
Robotium at Android Only 2010-09-29
Robotium at Android Only 2010-09-29Robotium at Android Only 2010-09-29
Robotium at Android Only 2010-09-29
 
SwtBot: Unit Testing Made Easy
SwtBot: Unit Testing Made EasySwtBot: Unit Testing Made Easy
SwtBot: Unit Testing Made Easy
 
SWTBot Tutorial
SWTBot TutorialSWTBot Tutorial
SWTBot Tutorial
 
Seven Versions of One Web Application
Seven Versions of One Web ApplicationSeven Versions of One Web Application
Seven Versions of One Web Application
 
Swtbot
SwtbotSwtbot
Swtbot
 
Testing the User Interface - Coded UI Tests with Visual Studio 2010
Testing the User Interface - Coded UI Tests with Visual Studio 2010Testing the User Interface - Coded UI Tests with Visual Studio 2010
Testing the User Interface - Coded UI Tests with Visual Studio 2010
 
Functional Testing made easy with SWTBot for Developers and Testers
Functional Testing made easy with SWTBot for Developers and TestersFunctional Testing made easy with SWTBot for Developers and Testers
Functional Testing made easy with SWTBot for Developers and Testers
 
WinAppDriver - Windows Store Apps Test Automation
WinAppDriver - Windows Store Apps Test AutomationWinAppDriver - Windows Store Apps Test Automation
WinAppDriver - Windows Store Apps Test Automation
 
How to configure Appium with android IDE & eclipse
How to configure Appium with android IDE & eclipseHow to configure Appium with android IDE & eclipse
How to configure Appium with android IDE & eclipse
 
Android Test Automation Workshop
Android Test Automation WorkshopAndroid Test Automation Workshop
Android Test Automation Workshop
 

Similar to  xctest

What's new in testing with Xcode.pdf
What's new in testing with Xcode.pdfWhat's new in testing with Xcode.pdf
What's new in testing with Xcode.pdfssuser5a6d90
 
Xcode Server & Xcode 7 Bots
Xcode Server & Xcode 7 Bots Xcode Server & Xcode 7 Bots
Xcode Server & Xcode 7 Bots Steven Forbes
 
JavaFX - Sketch Board to Production
JavaFX - Sketch Board to ProductionJavaFX - Sketch Board to Production
JavaFX - Sketch Board to ProductionYoav Aharoni
 
Integration tests: use the containers, Luke!
Integration tests: use the containers, Luke!Integration tests: use the containers, Luke!
Integration tests: use the containers, Luke!Roberto Franchini
 
CocoaConf DC - Automate with Swift - Tony Ingraldi
CocoaConf DC -  Automate with Swift - Tony IngraldiCocoaConf DC -  Automate with Swift - Tony Ingraldi
CocoaConf DC - Automate with Swift - Tony IngraldiTony Ingraldi
 
Xamarin UI Test And Xamarin Test Cloud
Xamarin UI Test And Xamarin Test CloudXamarin UI Test And Xamarin Test Cloud
Xamarin UI Test And Xamarin Test CloudEmanuel Amiguinho
 
Using Jenkins with iOS projects
Using Jenkins with iOS projectsUsing Jenkins with iOS projects
Using Jenkins with iOS projectsAppsDojo
 
UI Testing Automation - Alex Kalinovsky - CreamTec LLC
UI Testing Automation - Alex Kalinovsky - CreamTec LLCUI Testing Automation - Alex Kalinovsky - CreamTec LLC
UI Testing Automation - Alex Kalinovsky - CreamTec LLCJim Lane
 
Intro to React Native
Intro to React NativeIntro to React Native
Intro to React NativeForSharing
 
Qt test framework
Qt test frameworkQt test framework
Qt test frameworkICS
 
1 java fundamental KSHRD
1   java fundamental KSHRD1   java fundamental KSHRD
1 java fundamental KSHRDTola Meng
 
JavaScript TDD with Jasmine and Karma
JavaScript TDD with Jasmine and KarmaJavaScript TDD with Jasmine and Karma
JavaScript TDD with Jasmine and KarmaChristopher Bartling
 
Open source and cross platform .net
Open source and cross platform .netOpen source and cross platform .net
Open source and cross platform .netIbon Landa
 
Android Meetup Slovenija #3 - Testing with Robolectric by Ivan Kust
Android Meetup Slovenija #3 - Testing with Robolectric by Ivan KustAndroid Meetup Slovenija #3 - Testing with Robolectric by Ivan Kust
Android Meetup Slovenija #3 - Testing with Robolectric by Ivan KustInfinum
 
みゆっき☆Think#4 「こんどはiPhoneに触ってみるよ!」
みゆっき☆Think#4 「こんどはiPhoneに触ってみるよ!」みゆっき☆Think#4 「こんどはiPhoneに触ってみるよ!」
みゆっき☆Think#4 「こんどはiPhoneに触ってみるよ!」techtalkdwango
 

Similar to  xctest (20)

What's new in testing with Xcode.pdf
What's new in testing with Xcode.pdfWhat's new in testing with Xcode.pdf
What's new in testing with Xcode.pdf
 
Xcode Server & Xcode 7 Bots
Xcode Server & Xcode 7 Bots Xcode Server & Xcode 7 Bots
Xcode Server & Xcode 7 Bots
 
JavaFX - Sketch Board to Production
JavaFX - Sketch Board to ProductionJavaFX - Sketch Board to Production
JavaFX - Sketch Board to Production
 
Integration tests: use the containers, Luke!
Integration tests: use the containers, Luke!Integration tests: use the containers, Luke!
Integration tests: use the containers, Luke!
 
CocoaConf DC - Automate with Swift - Tony Ingraldi
CocoaConf DC -  Automate with Swift - Tony IngraldiCocoaConf DC -  Automate with Swift - Tony Ingraldi
CocoaConf DC - Automate with Swift - Tony Ingraldi
 
Xamarin UI Test And Xamarin Test Cloud
Xamarin UI Test And Xamarin Test CloudXamarin UI Test And Xamarin Test Cloud
Xamarin UI Test And Xamarin Test Cloud
 
Agile Swift
Agile SwiftAgile Swift
Agile Swift
 
Using Jenkins with iOS projects
Using Jenkins with iOS projectsUsing Jenkins with iOS projects
Using Jenkins with iOS projects
 
UI Testing Automation - Alex Kalinovsky - CreamTec LLC
UI Testing Automation - Alex Kalinovsky - CreamTec LLCUI Testing Automation - Alex Kalinovsky - CreamTec LLC
UI Testing Automation - Alex Kalinovsky - CreamTec LLC
 
Intro to React Native
Intro to React NativeIntro to React Native
Intro to React Native
 
september13.ppt
september13.pptseptember13.ppt
september13.ppt
 
Qt test framework
Qt test frameworkQt test framework
Qt test framework
 
1 java fundamental KSHRD
1   java fundamental KSHRD1   java fundamental KSHRD
1 java fundamental KSHRD
 
JavaScript TDD with Jasmine and Karma
JavaScript TDD with Jasmine and KarmaJavaScript TDD with Jasmine and Karma
JavaScript TDD with Jasmine and Karma
 
Open source and cross platform .net
Open source and cross platform .netOpen source and cross platform .net
Open source and cross platform .net
 
Android Meetup Slovenija #3 - Testing with Robolectric by Ivan Kust
Android Meetup Slovenija #3 - Testing with Robolectric by Ivan KustAndroid Meetup Slovenija #3 - Testing with Robolectric by Ivan Kust
Android Meetup Slovenija #3 - Testing with Robolectric by Ivan Kust
 
UI testing in Xcode 7
UI testing in Xcode 7UI testing in Xcode 7
UI testing in Xcode 7
 
20110709 - CM_Cocoa
20110709 - CM_Cocoa20110709 - CM_Cocoa
20110709 - CM_Cocoa
 
Snug 6 Maart 2009
Snug 6 Maart 2009Snug 6 Maart 2009
Snug 6 Maart 2009
 
みゆっき☆Think#4 「こんどはiPhoneに触ってみるよ!」
みゆっき☆Think#4 「こんどはiPhoneに触ってみるよ!」みゆっき☆Think#4 「こんどはiPhoneに触ってみるよ!」
みゆっき☆Think#4 「こんどはiPhoneに触ってみるよ!」
 

 xctest