QA Fest 2014. Ярослав Пернеровский. Appium - два в одном. рецепт приготовления коктейля из мобильных автотестов

Q
Appium 2in1
Mobile tests cocktail recipe
Who?
Yaroslav
Pernerovskyy
 Test Automation Lead in
Global Logic
 Trainer in QA Factory
y.pernerovskyy
ypernerovskyy@qafactory.com.ua
www.linkedin.com/pub/yaroslav-pernerovsky/1/9b5/55
What?
Why?
 Web application
 Selenium based test framework (Java)
 iOS and Android clients
 Reuse framework features for mobile
 Open Source (Free of charge)
 Easy setup and configuration
 Scalable and flexible
Appium Rules
 Test the same app you submit to the
marketplace
 Write your tests in any language, using any
framework
 Use a standard automation specification and
API
 Build a large and thriving open-source
community effort
http://appium.io/slate/en/master/?ruby#appium-philosophy
iOS
Android
Firefox OS
Test Script
JSON Wire
protocol
How it works
Native
automation
instruments
Remote Web
Driver
node.js
UiAutomator
Selendroid
Instruments
Marionette
 Native automation instruments
Android: UiAutomator (4.2), Selendroid (2.3)
iOS: UIAutomation
Firefox OS: Marionette
 Emulators/simulators and real devices
 Web Driver API
 Selenium Grid
 Ruby, Python, Java, JavaScript, PHP, C#...
 Documentation
 http://appium.io/
Features
Install
 npm install -g appium
 Appium.dmg
 Appium.exe
 https://bitbucket.org/appium/appium.app/downloads/
Appium GUI
Command line
appium -a 192.168.10.11 -p 4723
--device-name "iPad Simulator" --force-ipad
--orientation LANDSCAPE --pre-launch
--app /products/testapp.app
--nodeconfig /appium/nodeconfig.json
nodeconfig.json
Issues
 Stability issues
 Actions depends on platform
 Problems with accessing some elements
 iOS specific issues
