Test automation - Building effective solutions

1,667 views
1,502 views

Published on

This presentation is answering the questions: how to build an effective test automation framework, select the right tools and organize to whole process?

Published in: Technology
0 Comments
2 Likes
Statistics
Notes
  • Be the first to comment

No Downloads
Views
Total views
1,667
On SlideShare
0
From Embeds
0
Number of Embeds
16
Actions
Shares
0
Downloads
48
Comments
0
Likes
2
Embeds 0
No embeds

No notes for slide

Test automation - Building effective solutions

  1. 1. Test AutomationBuilding effective solutionsby Artem Nagornyi
  2. 2. select the right toolIn order to understand whether a test automation tool wasselected properly, you should begin with answering a fewquestions:● Is your tool compatible with the application environment, technologies, and interfaces?● What is the cost of your chosen test automation tool?● How easy it is to write, execute, and maintain test scripts?● Is it possible to extend the tool with additional components?● How fast can a person learn the scripting language used by the tool?● Is your vendor ready to resolve tool-related issues? Is the community support strong enough?● How reliable is your test automation tool?
  3. 3. building theframeworkData-driven type of framework with page objects. Site Class "Page A" Class "Page B" Class "Page C" Class Tests Helpers Driver
  4. 4. select test cases forautomationHow do we select test cases for automation? "Automatethem all" is hardly an answer if you are focused on qualityand efficiency.You should automate a manual test case only when:● Your test case is executed frequently enough, and takes time to run manually. Especially this is actual for large regression test suites.● You have a test that will run with different sets of data.● Your test case needs to be run under many different platforms and system configurations.
  5. 5. select test cases forautomationOn the other hand, test automation is not recommended inthe following cases:● Usability testing.● When the functionality of the application changes frequently.● When the expenditures on test automation tools and the support of already existing tests are too high.● When test automation doesnt provide enough advantages if compared to manual testing.
  6. 6. test automationlifecycle
  7. 7. sharing theresponsibilities ● TA Engineers● QA Engineers Test ● Developers Manual Test Automation Cases Framework Development Automated Execution Test Scripts and Results Development Analysis● QA Engineers ● TA Engineers● TA Engineers ● QA Engineers
  8. 8. what is seleniumwebdriver?● Open-source, multi-platform, multi-browser tool for browser-based Web UI automation that is de facto standard in the world of Web UI test automation.
  9. 9. what is seleniumwebdriver?All browsers, all versions are equallysupported.Once written, test script in most cases will workfor all browsers without modifications.
  10. 10. what is seleniumwebdriver?Test scripts can be developed in anyprogramming language of your preference.
  11. 11. what is seleniumwebdriver?Many frameworks are supported:● JUnit● NUnit● TestNG● unittest● RSpec● Test::Unit● Bromine● Robot● FitNesse... and others.
  12. 12. what is seleniumwebdriver?Has the biggest and strongest communityamong all open-source test automation tools.
  13. 13. what is seleniumwebdriver?Example of Selenium WebDriver script: WebDriver driver = new FirefoxDriver(); // Go to the Google Suggest home page driver.get("http://www.google.com/webhp?complete=1&hl=en"); // Enter the query string "Cheese" WebElement query = driver.findElement(By.name("q")); query.sendKeys("Cheese");
  14. 14. what is sikuli?● Open-source, multi-platform visual technology to automate graphical user interfaces using images of objects on the screen and OCR.
  15. 15. what is sikuli?Virtually any application interface and platformcan be automated. The only requirement isJava.
  16. 16. what is sikuli?Test scripts can be developed either in Jythonor Java.
  17. 17. what is sikuli?Images of elements can be captured in SikuliIDE.
  18. 18. what is sikuli?Example test script in Sikuli: #Start program calcApp = App("Calculator") if not calcApp.window(): App.open("calc.exe"); wait(2) calcApp.focus(); wait(1) #Verify that the window appeared if exists("CalcApp.png"): print("PASS: Calculator window appeared") else: print("FAIL: No calculator window") click("2.png"); click("plus.png"); click("3.png") #Verify the addition result find("5.png")
  19. 19. what is testng?TestNG is a testing framework inspired from JUnit andNUnit but introducing some new functionalities that make itmore powerful and easier to use, such as:● Annotations.● Flexible test configuration.● Support for data-driven testing.● Support for parameters.● Powerful execution model.● Supported by a variety of tools and plug-ins (Eclipse, IDEA, Maven, etc...).
  20. 20. what is apache ant?Software tool for automating software build processes.It can be used for preparing environment, compilation andexecution of test scripts if they are developed in Java.
  21. 21. what is jenkins?Open-source continuous integration server with 300+plugins to support all kinds of software development.It can be used to make test automation processes moresolid by:● Updating tests from source control repository before execution.● Scheduling test execution.● Keeping test results and history.
  22. 22. demoTest automation framework that is built upon the followingtools: ● Selenium WebDriver ● Sikuli ● TestNG ● Apache Ant ● Jenkins
  23. 23. questions?

×