SlideShare a Scribd company logo
1 of 16
Maxim Naidenov, SAP
July 20, 2018
Reliable application
tests for UI5 applications
Web Page vs Web App
How we test Web Apps today
Technical level
 Unit tests for separate components
 E2E tests that involve backend
Organizational level
 E2E Test are created and operated by
a QA team
What is the problem ?
 Catches defects late
 Reporting is hard
 Local reproduction is hard
 Retesting is slow
 Keeping tests consistent is hard
 Covering new features is hard
 Covering fixes is unlikely
INEFFICIENT
How should web apps be tested ?
 Move UI tests in the app
development cycle
 Ask developers to write them
 Execute frequently
 Catches regressions very
early
 Reporting is automatic
 Reproduction is very easy
 Tests are consistent by design
 Very easy to cover new
features and fixes
What is preventing us from doing it ?
 UI tests are written in a
different language than than
the web app
 UI tests require external tools
and complicated local setup
 UI tests are hard to debug
 UI tests are unstable, frequent
false positives
How to fix it ?
 Write tests in JavaScript
 Make the UI tests run
completely in browser
 Debug tests in the browser
dev tools
 Make UI tests inherently
stable by automatic
synchronization with the UI
framework
Application Testing with OPA
Testing framework for UI5 based applications
UI5 based
application
Fully browser-based,
NO selenium
HTTP
Server
OPA script
Application testing
Developer centric
Mocked backend
MockServer
OPA – launching the test
Bootstrap UI5 and QUnit
Start the execution
Load the test site
Plain HTML
OPA – test suite
The test suite loads the
test cases
Global OPA configuration
OPA – test case
Loading Page Objects
We use BDD-line syntax
opaTest() is a wrapper
for Qunit.test()
Opa starts and stops the
the application
Test looks synchronous
Semantical actions and
assertions
OPA – page objects
Work with controls, not
the DOM
OPA helper for creating
Page Objects
waitFor() is the basic
building block
Report will contain nice
error messages
This is the stable ID from
the XML template
OPA – autoWaiter
 Wait for all XHR requests to complete
 Wait for all promises to be resolved
 Wait for all timeouts to be completed
 Application pollings are not a problem
 Wait for UI5 rendering to be completed
 Wait for UI5 NavContainer, OverflowToolbar, etc
specific behavior
One good OPA test
Limitations
 Same domain policy means that both test and
app should be deployed on the same origin, not
suitable for productive systems
 In-browser operation mean that authentications
and browser redirects are not possible
 OPA is a developer friendly but requires both
JavaScript and UI5 proficiency to use effectively
Thank you.
Contact information:
Maxim Naidenov
maxim.naidenov@sap.com

More Related Content

What's hot

Smart : Comprehensive and unified framework for test automation of web and mo...
Smart : Comprehensive and unified framework for test automation of web and mo...Smart : Comprehensive and unified framework for test automation of web and mo...
Smart : Comprehensive and unified framework for test automation of web and mo...
Anmol Bagga
 
Testing Design System Changes Across Your Application -- Intuit Use Case -- w...
Testing Design System Changes Across Your Application -- Intuit Use Case -- w...Testing Design System Changes Across Your Application -- Intuit Use Case -- w...
Testing Design System Changes Across Your Application -- Intuit Use Case -- w...
Applitools
 
Mdc2010 Automated Mobile Testing
Mdc2010 Automated Mobile TestingMdc2010 Automated Mobile Testing
Mdc2010 Automated Mobile Testing
momobangalore
 

What's hot (20)

Smart : Comprehensive and unified framework for test automation of web and mo...
Smart : Comprehensive and unified framework for test automation of web and mo...Smart : Comprehensive and unified framework for test automation of web and mo...
Smart : Comprehensive and unified framework for test automation of web and mo...
 
API Integration For Building Software Applications Powerpoint Presentation Sl...
API Integration For Building Software Applications Powerpoint Presentation Sl...API Integration For Building Software Applications Powerpoint Presentation Sl...
API Integration For Building Software Applications Powerpoint Presentation Sl...
 
