Trust Your Pipeline: Automatically Testing an End-to-End Java Application Bruno Souza | @brjavaman Elias Nogueira | @eliasnogueira
Different Test Levels Unit Tests Component Tests Integration Test API Test Web Mobile UI Static Analysis Code coverage Stubs Mocks Services UI Tests Visual Regression Test Test Pyramid – Focus on Automated Testing
Different Test Levels Test Pyramid – Focus on Automated Testing Unit Tests Component Tests Integration Test API Test Web Mobile UI Machines for web execution Devices for mobile executions Servers ”mid” tests
Continuous Delivery Development QAOperations DevOps Automated Build and DeployAutomated Provisioning Continuous Feedback Automated Testing
Strategy focus on a Test Pipeline UNIT TEST INTEGRATION TEST SERVICE TEST ACCEPTANCE TEST FUNCTIONAL TEST MOCK SMOKE WEB MOBILE NON FUNCTIONAL TESTS SCREENSHOTS – LOGS – REPORT – DATA MANAGEMENT - PARAMETERIZED PARALLEL EXECUTION SMOKE CONTRACT FUNCTIONAL ACCEPTANCE
REST ASSURED + JAVA SPARK (mock) REST SELENIUM WEBDRIVER WEB APPIUM with EMULATOR MOBILE REST ASSURED for test an REST endpoint SELENIUM WEBDRIVER for a Web Test (functional and acceptance) APPIUM for Mobile Test (functional and acceptance) Tool box Tools for think about test out-of-the-box
Now it’s time to see the tools in action Example
REST Assured RestAssured test example Sending a GET with id 1 (given) and the assert the response/results (then) Easy DSL to automating REST services that’s use Given-When-Then syntax https://github.com/jayway/rest-assured
Selenium WebDriver Easy DSL to automating REST services that’s use Given-When-Then syntax https://seleniumhq.org Selenium automated testing example Complete example with navigation, localization, manipulation and synchronization
Appium Tool for automated testing on native Android, iOS or Hybrid mobile apps https://appium.io Example with a pre-installed app Complete example targeting an Android platform
Applied Pipeline We gonna show this magic! SERVICE TEST ACCEPTANCE TEST FUNCTIONAL TEST MOCK WEB MOBILE SMOKE FUNCTIONAL
Thank you https://github.com/eliasnogueira/ test-automation-javaone-2017 http://code4.life

Trust Your Pipeline - Automatically Testing and End-to-End Java Application

  • 1.
    Trust Your Pipeline: AutomaticallyTesting an End-to-End Java Application Bruno Souza | @brjavaman Elias Nogueira | @eliasnogueira
  • 2.
    Different Test Levels UnitTests Component Tests Integration Test API Test Web Mobile UI Static Analysis Code coverage Stubs Mocks Services UI Tests Visual Regression Test Test Pyramid – Focus on Automated Testing
  • 4.
    Different Test Levels TestPyramid – Focus on Automated Testing Unit Tests Component Tests Integration Test API Test Web Mobile UI Machines for web execution Devices for mobile executions Servers ”mid” tests
  • 5.
    Continuous Delivery Development QAOperations DevOps Automated Build andDeployAutomated Provisioning Continuous Feedback Automated Testing
  • 6.
    Strategy focus ona Test Pipeline UNIT TEST INTEGRATION TEST SERVICE TEST ACCEPTANCE TEST FUNCTIONAL TEST MOCK SMOKE WEB MOBILE NON FUNCTIONAL TESTS SCREENSHOTS – LOGS – REPORT – DATA MANAGEMENT - PARAMETERIZED PARALLEL EXECUTION SMOKE CONTRACT FUNCTIONAL ACCEPTANCE
  • 7.
    REST ASSURED + JAVA SPARK(mock) REST SELENIUM WEBDRIVER WEB APPIUM with EMULATOR MOBILE REST ASSURED for test an REST endpoint SELENIUM WEBDRIVER for a Web Test (functional and acceptance) APPIUM for Mobile Test (functional and acceptance) Tool box Tools for think about test out-of-the-box
  • 8.
    Now it’s timeto see the tools in action Example
  • 9.
    REST Assured RestAssured testexample Sending a GET with id 1 (given) and the assert the response/results (then) Easy DSL to automating REST services that’s use Given-When-Then syntax https://github.com/jayway/rest-assured
  • 10.
    Selenium WebDriver Easy DSLto automating REST services that’s use Given-When-Then syntax https://seleniumhq.org Selenium automated testing example Complete example with navigation, localization, manipulation and synchronization
  • 11.
    Appium Tool for automatedtesting on native Android, iOS or Hybrid mobile apps https://appium.io Example with a pre-installed app Complete example targeting an Android platform
  • 12.
    Applied Pipeline We gonnashow this magic! SERVICE TEST ACCEPTANCE TEST FUNCTIONAL TEST MOCK WEB MOBILE SMOKE FUNCTIONAL
  • 13.