test autom ation and test autom ation and keyw ord driven
play

Test Autom ation and Test Autom ation and Keyw ord-driven testing - PowerPoint PPT Presentation

Test Autom ation and Test Autom ation and Keyw ord-driven testing Brian Nielsen, bnielsen@cs.aau.dk 3 Script Based Testing 3. Script-Based Testing + / - test impl. = programming + automatic execution + auto regression testing + auto


  1. Test Autom ation and Test Autom ation and Keyw ord-driven testing Brian Nielsen, bnielsen@cs.aau.dk

  2. 3 Script Based Testing 3. Script-Based Testing + / - test impl. = programming + automatic execution + auto regression testing + auto regression testing fragile tests break easily? (depends on abstraction) (depends on abstraction) - ad-hoc coverage - no coverage measurement

  3. 4 Keyword Driven Testing 4. Keyword-Driven Testing + abstract tests + automatic execution + auto regression testing + auto regression testing - robust tests - ad-hoc coverage ad hoc coverage - no coverage measurement

  4. Script based Testing Script-based Testing Test inputs and observations (verdict assignment) programmed in scripts in g ) p p g dedicated or general-purpose languages. + Repeatable (for regression testing) + Repeatable (for regression testing) + Data driven testing: Fixed scripts, each parameterized with different data d e e da a – Mixes test harness and logical test cases – Must be updated when specs (or impl) change Must be updated when specs (or impl) change – Very lengthy – Good programmers may write well-structured Good programmers may write well structured reusable test code but ”it is just test code”

  5. Keyword Driven Testing y g • Script based automation where test case d design is separated from automation i i t d f t ti – Focus on actions user/environment can do on objects in SUT (at different abstraction levels) • ”Actions” appear in scripts, pp p • ”Action-code” implements the action • aka “Action-word” testing (or table driven • aka Action-word testing (or, table driven testing), < 1994 • Black-box, subsystem, accept tests • Automated execution using a “framework”. Automated execution using a framework .

  6. Keyword Driven Testing y g + Concise, flexible, maintainable, + Read-/writeable by non-programmers ÷ Expressiveness of a scripting language – Control structures and complex computations C t l t t d l t ti – (Branching in test cases, complex data, matching of expected results)

  7. Keyword Driven Test y Eg. Sequence Object Keyword Value LoginDialog Login ”badUserId”, ”GoodPass” VerifyLogin VerifyLogin ”Login failed” Login failed LoginDialog Login ”goodUserId”, ”badPass” VerifyLogin ”Login failed” LoginDialog Login ”goodUserId”, ”GoodPass” VerifyLogin ”welcome” WelcomeDialog W l Di l changeLogin h L i ” ”newUserName”,”newpwd” U N ” ” d” confirm ”goodUserId”, ”newpwd” confirmChange ”Change Failed”

  8. KWD Process Automation Expert Test Expert http: / / www.softwaretestinghelp.com/ wp-content/ qa/ uploads/ 2010/ 01/ keyword-driven-testing.pdf

  9. Automation Fixture Automation Fixture Keywod Script Keywod Script Open(Scripts) While(!EOF){ Keyword, data=readFile(); Engine/driver Generic Libs Case(keyword){ (fixtures) (fixtures) L Login: widget->submit(data); i id t > b it(d t ) verifyLogin: … Application Libs } (keyword functions) Close() SUT }

  10. Tools • SAFS, open source • EMOS Framework, open source • FIT/FitNesse open source • FIT/FitNesse, open source • Certify, Worksoft • Unified TestPro, SDT • TestFrame LogicaCMG • TestFrame, LogicaCMG • TestArchitect, LogiGear • Tools with built-in keyword support: – TestQuest Pro, TestQuest Pro – QuickTest Professional

  11. Example Example http: / / localhost: 8080/ FitBookExamples.Chapter4TestingActions.Fig6TestChatServer

  12. http: / / fit.c2.com/ wiki.cgi?FitBook http: / / my.safaribooksonline.com/ 0321269349

  13. Comparison p Manual Script KWD Model-Based Criteria Cost Cost Development Development L L M M M M L L Maintenance H? H L Tools/equip q p L M M H Time Time to first test L M M M-H Re-execution H L L L Maintenance L H H L Learn- Skills L H M* H* ability ability Maturity L M M-H H Readability L L M H* I t Interest / Challenging t / Ch ll i L L M M M M H H Effective- Bug detection H L L H ness Tracability Tracability L L L L M M H H Coverage L L M H

  14. References References • http://en.wikipedia.org/wiki/Keyword-driven_testing • http://www.cs.waikato.ac.nz/~marku/mbt/ • http://www.onestoptesting.com/automation- framework/keyword-driven-testing/ • http://www.softwaretestinghelp.com/wp- content/qa/uploads/2010/01/keyword-driven-testing.pdf • http://www.musala.com/press/PR_2008_03_17/pr/Keyw ord-driven%20Testing.pdf d d i %20T ti df • Mark Fewster and Dorothy Graham, Software Test Automation 1999 (Chapter 22) Automation, 1999 (Chapter 22) • M. Utting Practical Model-based testing

Download Presentation
Download Policy: The content available on the website is offered to you 'AS IS' for your personal information and use only. It cannot be commercialized, licensed, or distributed on other websites without prior consent from the author. To download a presentation, simply click this link. If you encounter any difficulties during the download process, it's possible that the publisher has removed the file from their server.

Recommend


More recommend