[webinar] Best of Breed: Successful Test Automation Practices from Innovative...
[webinar] Best of Breed: Successful Test Automation Practices from Innovative...[webinar] Best of Breed: Successful Test Automation Practices from Innovative...
[webinar] Best of Breed: Successful Test Automation Practices from Innovative...
 
Test automationatrakutentravel
Test automationatrakutentravelTest automationatrakutentravel
Test automationatrakutentravel
 
Real Testing Scenario Strategy Practical TestOps Presentation
Real Testing Scenario Strategy Practical TestOps PresentationReal Testing Scenario Strategy Practical TestOps Presentation
Real Testing Scenario Strategy Practical TestOps Presentation
 
Introduction to APIs & how to automate APIs testing with selenium web driver?
Introduction to APIs & how to automate APIs testing with selenium web driver?Introduction to APIs & how to automate APIs testing with selenium web driver?
Introduction to APIs & how to automate APIs testing with selenium web driver?
 
Test Automation Frameworks: Assumptions, Concepts & Tools
Test Automation Frameworks: Assumptions, Concepts & ToolsTest Automation Frameworks: Assumptions, Concepts & Tools
Test Automation Frameworks: Assumptions, Concepts & Tools
 
Web Accessibility Testing Trends and Shift Left Testing of accessibility usin...
Web Accessibility Testing Trends and Shift Left Testing of accessibility usin...Web Accessibility Testing Trends and Shift Left Testing of accessibility usin...
Web Accessibility Testing Trends and Shift Left Testing of accessibility usin...
 
Appium vs Espresso and XCUI Test
Appium vs Espresso and XCUI TestAppium vs Espresso and XCUI Test
Appium vs Espresso and XCUI Test
 
Make the Shift from Manual to Automation with Open Source
Make the Shift from Manual to Automation with Open SourceMake the Shift from Manual to Automation with Open Source
Make the Shift from Manual to Automation with Open Source
 
What Can The Spira API Do For You?
 What Can The Spira API Do For You? What Can The Spira API Do For You?
What Can The Spira API Do For You?
 
Roman iovlev battle - JDI vs Selenide - Selenium Camp
Roman iovlev battle - JDI vs Selenide - Selenium CampRoman iovlev battle - JDI vs Selenide - Selenium Camp
Roman iovlev battle - JDI vs Selenide - Selenium Camp
 
Testing Design System Changes Across Your Application -- Intuit Use Case -- w...
Testing Design System Changes Across Your Application -- Intuit Use Case -- w...Testing Design System Changes Across Your Application -- Intuit Use Case -- w...
Testing Design System Changes Across Your Application -- Intuit Use Case -- w...
 
Selenium test automation framework design & development
Selenium test automation framework design & developmentSelenium test automation framework design & development
Selenium test automation framework design & development
 
Test automation within a scrum process
Test automation within a scrum processTest automation within a scrum process
Test automation within a scrum process
 
Mdc2010 Automated Mobile Testing
Mdc2010 Automated Mobile TestingMdc2010 Automated Mobile Testing
Mdc2010 Automated Mobile Testing
 
Building Resilient Automated UI Tests for Cloud Applications using Scripless ...
Building Resilient Automated UI Tests for Cloud Applications using Scripless ...Building Resilient Automated UI Tests for Cloud Applications using Scripless ...
Building Resilient Automated UI Tests for Cloud Applications using Scripless ...
 
Setup and run automated test framework for android application
Setup and run automated test framework for android applicationSetup and run automated test framework for android application
Setup and run automated test framework for android application
 
Start Your Automation Journey With Rapise
Start Your Automation Journey With Rapise Start Your Automation Journey With Rapise
Start Your Automation Journey With Rapise
 
Cross Platform Mobile Test Automation using Selenium WebDriver by Perfecto Mo...
Cross Platform Mobile Test Automation using Selenium WebDriver by Perfecto Mo...Cross Platform Mobile Test Automation using Selenium WebDriver by Perfecto Mo...
Cross Platform Mobile Test Automation using Selenium WebDriver by Perfecto Mo...
 

Similar to Reliable application tests for ui5 apps