Single app test
Hardware keys support
One emulator instance
xpath issue
Application types
Mobile Browser
Device APIs
Native App
0101010101
0101010101
0101010001
0011110101
0010011100
1010000001
<html>
<body>
<input type="button"
value=" + "
onclick="plus()">
<script
language="JavaScrip
t">
unction plus()
{
rezultat.value=znah_
1.value-(-
1)*znah_2.value;
}
</body>
</html>
Device APIs
Native Container
<html>
<body>
<input type="button"
value=" + "
onclick="plus()">
<script
language="JavaScrip
t">
unction plus()
{
rezultat.value=znah_
1.value
Web apps
 Similar layouts
 Same locators
 Absolutely the same tests can be executed
 Not require additional efforts
Native apps
 Different layout
 Different locators
 Platform specific UI elements
 Test cases should be specially designed
 Require additional efforts
Test environment
SVN
Jenkins
Web Firefox
Web Chrome
Mobile iOS
Mobile Android
……
Selenium
Grid
Chrome, FF
IE
Safari
adb
iPad simulator
iPhone simulator
Nexus 7
Nexus 5
Appiumreports
Selenium
Test framework overview
class Drivers
class Bindings
Page Objects
Page Objects
Page Objects
Page Objects
Tests
Tests
Tests
Tests
Global Configuration
Test data
loggers/db tools/service tools
etc.
Tests
 Test steps should be similar for both platforms
@Test (dataProvider = "Logins")
public void verify_Incorrect_Login(Map<String, String> testData){
loginScreen.verifyScreenLoaded();
loginScreen.submitLogin(testData.get("User"),testData.get("Password"));
loginScreen.verifyAndCloseErrorMessage(testData.get("Message"));
loginScreen.verifyScreenLoaded();
}
Page Objects
 Do not hardcode locators in Page objects
 Store it in external object
 Implement platform specific code
 Create bindings for platform specific actions
Page Object
public class LoginScreen extends Bindings {
public LoginScreen(Instance instance) {
super(instance);
initLocators();
}
private static String LoginScreenUserField;
private static String LoginScreenPasswordField;
private static String LoginScreenSubmitLoginBtn;
private static String LoginScreenErrorMsg;
private static String LoginScreenErrorMsgCloseBtn;
private void initLocators() {
LoginScreenUserField = locators.get("LoginScreenUserField");
LoginScreenPasswordField = locators.get("LoginScreenPasswordField");
LoginScreenSubmitLoginButton = locators.get("LoginScreenSubmitLoginButton");
LoginScreenErrorMsg = locators.get("LoginScreenErrorMsg");
LoginScreenErrorMsgCloseBtn = locators.get("LoginScreenErrorMsgCloseBtn");
}
...
...
Page Object
public void submitLogin(String login, String pass) {
typeKeys(LoginScreenUserField, login);
typeKeys(LoginScreenPasswordField, pass);
tap(LoginScreenSubmitLoginBtn);
}
public void verifyAndCloseErrorMessage(String Message) {
verifyElementPresent(LoginScreenErrorMsg);
assetEqual(getText(LoginScreenErrorMsg),Message);
if (instance.getPlatform().equals("ios"))
tap(LoginScreenErrorMsgCloseBtn);
else
clickBackBtn();
}
Locators
<?xml version='1.0' encoding='UTF-8'?>
<dataset>
<LOCATORNAME="LoginScreenUserField"
ANDROID="id=com.example.myapp:id/txtUser"
IOS="xpath=//window[1]/textfield[1]"/>
<LOCATORNAME="LoginScreenPasswordField"
ANDROID="id=com.example.myapp:id/txtPassword"
IOS="xpath=//window[1]/textfield[2]"/>
<LOCATORNAME="LoginScreenSubmitLoginButton"
ANDROID="name=Login "
IOS="name=Login"/>
<LOCATORNAME="LoginScreenErrorMsg"
ANDROID="id=com.example.myapp:id/errText"
IOS="xpath=//*/UIAPopover[contains(@name,'ErrorText')]"/>
<LOCATORNAME="LoginScreenErrorMsgCloseBtn"
IOS="name=Ok"/>
...
...
Get locators for Android
Get locators for iOS
Summary
 WebDriver concept
 Cross platform
 Open Source
 Easy integration into existed frameworks
 It Works!
 Has issues
 But it works!
 With some additional efforts it is possible to execute
exactly the same tests on different platforms
KEEP
CALM
AND
ASK
QUESTIONS
1 of 26

Recommended

Android Automation Testing with Selendroid by
Android Automation Testing with SelendroidAndroid Automation Testing with Selendroid
Android Automation Testing with SelendroidVikas Thange
4.6K views37 slides
Cross Platform Appium Tests: How To by
Cross Platform Appium Tests: How ToCross Platform Appium Tests: How To
Cross Platform Appium Tests: How ToGlobalLogic Ukraine
2.8K views26 slides
Introduction to Selenium by
Introduction to SeleniumIntroduction to Selenium
Introduction to Seleniumrohitnayak
6.8K views19 slides
Selenium Overview by
Selenium OverviewSelenium Overview
Selenium OverviewAbhijeet Vaikar
339 views25 slides
Appium Meetup #2 - Mobile Web Automation Introduction by
Appium Meetup #2 - Mobile Web Automation IntroductionAppium Meetup #2 - Mobile Web Automation Introduction
Appium Meetup #2 - Mobile Web Automation Introductionsnevesbarros
1.3K views11 slides
ATAGTR2017 Upgrading a mobile tester's weapons with advanced debugging by
ATAGTR2017 Upgrading a mobile tester's weapons with advanced debuggingATAGTR2017 Upgrading a mobile tester's weapons with advanced debugging
ATAGTR2017 Upgrading a mobile tester's weapons with advanced debuggingAgile Testing Alliance
1.4K views42 slides

More Related Content

What's hot

Using Selenium to Test Native Apps (Wait, you can do that?) by
Using Selenium to Test Native Apps (Wait, you can do that?)Using Selenium to Test Native Apps (Wait, you can do that?)
Using Selenium to Test Native Apps (Wait, you can do that?)Sauce Labs
13.6K views65 slides
Android & iOS Automation Using Appium by
Android & iOS Automation Using AppiumAndroid & iOS Automation Using Appium
Android & iOS Automation Using AppiumMindfire Solutions
21.7K views36 slides
Selenium Concepts by
Selenium ConceptsSelenium Concepts
Selenium ConceptsSwati Bansal
13.1K views40 slides
Selenium WebDriver with Java by
Selenium WebDriver with JavaSelenium WebDriver with Java
Selenium WebDriver with JavaFayis-QA
191 views31 slides
Selenium web driver by
Selenium web driverSelenium web driver
Selenium web driverRoman Savitskiy
732 views21 slides
Selenium Webdriver Interview Questions by
Selenium Webdriver Interview QuestionsSelenium Webdriver Interview Questions
Selenium Webdriver Interview QuestionsJai Singh
896 views13 slides

What's hot(20)

Using Selenium to Test Native Apps (Wait, you can do that?) by Sauce Labs
Using Selenium to Test Native Apps (Wait, you can do that?)Using Selenium to Test Native Apps (Wait, you can do that?)
Using Selenium to Test Native Apps (Wait, you can do that?)
Sauce Labs13.6K views
Selenium Concepts by Swati Bansal
Selenium ConceptsSelenium Concepts
Selenium Concepts
Swati Bansal13.1K views
Selenium WebDriver with Java by Fayis-QA
Selenium WebDriver with JavaSelenium WebDriver with Java
Selenium WebDriver with Java
Fayis-QA191 views
Selenium Webdriver Interview Questions by Jai Singh
Selenium Webdriver Interview QuestionsSelenium Webdriver Interview Questions
Selenium Webdriver Interview Questions
Jai Singh896 views
Appium Mobile Test Automation like WebDriver by Andrii Dzynia
Appium Mobile Test Automation like WebDriverAppium Mobile Test Automation like WebDriver
Appium Mobile Test Automation like WebDriver
Andrii Dzynia23.6K views
Web UI test automation instruments by Artem Nagornyi
Web UI test automation instrumentsWeb UI test automation instruments
Web UI test automation instruments
Artem Nagornyi10K views
利用 Appium + Robot Framework 實現跨平台 App 互動測試 by Jeremy Kao
利用 Appium + Robot Framework 實現跨平台 App 互動測試利用 Appium + Robot Framework 實現跨平台 App 互動測試
利用 Appium + Robot Framework 實現跨平台 App 互動測試
Jeremy Kao8.2K views
Selenium by Batch2016
SeleniumSelenium
Selenium
Batch2016438 views
Mobile automation testing with selenium and appium by BugRaptors
Mobile automation testing with selenium and appiumMobile automation testing with selenium and appium
Mobile automation testing with selenium and appium
BugRaptors264 views
iOS Automation Frameworks evaluation by Serghei Moret
iOS Automation Frameworks evaluationiOS Automation Frameworks evaluation
iOS Automation Frameworks evaluation
Serghei Moret1.3K views
Automation testing on ios platform using appium by Ambreen Khan
Automation testing on ios platform using appiumAutomation testing on ios platform using appium
Automation testing on ios platform using appium
Ambreen Khan9K views
Selenium Interview Questions and Answers | Selenium Tutorial | Selenium Train... by Edureka!
Selenium Interview Questions and Answers | Selenium Tutorial | Selenium Train...Selenium Interview Questions and Answers | Selenium Tutorial | Selenium Train...
Selenium Interview Questions and Answers | Selenium Tutorial | Selenium Train...
Edureka!4K views

Viewers also liked

Selenium and Cucumber Selenium Conf 2011 by
Selenium and Cucumber Selenium Conf 2011Selenium and Cucumber Selenium Conf 2011
Selenium and Cucumber Selenium Conf 2011dimakovalenko
2.2K views70 slides
Mobile automation using selenium cucumber & appium by
Mobile automation using selenium cucumber & appiumMobile automation using selenium cucumber & appium
Mobile automation using selenium cucumber & appiumSelenium Cucumber
4.6K views27 slides
QA Fest 2015. Игорь Хрол. Тестировщик в Agile - кто это? by
QA Fest 2015. Игорь Хрол. Тестировщик в Agile - кто это?QA Fest 2015. Игорь Хрол. Тестировщик в Agile - кто это?
QA Fest 2015. Игорь Хрол. Тестировщик в Agile - кто это?QAFest
925 views27 slides
Developing a test automation strategy by Brian Bayer by
Developing a test automation strategy by Brian BayerDeveloping a test automation strategy by Brian Bayer
Developing a test automation strategy by Brian BayerQA or the Highway
1.2K views78 slides
Barcamp Bangkhen :: Robot Framework by
Barcamp Bangkhen :: Robot FrameworkBarcamp Bangkhen :: Robot Framework
Barcamp Bangkhen :: Robot FrameworkSomkiat Puisungnoen
2.4K views24 slides
Robot Framework Introduction & Sauce Labs Integration by
Robot Framework Introduction & Sauce Labs IntegrationRobot Framework Introduction & Sauce Labs Integration
Robot Framework Introduction & Sauce Labs IntegrationSauce Labs
10.9K views19 slides

Viewers also liked(6)

Selenium and Cucumber Selenium Conf 2011 by dimakovalenko
Selenium and Cucumber Selenium Conf 2011Selenium and Cucumber Selenium Conf 2011
Selenium and Cucumber Selenium Conf 2011
dimakovalenko2.2K views
Mobile automation using selenium cucumber & appium by Selenium Cucumber
Mobile automation using selenium cucumber & appiumMobile automation using selenium cucumber & appium
Mobile automation using selenium cucumber & appium
Selenium Cucumber4.6K views
QA Fest 2015. Игорь Хрол. Тестировщик в Agile - кто это? by QAFest
QA Fest 2015. Игорь Хрол. Тестировщик в Agile - кто это?QA Fest 2015. Игорь Хрол. Тестировщик в Agile - кто это?
QA Fest 2015. Игорь Хрол. Тестировщик в Agile - кто это?
QAFest925 views
Developing a test automation strategy by Brian Bayer by QA or the Highway
Developing a test automation strategy by Brian BayerDeveloping a test automation strategy by Brian Bayer
Developing a test automation strategy by Brian Bayer
QA or the Highway1.2K views
Robot Framework Introduction & Sauce Labs Integration by Sauce Labs
Robot Framework Introduction & Sauce Labs IntegrationRobot Framework Introduction & Sauce Labs Integration
Robot Framework Introduction & Sauce Labs Integration
Sauce Labs10.9K views

Similar to QA Fest 2014. Ярослав Пернеровский. Appium - два в одном. рецепт приготовления коктейля из мобильных автотестов

Appium by
AppiumAppium
AppiumDeepshikha Singh
764 views29 slides
Selenium by
SeleniumSelenium
SeleniumSun Technlogies
399 views37 slides
automation framework by
automation frameworkautomation framework
automation frameworkANSHU GOYAL
427 views45 slides
Test automationslides by
Test automationslidesTest automationslides
Test automationslidesUMA MAHESWARI
124 views22 slides
#2 integration + ui tests by
#2 integration + ui tests#2 integration + ui tests
#2 integration + ui testseleksdev
1.6K views20 slides
Android CI and Appium by
Android CI and AppiumAndroid CI and Appium
Android CI and AppiumOren Ashkenazy
801 views22 slides

Similar to QA Fest 2014. Ярослав Пернеровский. Appium - два в одном. рецепт приготовления коктейля из мобильных автотестов(20)

automation framework by ANSHU GOYAL
automation frameworkautomation framework
automation framework
ANSHU GOYAL427 views
#2 integration + ui tests by eleksdev
#2 integration + ui tests#2 integration + ui tests
#2 integration + ui tests
eleksdev1.6K views
Comprehensive List of Open Source QA Tools by Ashish Bansal
Comprehensive List of Open Source QA ToolsComprehensive List of Open Source QA Tools
Comprehensive List of Open Source QA Tools
Ashish Bansal370 views
Automation - web testing with selenium by Tzirla Rozental
Automation - web testing with seleniumAutomation - web testing with selenium
Automation - web testing with selenium
Tzirla Rozental1.2K views
Good practices for debugging Selenium and Appium tests by Abhijeet Vaikar
Good practices for debugging Selenium and Appium testsGood practices for debugging Selenium and Appium tests
Good practices for debugging Selenium and Appium tests
Abhijeet Vaikar233 views
Web UI Tests: Introduce UI tests using Selenium by Peyman Fakharian
Web UI Tests: Introduce UI tests using Selenium Web UI Tests: Introduce UI tests using Selenium
Web UI Tests: Introduce UI tests using Selenium
Peyman Fakharian88 views
Selenium Testing Training in Bangalore by rajkamal560066
Selenium Testing Training in BangaloreSelenium Testing Training in Bangalore
Selenium Testing Training in Bangalore
rajkamal560066290 views
Android UI Testing with Appium by Luke Maung
Android UI Testing with AppiumAndroid UI Testing with Appium
Android UI Testing with Appium
Luke Maung10.9K views
Java Test Automation for REST, Web and Mobile by Elias Nogueira
Java Test Automation for REST, Web and MobileJava Test Automation for REST, Web and Mobile
Java Test Automation for REST, Web and Mobile
Elias Nogueira1.6K views
Shifting landscape of mobile automation, and the future of Appium - Jonathan ... by Applitools
Shifting landscape of mobile automation, and the future of Appium - Jonathan ...Shifting landscape of mobile automation, and the future of Appium - Jonathan ...
Shifting landscape of mobile automation, and the future of Appium - Jonathan ...
Applitools2.1K views
Automated Testing using JavaScript by Simon Guest
Automated Testing using JavaScriptAutomated Testing using JavaScript
Automated Testing using JavaScript
Simon Guest11.9K views

More from QAFest

QA Fest 2019. Сергій Короленко. Топ веб вразливостей за 40 хвилин by
QA Fest 2019. Сергій Короленко. Топ веб вразливостей за 40 хвилинQA Fest 2019. Сергій Короленко. Топ веб вразливостей за 40 хвилин
QA Fest 2019. Сергій Короленко. Топ веб вразливостей за 40 хвилинQAFest
979 views44 slides
QA Fest 2019. Анна Чернышова. Self-healing test automation 2.0. The Future by
QA Fest 2019. Анна Чернышова. Self-healing test automation 2.0. The FutureQA Fest 2019. Анна Чернышова. Self-healing test automation 2.0. The Future
QA Fest 2019. Анна Чернышова. Self-healing test automation 2.0. The FutureQAFest
931 views44 slides
QA Fest 2019. Doug Sillars. It's just too Slow: Testing Mobile application pe... by
QA Fest 2019. Doug Sillars. It's just too Slow: Testing Mobile application pe...QA Fest 2019. Doug Sillars. It's just too Slow: Testing Mobile application pe...
QA Fest 2019. Doug Sillars. It's just too Slow: Testing Mobile application pe...QAFest
322 views131 slides
QA Fest 2019. Катерина Спринсян. Параллельное покрытие автотестами и другие и... by
QA Fest 2019. Катерина Спринсян. Параллельное покрытие автотестами и другие и...QA Fest 2019. Катерина Спринсян. Параллельное покрытие автотестами и другие и...
QA Fest 2019. Катерина Спринсян. Параллельное покрытие автотестами и другие и...QAFest
336 views92 slides
QA Fest 2019. Никита Галкин. Как зарабатывать больше by
QA Fest 2019. Никита Галкин. Как зарабатывать большеQA Fest 2019. Никита Галкин. Как зарабатывать больше
QA Fest 2019. Никита Галкин. Как зарабатывать большеQAFest
389 views40 slides
QA Fest 2019. Сергей Пирогов. Why everything is spoiled by
QA Fest 2019. Сергей Пирогов. Why everything is spoiledQA Fest 2019. Сергей Пирогов. Why everything is spoiled
QA Fest 2019. Сергей Пирогов. Why everything is spoiledQAFest
342 views33 slides

More from QAFest(20)

QA Fest 2019. Сергій Короленко. Топ веб вразливостей за 40 хвилин by QAFest
QA Fest 2019. Сергій Короленко. Топ веб вразливостей за 40 хвилинQA Fest 2019. Сергій Короленко. Топ веб вразливостей за 40 хвилин
QA Fest 2019. Сергій Короленко. Топ веб вразливостей за 40 хвилин
QAFest979 views
QA Fest 2019. Анна Чернышова. Self-healing test automation 2.0. The Future by QAFest
QA Fest 2019. Анна Чернышова. Self-healing test automation 2.0. The FutureQA Fest 2019. Анна Чернышова. Self-healing test automation 2.0. The Future
QA Fest 2019. Анна Чернышова. Self-healing test automation 2.0. The Future
QAFest931 views
QA Fest 2019. Doug Sillars. It's just too Slow: Testing Mobile application pe... by QAFest
QA Fest 2019. Doug Sillars. It's just too Slow: Testing Mobile application pe...QA Fest 2019. Doug Sillars. It's just too Slow: Testing Mobile application pe...
QA Fest 2019. Doug Sillars. It's just too Slow: Testing Mobile application pe...
QAFest322 views
QA Fest 2019. Катерина Спринсян. Параллельное покрытие автотестами и другие и... by QAFest
QA Fest 2019. Катерина Спринсян. Параллельное покрытие автотестами и другие и...QA Fest 2019. Катерина Спринсян. Параллельное покрытие автотестами и другие и...
QA Fest 2019. Катерина Спринсян. Параллельное покрытие автотестами и другие и...
QAFest336 views
QA Fest 2019. Никита Галкин. Как зарабатывать больше by QAFest
QA Fest 2019. Никита Галкин. Как зарабатывать большеQA Fest 2019. Никита Галкин. Как зарабатывать больше
QA Fest 2019. Никита Галкин. Как зарабатывать больше
QAFest389 views
QA Fest 2019. Сергей Пирогов. Why everything is spoiled by QAFest
QA Fest 2019. Сергей Пирогов. Why everything is spoiledQA Fest 2019. Сергей Пирогов. Why everything is spoiled
QA Fest 2019. Сергей Пирогов. Why everything is spoiled
QAFest342 views
QA Fest 2019. Сергей Новик. Между мотивацией и выгоранием by QAFest
QA Fest 2019. Сергей Новик. Между мотивацией и выгораниемQA Fest 2019. Сергей Новик. Между мотивацией и выгоранием
QA Fest 2019. Сергей Новик. Между мотивацией и выгоранием
QAFest249 views
QA Fest 2019. Владимир Никонов. Код Шредингера или зачем и как мы тестируем н... by QAFest
QA Fest 2019. Владимир Никонов. Код Шредингера или зачем и как мы тестируем н...QA Fest 2019. Владимир Никонов. Код Шредингера или зачем и как мы тестируем н...
QA Fest 2019. Владимир Никонов. Код Шредингера или зачем и как мы тестируем н...
QAFest338 views
QA Fest 2019. Владимир Трандафилов. GUI automation of WEB application with SV... by QAFest
QA Fest 2019. Владимир Трандафилов. GUI automation of WEB application with SV...QA Fest 2019. Владимир Трандафилов. GUI automation of WEB application with SV...
QA Fest 2019. Владимир Трандафилов. GUI automation of WEB application with SV...
QAFest227 views
QA Fest 2019. Иван Крутов. Bulletproof Selenium Cluster by QAFest
QA Fest 2019. Иван Крутов. Bulletproof Selenium ClusterQA Fest 2019. Иван Крутов. Bulletproof Selenium Cluster
QA Fest 2019. Иван Крутов. Bulletproof Selenium Cluster
QAFest282 views
QA Fest 2019. Николай Мижигурский. Миссия /*не*/выполнима: гуманитарий собесе... by QAFest
QA Fest 2019. Николай Мижигурский. Миссия /*не*/выполнима: гуманитарий собесе...QA Fest 2019. Николай Мижигурский. Миссия /*не*/выполнима: гуманитарий собесе...
QA Fest 2019. Николай Мижигурский. Миссия /*не*/выполнима: гуманитарий собесе...
QAFest251 views
QA Fest 2019. Володимир Стиран. Чим раніше – тим вигідніше, але ніколи не піз... by QAFest
QA Fest 2019. Володимир Стиран. Чим раніше – тим вигідніше, але ніколи не піз...QA Fest 2019. Володимир Стиран. Чим раніше – тим вигідніше, але ніколи не піз...
QA Fest 2019. Володимир Стиран. Чим раніше – тим вигідніше, але ніколи не піз...
QAFest301 views
QA Fest 2019. Дмитрий Прокопук. Mocks and network tricks in UI automation by QAFest
QA Fest 2019. Дмитрий Прокопук. Mocks and network tricks in UI automationQA Fest 2019. Дмитрий Прокопук. Mocks and network tricks in UI automation
QA Fest 2019. Дмитрий Прокопук. Mocks and network tricks in UI automation
QAFest225 views
QA Fest 2019. Екатерина Дядечко. Тестирование медицинского софта — вызовы и в... by QAFest
QA Fest 2019. Екатерина Дядечко. Тестирование медицинского софта — вызовы и в...QA Fest 2019. Екатерина Дядечко. Тестирование медицинского софта — вызовы и в...
QA Fest 2019. Екатерина Дядечко. Тестирование медицинского софта — вызовы и в...
QAFest243 views
QA Fest 2019. Катерина Черникова. Tune your P’s: the pop-art of keeping testa... by QAFest
QA Fest 2019. Катерина Черникова. Tune your P’s: the pop-art of keeping testa...QA Fest 2019. Катерина Черникова. Tune your P’s: the pop-art of keeping testa...
QA Fest 2019. Катерина Черникова. Tune your P’s: the pop-art of keeping testa...
QAFest376 views
QA Fest 2019. Алиса Бойко. Какнезапутаться в коммуникативных сетях IT by QAFest
QA Fest 2019. Алиса Бойко. Какнезапутаться в коммуникативных сетях ITQA Fest 2019. Алиса Бойко. Какнезапутаться в коммуникативных сетях IT
QA Fest 2019. Алиса Бойко. Какнезапутаться в коммуникативных сетях IT
QAFest209 views
QA Fest 2019. Святослав Логин. Как найти уязвимости в мобильном приложении by QAFest
QA Fest 2019. Святослав Логин. Как найти уязвимости в мобильном приложенииQA Fest 2019. Святослав Логин. Как найти уязвимости в мобильном приложении
QA Fest 2019. Святослав Логин. Как найти уязвимости в мобильном приложении
QAFest607 views
QA Fest 2019. Катерина Шепелєва та Інна Оснач. Що українцям потрібно знати пр... by QAFest
QA Fest 2019. Катерина Шепелєва та Інна Оснач. Що українцям потрібно знати пр...QA Fest 2019. Катерина Шепелєва та Інна Оснач. Що українцям потрібно знати пр...
QA Fest 2019. Катерина Шепелєва та Інна Оснач. Що українцям потрібно знати пр...
QAFest321 views
QA Fest 2019. Антон Серпутько. Нагрузочное тестирование распределенных асинхр... by QAFest
QA Fest 2019. Антон Серпутько. Нагрузочное тестирование распределенных асинхр...QA Fest 2019. Антон Серпутько. Нагрузочное тестирование распределенных асинхр...
QA Fest 2019. Антон Серпутько. Нагрузочное тестирование распределенных асинхр...
QAFest296 views
QA Fest 2019. Петр Тарасенко. QA Hackathon - The Cookbook 22 by QAFest
QA Fest 2019. Петр Тарасенко. QA Hackathon - The Cookbook 22QA Fest 2019. Петр Тарасенко. QA Hackathon - The Cookbook 22
QA Fest 2019. Петр Тарасенко. QA Hackathon - The Cookbook 22
QAFest164 views

Recently uploaded

ICS3211_lecture 08_2023.pdf by
ICS3211_lecture 08_2023.pdfICS3211_lecture 08_2023.pdf
ICS3211_lecture 08_2023.pdfVanessa Camilleri
231 views30 slides
Computer Introduction-Lecture06 by
Computer Introduction-Lecture06Computer Introduction-Lecture06
Computer Introduction-Lecture06Dr. Mazin Mohamed alkathiri
105 views12 slides
REPRESENTATION - GAUNTLET.pptx by
REPRESENTATION - GAUNTLET.pptxREPRESENTATION - GAUNTLET.pptx
REPRESENTATION - GAUNTLET.pptxiammrhaywood
138 views26 slides
Java Simplified: Understanding Programming Basics by
Java Simplified: Understanding Programming BasicsJava Simplified: Understanding Programming Basics
Java Simplified: Understanding Programming BasicsAkshaj Vadakkath Joshy
322 views155 slides
MIXING OF PHARMACEUTICALS.pptx by
MIXING OF PHARMACEUTICALS.pptxMIXING OF PHARMACEUTICALS.pptx
MIXING OF PHARMACEUTICALS.pptxAnupkumar Sharma
95 views35 slides
ICS3211_lecture 09_2023.pdf by
ICS3211_lecture 09_2023.pdfICS3211_lecture 09_2023.pdf
ICS3211_lecture 09_2023.pdfVanessa Camilleri
115 views10 slides

Recently uploaded(20)

REPRESENTATION - GAUNTLET.pptx by iammrhaywood
REPRESENTATION - GAUNTLET.pptxREPRESENTATION - GAUNTLET.pptx
REPRESENTATION - GAUNTLET.pptx
iammrhaywood138 views
Pharmaceutical Inorganic chemistry UNIT-V Radiopharmaceutical.pptx by Ms. Pooja Bhandare
Pharmaceutical Inorganic chemistry UNIT-V Radiopharmaceutical.pptxPharmaceutical Inorganic chemistry UNIT-V Radiopharmaceutical.pptx
Pharmaceutical Inorganic chemistry UNIT-V Radiopharmaceutical.pptx
Ms. Pooja Bhandare113 views
CUNY IT Picciano.pptx by apicciano
CUNY IT Picciano.pptxCUNY IT Picciano.pptx
CUNY IT Picciano.pptx
apicciano54 views
The Accursed House by Émile Gaboriau by DivyaSheta
The Accursed House  by Émile GaboriauThe Accursed House  by Émile Gaboriau
The Accursed House by Émile Gaboriau
DivyaSheta223 views
Classification of crude drugs.pptx by GayatriPatra14
Classification of crude drugs.pptxClassification of crude drugs.pptx
Classification of crude drugs.pptx
GayatriPatra14101 views
How to empty an One2many field in Odoo by Celine George
How to empty an One2many field in OdooHow to empty an One2many field in Odoo
How to empty an One2many field in Odoo
Celine George87 views
Ch. 7 Political Participation and Elections.pptx by Rommel Regala
Ch. 7 Political Participation and Elections.pptxCh. 7 Political Participation and Elections.pptx
Ch. 7 Political Participation and Elections.pptx
Rommel Regala111 views
Solar System and Galaxies.pptx by DrHafizKosar
Solar System and Galaxies.pptxSolar System and Galaxies.pptx
Solar System and Galaxies.pptx
DrHafizKosar106 views
Sociology KS5 by WestHatch
Sociology KS5Sociology KS5
Sociology KS5
WestHatch85 views
Pharmaceutical Inorganic Chemistry Unit IVMiscellaneous compounds Expectorant... by Ms. Pooja Bhandare
Pharmaceutical Inorganic Chemistry Unit IVMiscellaneous compounds Expectorant...Pharmaceutical Inorganic Chemistry Unit IVMiscellaneous compounds Expectorant...
Pharmaceutical Inorganic Chemistry Unit IVMiscellaneous compounds Expectorant...
Ms. Pooja Bhandare133 views
Create a Structure in VBNet.pptx by Breach_P
Create a Structure in VBNet.pptxCreate a Structure in VBNet.pptx
Create a Structure in VBNet.pptx
Breach_P78 views
When Sex Gets Complicated: Porn, Affairs, & Cybersex by Marlene Maheu
When Sex Gets Complicated: Porn, Affairs, & CybersexWhen Sex Gets Complicated: Porn, Affairs, & Cybersex
When Sex Gets Complicated: Porn, Affairs, & Cybersex
Marlene Maheu85 views

QA Fest 2014. Ярослав Пернеровский. Appium - два в одном. рецепт приготовления коктейля из мобильных автотестов

  • 1. Appium 2in1 Mobile tests cocktail recipe
  • 2. Who? Yaroslav Pernerovskyy  Test Automation Lead in Global Logic  Trainer in QA Factory y.pernerovskyy ypernerovskyy@qafactory.com.ua www.linkedin.com/pub/yaroslav-pernerovsky/1/9b5/55
  • 4. Why?  Web application  Selenium based test framework (Java)  iOS and Android clients  Reuse framework features for mobile  Open Source (Free of charge)  Easy setup and configuration  Scalable and flexible
  • 5. Appium Rules  Test the same app you submit to the marketplace  Write your tests in any language, using any framework  Use a standard automation specification and API  Build a large and thriving open-source community effort http://appium.io/slate/en/master/?ruby#appium-philosophy
  • 6. iOS Android Firefox OS Test Script JSON Wire protocol How it works Native automation instruments Remote Web Driver node.js UiAutomator Selendroid Instruments Marionette
  • 7.  Native automation instruments Android: UiAutomator (4.2), Selendroid (2.3) iOS: UIAutomation Firefox OS: Marionette  Emulators/simulators and real devices  Web Driver API  Selenium Grid  Ruby, Python, Java, JavaScript, PHP, C#...  Documentation  http://appium.io/ Features
  • 8. Install  npm install -g appium  Appium.dmg  Appium.exe  https://bitbucket.org/appium/appium.app/downloads/
  • 10. Command line appium -a 192.168.10.11 -p 4723 --device-name "iPad Simulator" --force-ipad --orientation LANDSCAPE --pre-launch --app /products/testapp.app --nodeconfig /appium/nodeconfig.json
  • 12. Issues  Stability issues  Actions depends on platform  Problems with accessing some elements  iOS specific issues Single app test Hardware keys support One emulator instance xpath issue
  • 13. Application types Mobile Browser Device APIs Native App 0101010101 0101010101 0101010001 0011110101 0010011100 1010000001 <html> <body> <input type="button" value=" + " onclick="plus()"> <script language="JavaScrip t"> unction plus() { rezultat.value=znah_ 1.value-(- 1)*znah_2.value; } </body> </html> Device APIs Native Container <html> <body> <input type="button" value=" + " onclick="plus()"> <script language="JavaScrip t"> unction plus() { rezultat.value=znah_ 1.value
  • 14. Web apps  Similar layouts  Same locators  Absolutely the same tests can be executed  Not require additional efforts
  • 15. Native apps  Different layout  Different locators  Platform specific UI elements  Test cases should be specially designed  Require additional efforts
  • 16. Test environment SVN Jenkins Web Firefox Web Chrome Mobile iOS Mobile Android …… Selenium Grid Chrome, FF IE Safari adb iPad simulator iPhone simulator Nexus 7 Nexus 5 Appiumreports
  • 17. Selenium Test framework overview class Drivers class Bindings Page Objects Page Objects Page Objects Page Objects Tests Tests Tests Tests Global Configuration Test data loggers/db tools/service tools etc.
  • 18. Tests  Test steps should be similar for both platforms @Test (dataProvider = "Logins") public void verify_Incorrect_Login(Map<String, String> testData){ loginScreen.verifyScreenLoaded(); loginScreen.submitLogin(testData.get("User"),testData.get("Password")); loginScreen.verifyAndCloseErrorMessage(testData.get("Message")); loginScreen.verifyScreenLoaded(); }
  • 19. Page Objects  Do not hardcode locators in Page objects  Store it in external object  Implement platform specific code  Create bindings for platform specific actions
  • 20. Page Object public class LoginScreen extends Bindings { public LoginScreen(Instance instance) { super(instance); initLocators(); } private static String LoginScreenUserField; private static String LoginScreenPasswordField; private static String LoginScreenSubmitLoginBtn; private static String LoginScreenErrorMsg; private static String LoginScreenErrorMsgCloseBtn; private void initLocators() { LoginScreenUserField = locators.get("LoginScreenUserField"); LoginScreenPasswordField = locators.get("LoginScreenPasswordField"); LoginScreenSubmitLoginButton = locators.get("LoginScreenSubmitLoginButton"); LoginScreenErrorMsg = locators.get("LoginScreenErrorMsg"); LoginScreenErrorMsgCloseBtn = locators.get("LoginScreenErrorMsgCloseBtn"); } ... ...
  • 21. Page Object public void submitLogin(String login, String pass) { typeKeys(LoginScreenUserField, login); typeKeys(LoginScreenPasswordField, pass); tap(LoginScreenSubmitLoginBtn); } public void verifyAndCloseErrorMessage(String Message) { verifyElementPresent(LoginScreenErrorMsg); assetEqual(getText(LoginScreenErrorMsg),Message); if (instance.getPlatform().equals("ios")) tap(LoginScreenErrorMsgCloseBtn); else clickBackBtn(); }
  • 23. Get locators for Android
  • 25. Summary  WebDriver concept  Cross platform  Open Source  Easy integration into existed frameworks  It Works!  Has issues  But it works!  With some additional efforts it is possible to execute exactly the same tests on different platforms

Editor's Notes

  1. 1 year with appium Issues add Add slide real and emulators and limitations. Appium + hardware controls
  2. Hardware keys iOS only one etc
  3. (grid/tablewiew etc.)