1 / 34

Automated Testing Tool for UML Behavioral Descriptions

Automated Testing Tool for UML Behavioral Descriptions. M.Tech. Project. Guided by:. Presented by:. Venkat. Prof. S.Ramesh. Prof. Sridhar Iyer. Outline of the Talk. Overview of the Software Testing Literature Survey Stress on Statecharts Importance of Testing Statecharts

fell
Télécharger la présentation

Automated Testing Tool for UML Behavioral Descriptions

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Automated Testing Tool for UML Behavioral Descriptions M.Tech. Project Guided by: Presented by: Venkat Prof. S.Ramesh Prof. Sridhar Iyer

  2. Outline of the Talk • Overview of the Software Testing • Literature Survey • Stress on Statecharts • Importance of Testing Statecharts • Coverage Metrics • Design Specification of StateTest Tool • Conclusions • Demo M.Tech Project Presentation By Guntapudi V R, SIT, IIT BOMBAY

  3. Testing Fundamentals • Testing Objectives • Test Information Flow M.Tech Project Presentation By Guntapudi V R, SIT, IIT BOMBAY

  4. Test Information Flow M.Tech Project Presentation By Guntapudi V R, SIT, IIT BOMBAY

  5. Test Case Design • Three elements • Test specification • Test requirements • Clues • Fault Conditions • Reachability • Necessity • Propagation M.Tech Project Presentation By Guntapudi V R, SIT, IIT BOMBAY

  6. An Example void Check_square(int do_square,double x) { double y = x; if(do_square) y = x + x; printf(“squared value larger? %d\n”,y > x); } The fault is that + was used when * should have been M.Tech Project Presentation By Guntapudi V R, SIT, IIT BOMBAY

  7. Reachability (do_square is true) Necessity (x!=2 && x!=0) Propagation (x <=1) (to differentiate the truth value between (x+x >x) and (x*x>x)) Fault Conditions M.Tech Project Presentation By Guntapudi V R, SIT, IIT BOMBAY

  8. Testing Techniques • White-Box Testing • Basis path testing • Deriving Test cases • Flow graph • Cyclomatic Complexity • Finding independent paths • Graph Matrices • Control Structure Testing • Condition testing • Data flow testing • Loop testing M.Tech Project Presentation By Guntapudi V R, SIT, IIT BOMBAY

  9. Testing Techniques • Black-Box Testing • Equivalence Partitioning • (Range,specific value)one valid, two invalid inputs • (Boolean,member of a set)one valid, one invalid inputs • Boundary Value Analysis(BVA) • Ex: (1). If 0<a<5, then test with (-1, 0, 1) and (4, 5, 6) • Ex: (2). If the i/p has n values, then test with i/p s (n-1), (n), and (n+1) values • Comparison Testing • Specially for Safety-critical systems M.Tech Project Presentation By Guntapudi V R, SIT, IIT BOMBAY

  10. Testing Strategies • Unit Testing • To test the modules • Integration Testing • To test interfaces between modules • Top-down • Could be DFS / BFS followed • Bottom-up • Regression Testing • Validation Testing • Validation test criteria • Configuration review • Alpha and Beta testing • System Testing • Recovery • Security • Stress • Performance M.Tech Project Presentation By Guntapudi V R, SIT, IIT BOMBAY

  11. Spiral Model of S/W Testing M.Tech Project Presentation By Guntapudi V R, SIT, IIT BOMBAY

  12. Literature Survey • AdaTest and Cantata • For State Machine Testing • IPL Algo. For Coverage Metrics • Property-Based Testing • Suggests the Testing at Source code level, rather than at higher level • TASPEC is the Central entity • ATTOL Software • ATTOL UnitTest, ATTOL SystemTset, ATTOL Coverage • +1 Software Testing Tool • +1Base, +1CR, +1CM, +1DataTree, +1Test, +1Reports, +1Reuse M.Tech Project Presentation By Guntapudi V R, SIT, IIT BOMBAY

  13. A Brief Look At UML • Result of the Three OO methodologies • Booch Method by Grady Booch • OMT by James Rumbaugh • OOSE by Ivar Jacobson • Statechart is one of the Nine building blocks supported by the UML M.Tech Project Presentation By Guntapudi V R, SIT, IIT BOMBAY

  14. Statecharts : A Visual Formalism for Complex Systems • Origins Of Statecharts • FSMs • STDs • Harel Statecharts • Limitations of State Machines • Doesn’t • Provide State Hierarchy • Have History Info. • Have Concurrent States M.Tech Project Presentation By Guntapudi V R, SIT, IIT BOMBAY

  15. Semantics of Statecharts • State • Event • Transitions • Event [Guard] / Action Transition M.Tech Project Presentation By Guntapudi V R, SIT, IIT BOMBAY

  16. Example for Statechart Semantics M.Tech Project Presentation By Guntapudi V R, SIT, IIT BOMBAY

  17. More features of Statecharts • Generalization • Simplifies by Factorization • Orthogonality • Simplifies by Segmentation • History Info. • To memorize the substate last visited M.Tech Project Presentation By Guntapudi V R, SIT, IIT BOMBAY

  18. Example for Generalization M.Tech Project Presentation By Guntapudi V R, SIT, IIT BOMBAY

  19. Example for Orthogonality M.Tech Project Presentation By Guntapudi V R, SIT, IIT BOMBAY

  20. Example for History state M.Tech Project Presentation By Guntapudi V R, SIT, IIT BOMBAY

  21. Importance of Testing Statecharts Statecharts play crucial role in modeling • Safety-critical systems • Networking Protocols • GUIs (Graphical User Interfaces) • OOD (Object-Oriented Design) M.Tech Project Presentation By Guntapudi V R, SIT, IIT BOMBAY

  22. Methodology of Testing SCs M.Tech Project Presentation By Guntapudi V R, SIT, IIT BOMBAY

  23. Coverage Metrics • State Coverage • Ratio of number of states covered and total number of states in the given state model • Event Coverage • Ratio of number of events covered and total number of events in the given state model • Transition Coverage • Ratio of number transitions exercised and total number of transitions in the given state model • State-Event Coverage • Ratio of state-event pairs exercised and number of states multiply number of events in the given state model M.Tech Project Presentation By Guntapudi V R, SIT, IIT BOMBAY

  24. Design Specification of StateTest Tool • Two inputs and Three outputs • Input_1 : Statechart specification generated by Statechart Editor(SCE) by BARC • Input_2 : Test Script File • Output_1 : Pass / Fail report • Output_2 : Coverage Metrics • Output_3 : Error Report M.Tech Project Presentation By Guntapudi V R, SIT, IIT BOMBAY

  25. Statechart Spec. and Test Case’s Formats M.Tech Project Presentation By Guntapudi V R, SIT, IIT BOMBAY

  26. DFD Level 0 for StateTest M.Tech Project Presentation By Guntapudi V R, SIT, IIT BOMBAY

  27. DFD Level 1 for StateTest M.Tech Project Presentation By Guntapudi V R, SIT, IIT BOMBAY

  28. Implementation Details • StateTest tool is implemented by using JAVA language • StateTest tool has justfour classes M.Tech Project Presentation By Guntapudi V R, SIT, IIT BOMBAY

  29. Object Specification of StateTest • Four Classes • StatesInfo • Reads the Statechart specification file • CopyStateHierarchy • Reads the hierarchical from the StatesInfo class • TestScriptReading • Reads the Test Script file • ReportGenerator • Generates pass / fail report M.Tech Project Presentation By Guntapudi V R, SIT, IIT BOMBAY

  30. Initial Object Specification for StateTest M.Tech Project Presentation By Guntapudi V R, SIT, IIT BOMBAY

  31. Detailed Object Specification for StateTest Tool M.Tech Project Presentation By Guntapudi V R, SIT, IIT BOMBAY

  32. Experiments • Code generated by SCE (BARC tool) from the Statechart figures • Statechart’s Specification as a 4-tuple by StateTest tool internally • Experimented with many complex Statecharts • Execution time of each test case is reasonable M.Tech Project Presentation By Guntapudi V R, SIT, IIT BOMBAY

  33. Conclusions • StateTest Tool is effective for Statechart Testing • Future work: • Can be generalized to other input files… • Orthogonality • History M.Tech Project Presentation By Guntapudi V R, SIT, IIT BOMBAY

  34. Thank You M.Tech Project Presentation By Guntapudi V R, SIT, IIT BOMBAY

More Related