Stepin evening presented
Stepin evening presentedStepin evening presented
Stepin evening presented
Vijayan Reddy
 
Automated Testing Of EPiServer CMS Sites
Automated Testing Of EPiServer CMS SitesAutomated Testing Of EPiServer CMS Sites
Automated Testing Of EPiServer CMS Sites
joelabrahamsson
 

Similar to Reliable application tests for ui5 apps (20)

Антон Семенченко | (EPAM Systems, DPI.Solutions )Сравнительный анализ инстру...
Антон Семенченко | (EPAM Systems, DPI.Solutions )Сравнительный анализ инстру...Антон Семенченко | (EPAM Systems, DPI.Solutions )Сравнительный анализ инстру...
Антон Семенченко | (EPAM Systems, DPI.Solutions )Сравнительный анализ инстру...
 
E2E testing with UIVeri5
E2E testing with UIVeri5E2E testing with UIVeri5
E2E testing with UIVeri5
 
International journal of applied sciences and innovation vol 2015 - no 1 - ...
International journal of applied sciences and innovation   vol 2015 - no 1 - ...International journal of applied sciences and innovation   vol 2015 - no 1 - ...
International journal of applied sciences and innovation vol 2015 - no 1 - ...
 
Appium Interview Questions and Answers | Edureka
Appium Interview Questions and Answers | EdurekaAppium Interview Questions and Answers | Edureka
Appium Interview Questions and Answers | Edureka
 
What is Selenium Introduction to Selenium Testing.pptx
What is Selenium Introduction to Selenium Testing.pptxWhat is Selenium Introduction to Selenium Testing.pptx
What is Selenium Introduction to Selenium Testing.pptx
 
Stepin evening presented
Stepin evening presentedStepin evening presented
Stepin evening presented
 
Mobitop
MobitopMobitop
Mobitop
 
Mobitop
MobitopMobitop
Mobitop
 
Mobitop
MobitopMobitop
Mobitop
 
Mobitop
MobitopMobitop
Mobitop
 
Automated Testing using JavaScript
Automated Testing using JavaScriptAutomated Testing using JavaScript
Automated Testing using JavaScript
 
Automated Testing Of EPiServer CMS Sites
Automated Testing Of EPiServer CMS SitesAutomated Testing Of EPiServer CMS Sites
Automated Testing Of EPiServer CMS Sites
 
iOS Automation Frameworks evaluation
iOS Automation Frameworks evaluationiOS Automation Frameworks evaluation
iOS Automation Frameworks evaluation
 
Automation testing
Automation testingAutomation testing
Automation testing
 
Webservicex.pdf
Webservicex.pdfWebservicex.pdf
Webservicex.pdf
 
ATAGTR2017 Appium
ATAGTR2017 AppiumATAGTR2017 Appium
ATAGTR2017 Appium
 
Mobile App Quality Roadmap for DevTest Teams
Mobile App Quality Roadmap for DevTest TeamsMobile App Quality Roadmap for DevTest Teams
Mobile App Quality Roadmap for DevTest Teams
 
Testing of React JS app
Testing of React JS appTesting of React JS app
Testing of React JS app
 
Top 20 best automation testing tools
Top 20 best automation testing toolsTop 20 best automation testing tools
Top 20 best automation testing tools
 
Web Testing
Web TestingWeb Testing
Web Testing
 

Recently uploaded

Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...
Christo Ananth
 
UNIT-V FMM.HYDRAULIC TURBINE - Construction and working
UNIT-V FMM.HYDRAULIC TURBINE - Construction and workingUNIT-V FMM.HYDRAULIC TURBINE - Construction and working
UNIT-V FMM.HYDRAULIC TURBINE - Construction and working
rknatarajan
 
AKTU Computer Networks notes --- Unit 3.pdf
AKTU Computer Networks notes ---  Unit 3.pdfAKTU Computer Networks notes ---  Unit 3.pdf
AKTU Computer Networks notes --- Unit 3.pdf
ankushspencer015
 
Call Now ≽ 9953056974 ≼🔝 Call Girls In New Ashok Nagar ≼🔝 Delhi door step de...
Call Now ≽ 9953056974 ≼🔝 Call Girls In New Ashok Nagar  ≼🔝 Delhi door step de...Call Now ≽ 9953056974 ≼🔝 Call Girls In New Ashok Nagar  ≼🔝 Delhi door step de...
Call Now ≽ 9953056974 ≼🔝 Call Girls In New Ashok Nagar ≼🔝 Delhi door step de...
9953056974 Low Rate Call Girls In Saket, Delhi NCR
 
Call Girls in Ramesh Nagar Delhi 💯 Call Us 🔝9953056974 🔝 Escort Service
Call Girls in Ramesh Nagar Delhi 💯 Call Us 🔝9953056974 🔝 Escort ServiceCall Girls in Ramesh Nagar Delhi 💯 Call Us 🔝9953056974 🔝 Escort Service
Call Girls in Ramesh Nagar Delhi 💯 Call Us 🔝9953056974 🔝 Escort Service
9953056974 Low Rate Call Girls In Saket, Delhi NCR
 

Recently uploaded (20)

(INDIRA) Call Girl Meerut Call Now 8617697112 Meerut Escorts 24x7
(INDIRA) Call Girl Meerut Call Now 8617697112 Meerut Escorts 24x7(INDIRA) Call Girl Meerut Call Now 8617697112 Meerut Escorts 24x7
(INDIRA) Call Girl Meerut Call Now 8617697112 Meerut Escorts 24x7
 
KubeKraft presentation @CloudNativeHooghly
KubeKraft presentation @CloudNativeHooghlyKubeKraft presentation @CloudNativeHooghly
KubeKraft presentation @CloudNativeHooghly
 
Top Rated Pune Call Girls Budhwar Peth ⟟ 6297143586 ⟟ Call Me For Genuine Se...
Top Rated  Pune Call Girls Budhwar Peth ⟟ 6297143586 ⟟ Call Me For Genuine Se...Top Rated  Pune Call Girls Budhwar Peth ⟟ 6297143586 ⟟ Call Me For Genuine Se...
Top Rated Pune Call Girls Budhwar Peth ⟟ 6297143586 ⟟ Call Me For Genuine Se...
 
CCS335 _ Neural Networks and Deep Learning Laboratory_Lab Complete Record
CCS335 _ Neural Networks and Deep Learning Laboratory_Lab Complete RecordCCS335 _ Neural Networks and Deep Learning Laboratory_Lab Complete Record
CCS335 _ Neural Networks and Deep Learning Laboratory_Lab Complete Record
 
University management System project report..pdf
University management System project report..pdfUniversity management System project report..pdf
University management System project report..pdf
 
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...
 
UNIT - IV - Air Compressors and its Performance
UNIT - IV - Air Compressors and its PerformanceUNIT - IV - Air Compressors and its Performance
UNIT - IV - Air Compressors and its Performance
 
Thermal Engineering-R & A / C - unit - V
Thermal Engineering-R & A / C - unit - VThermal Engineering-R & A / C - unit - V
Thermal Engineering-R & A / C - unit - V
 
Double rodded leveling 1 pdf activity 01
Double rodded leveling 1 pdf activity 01Double rodded leveling 1 pdf activity 01
Double rodded leveling 1 pdf activity 01
 
UNIT-V FMM.HYDRAULIC TURBINE - Construction and working
UNIT-V FMM.HYDRAULIC TURBINE - Construction and workingUNIT-V FMM.HYDRAULIC TURBINE - Construction and working
UNIT-V FMM.HYDRAULIC TURBINE - Construction and working
 
The Most Attractive Pune Call Girls Manchar 8250192130 Will You Miss This Cha...
The Most Attractive Pune Call Girls Manchar 8250192130 Will You Miss This Cha...The Most Attractive Pune Call Girls Manchar 8250192130 Will You Miss This Cha...
The Most Attractive Pune Call Girls Manchar 8250192130 Will You Miss This Cha...
 
Booking open Available Pune Call Girls Koregaon Park 6297143586 Call Hot Ind...
Booking open Available Pune Call Girls Koregaon Park  6297143586 Call Hot Ind...Booking open Available Pune Call Girls Koregaon Park  6297143586 Call Hot Ind...
Booking open Available Pune Call Girls Koregaon Park 6297143586 Call Hot Ind...
 
(INDIRA) Call Girl Bhosari Call Now 8617697112 Bhosari Escorts 24x7
(INDIRA) Call Girl Bhosari Call Now 8617697112 Bhosari Escorts 24x7(INDIRA) Call Girl Bhosari Call Now 8617697112 Bhosari Escorts 24x7
(INDIRA) Call Girl Bhosari Call Now 8617697112 Bhosari Escorts 24x7
 
AKTU Computer Networks notes --- Unit 3.pdf
AKTU Computer Networks notes ---  Unit 3.pdfAKTU Computer Networks notes ---  Unit 3.pdf
AKTU Computer Networks notes --- Unit 3.pdf
 
ONLINE FOOD ORDER SYSTEM PROJECT REPORT.pdf
ONLINE FOOD ORDER SYSTEM PROJECT REPORT.pdfONLINE FOOD ORDER SYSTEM PROJECT REPORT.pdf
ONLINE FOOD ORDER SYSTEM PROJECT REPORT.pdf
 
Call Girls Pimpri Chinchwad Call Me 7737669865 Budget Friendly No Advance Boo...
Call Girls Pimpri Chinchwad Call Me 7737669865 Budget Friendly No Advance Boo...Call Girls Pimpri Chinchwad Call Me 7737669865 Budget Friendly No Advance Boo...
Call Girls Pimpri Chinchwad Call Me 7737669865 Budget Friendly No Advance Boo...
 
UNIT-III FMM. DIMENSIONAL ANALYSIS
UNIT-III FMM.        DIMENSIONAL ANALYSISUNIT-III FMM.        DIMENSIONAL ANALYSIS
UNIT-III FMM. DIMENSIONAL ANALYSIS
 
Thermal Engineering -unit - III & IV.ppt
Thermal Engineering -unit - III & IV.pptThermal Engineering -unit - III & IV.ppt
Thermal Engineering -unit - III & IV.ppt
 
Call Now ≽ 9953056974 ≼🔝 Call Girls In New Ashok Nagar ≼🔝 Delhi door step de...
Call Now ≽ 9953056974 ≼🔝 Call Girls In New Ashok Nagar  ≼🔝 Delhi door step de...Call Now ≽ 9953056974 ≼🔝 Call Girls In New Ashok Nagar  ≼🔝 Delhi door step de...
Call Now ≽ 9953056974 ≼🔝 Call Girls In New Ashok Nagar ≼🔝 Delhi door step de...
 
Call Girls in Ramesh Nagar Delhi 💯 Call Us 🔝9953056974 🔝 Escort Service
Call Girls in Ramesh Nagar Delhi 💯 Call Us 🔝9953056974 🔝 Escort ServiceCall Girls in Ramesh Nagar Delhi 💯 Call Us 🔝9953056974 🔝 Escort Service
Call Girls in Ramesh Nagar Delhi 💯 Call Us 🔝9953056974 🔝 Escort Service
 

Reliable application tests for ui5 apps

  • 1. Maxim Naidenov, SAP July 20, 2018 Reliable application tests for UI5 applications
  • 2. Web Page vs Web App
  • 3. How we test Web Apps today Technical level  Unit tests for separate components  E2E tests that involve backend Organizational level  E2E Test are created and operated by a QA team
  • 4. What is the problem ?  Catches defects late  Reporting is hard  Local reproduction is hard  Retesting is slow  Keeping tests consistent is hard  Covering new features is hard  Covering fixes is unlikely INEFFICIENT
  • 5. How should web apps be tested ?  Move UI tests in the app development cycle  Ask developers to write them  Execute frequently  Catches regressions very early  Reporting is automatic  Reproduction is very easy  Tests are consistent by design  Very easy to cover new features and fixes
  • 6. What is preventing us from doing it ?  UI tests are written in a different language than than the web app  UI tests require external tools and complicated local setup  UI tests are hard to debug  UI tests are unstable, frequent false positives
  • 7. How to fix it ?  Write tests in JavaScript  Make the UI tests run completely in browser  Debug tests in the browser dev tools  Make UI tests inherently stable by automatic synchronization with the UI framework
  • 8. Application Testing with OPA Testing framework for UI5 based applications UI5 based application Fully browser-based, NO selenium HTTP Server OPA script Application testing Developer centric Mocked backend MockServer
  • 9. OPA – launching the test Bootstrap UI5 and QUnit Start the execution Load the test site Plain HTML
  • 10. OPA – test suite The test suite loads the test cases Global OPA configuration
  • 11. OPA – test case Loading Page Objects We use BDD-line syntax opaTest() is a wrapper for Qunit.test() Opa starts and stops the the application Test looks synchronous Semantical actions and assertions
  • 12. OPA – page objects Work with controls, not the DOM OPA helper for creating Page Objects waitFor() is the basic building block Report will contain nice error messages This is the stable ID from the XML template
  • 13. OPA – autoWaiter  Wait for all XHR requests to complete  Wait for all promises to be resolved  Wait for all timeouts to be completed  Application pollings are not a problem  Wait for UI5 rendering to be completed  Wait for UI5 NavContainer, OverflowToolbar, etc specific behavior
  • 14. One good OPA test
  • 15. Limitations  Same domain policy means that both test and app should be deployed on the same origin, not suitable for productive systems  In-browser operation mean that authentications and browser redirects are not possible  OPA is a developer friendly but requires both JavaScript and UI5 proficiency to use effectively
  • 16. Thank you. Contact information: Maxim Naidenov maxim.naidenov@sap.com

Editor's Notes

  1. Web applications are browser-based javascript applications, frequently built with advanced frameworks like UI5, Angular, React. Web applications bring many benefits to the overall user experience but also provide serious challenges, particularly for automated testing. This reminder is important as most of the automated tools we use today are designed for automating the testing of web pages and not web applications. And particularly, the tools are depending on the interactions being mapped to HTTP communication because that is how the web has initially designed. But the web has changed and this mapping is no longer valid. The de-factor standard tool for automated browser UI testing is Selenium. There are numerous selenium-based frameworks that strive to optimize some aspect of selenium. There are also commercial tools line QTP. All those tools have a basic deficiency – they work on a low level and treat the application as a web page. And this is causing their major issues with reliability of the automated tests. So it is time to evolve the testing tools and start testing the web apps and not the container web page.
  2. Lets look how we test today Unit tests Rare Qunit for UI5, Jasmin for Angular E2E or integration testing selenium, sikuli, commercial tools QA team owns the tests QA team operates the tests and reports issue How to have a better quality – usuallty boils down to write more automated tests
  3. Long Feedback Cycle Process is hard - less likely to be followed under the pressure Test quality deuterates over time and UI tests become a burden and not an asset.
  4. Shorten the feedback cycle use application tests as part of test-driven development - the test is a formal specification write the test together with the code and commit them together
  5. Those problems are so common that many teams consider automated UI test as impractical and avoid them. So what is left is to live with manual UI regression testing. Manual testing is NOT feasible for regression testing because it is slow and does not scale - could not be executed after each commit. Remove the obstacles and provide value to developer No single open-source UI testing framework so we at SAP UI5 team had to build it ourselves.
  6. Testing framework for UI5 based applications – intended for UI testing of UI5 applications, no application tweaking is required Fully browser-based, NO selenium – not based on Selenium, does not require any external deployments, only browser and http server to bootstrap the test and the app. Application testing – Application testing in this context means UI testing of single web application with mocked backend. We provide support for ODATA backend mocking with integrated mocking support – MockServer Developer centric – OPA is developer centric because uses inside knowledge of the application to speedup the test creation. Simple test execution and debugging. Reliable by design – Reliability is a challenge, especially for UI tests. Common experience is that UI test are flaky and require special experts or whole teams to write and support them. With OPA, we are challenging the perception. Due to the integration with UI5 core, the OPA test is inherently reliable.
  7. Opa test is just one html page – open it in the browser and execute it. It will show the progress, you will see the test opening the app and clicking around, at the end you will see the report. Same applies for automation – use any Qunit runner.