Software Testing Life Cycle


Published on

Published in: Technology, Business
No Downloads
Total views
On SlideShare
From Embeds
Number of Embeds
Embeds 0
No embeds

No notes for slide

Software Testing Life Cycle

  1. 1. Software Testing Life Cycle Designed and Compiled by: Udayakumar Sree Senior Test Engineer
  2. 2. STLC - Definition <ul><li>The course of software being tested in a well-planned way is known as Software test life cycle. </li></ul>Contract Signing Requirement Analysis Test Planning Test Development Test Execution Defect Reporting Retest Defects Product Delivery
  3. 3. STLC – Stages Involved <ul><li>Contract Signing: </li></ul><ul><ul><li>Process - The project is signed with client for testing the software </li></ul></ul><ul><ul><li>Documents involved: </li></ul></ul><ul><ul><ul><li>SRS </li></ul></ul></ul><ul><ul><ul><li>Test Deliverables </li></ul></ul></ul><ul><ul><ul><li>Test Metrics etc. </li></ul></ul></ul>
  4. 4. STLC – Stages Involved <ul><li>Requirement Analysis: </li></ul><ul><ul><li>Process: Analyzing software for design and implementation methods and testable aspects are recorded </li></ul></ul><ul><ul><li>Documents involved: </li></ul></ul><ul><ul><ul><li>Requirement Specification documents </li></ul></ul></ul><ul><ul><ul><li>Functional Specification documents </li></ul></ul></ul><ul><ul><ul><li>Design Specification documents (use cases, etc) </li></ul></ul></ul><ul><ul><ul><li>Use case Documents </li></ul></ul></ul><ul><ul><ul><li>Test Trace-ability Matrix for identifying Test Coverage </li></ul></ul></ul>
  5. 5. STLC – Stages Involved <ul><li>Test Planning: </li></ul><ul><ul><li>Process: To plan, how the testing process should flow </li></ul></ul><ul><ul><ul><li>Test Process Flow </li></ul></ul></ul><ul><ul><ul><ul><li>Test Scope, Test Environment </li></ul></ul></ul></ul><ul><ul><ul><ul><li>Different Test phase and Test Methodologies </li></ul></ul></ul></ul><ul><ul><ul><ul><li>Manual and Automation Testing </li></ul></ul></ul></ul><ul><ul><ul><ul><li>Defect Mgmt, Configuration Mgmt, Risk Mgmt. Etc </li></ul></ul></ul></ul><ul><ul><ul><ul><li>Evaluation & identification – Test, Defect tracking tools </li></ul></ul></ul></ul><ul><ul><li>Documents Involved: </li></ul></ul><ul><ul><ul><li>Master Test Plan, Test Scenario, SCM </li></ul></ul></ul>
  6. 6. STLC – Stages Involved <ul><li>Test Development </li></ul><ul><ul><li>Process: </li></ul></ul><ul><ul><ul><li>Test Traceability Matrix and Test coverage </li></ul></ul></ul><ul><ul><ul><li>Test Scenarios Identification & Test Case preparation </li></ul></ul></ul><ul><ul><ul><li>Test data and Test scripts preparation </li></ul></ul></ul><ul><ul><ul><li>Test case reviews and Approval </li></ul></ul></ul><ul><ul><ul><li>Base lining under Configuration Management </li></ul></ul></ul><ul><ul><li>Documents Involved: </li></ul></ul><ul><ul><ul><li>Test Plan, RTM </li></ul></ul></ul><ul><ul><ul><li>Test cases </li></ul></ul></ul>
  7. 7. STLC – Stages Involved <ul><li>Test Execution: </li></ul><ul><ul><li>Process: </li></ul></ul><ul><ul><ul><li>Executing Test cases </li></ul></ul></ul><ul><ul><ul><li>Testing Test Scripts </li></ul></ul></ul><ul><ul><ul><li>Capture, review and analyze Test Results </li></ul></ul></ul><ul><ul><ul><li>Raising the defects and tracking for its closure </li></ul></ul></ul><ul><ul><li>Documents Involved: </li></ul></ul><ul><ul><ul><li>Test Cases </li></ul></ul></ul><ul><ul><ul><li>Test Execution report </li></ul></ul></ul><ul><ul><ul><li>Bug report </li></ul></ul></ul><ul><ul><ul><li>Requirement traceability matrix </li></ul></ul></ul>
  8. 8. STLC – Stages Involved <ul><li>Defect Reporting </li></ul><ul><ul><li>Process: </li></ul></ul><ul><ul><ul><li>Defect logging </li></ul></ul></ul><ul><ul><ul><li>Assigning defect and fixing </li></ul></ul></ul><ul><ul><ul><li>Retesting </li></ul></ul></ul><ul><ul><ul><li>Defect closing </li></ul></ul></ul><ul><ul><li>Documents involved: </li></ul></ul><ul><ul><ul><li>Test report </li></ul></ul></ul><ul><ul><ul><li>Bug Report </li></ul></ul></ul>
  9. 9. STLC – Stages Involved <ul><li>Product Delivery </li></ul><ul><ul><li>Process: </li></ul></ul><ul><ul><ul><li>After the product had undergone several tests, the acceptance test is done by the user/client i.e. UAT, wherein the use cases were executed and the product is accepted to go on live </li></ul></ul></ul><ul><ul><ul><li>Test Metrics and process Improvements made </li></ul></ul></ul><ul><ul><ul><li>Build release </li></ul></ul></ul><ul><ul><ul><li>Receiving acceptance </li></ul></ul></ul><ul><ul><li>Documents involved </li></ul></ul><ul><ul><ul><li>Test summary reports </li></ul></ul></ul><ul><ul><ul><li>UAT Test Plan, UAT Test cases </li></ul></ul></ul>
  10. 11. Test Plan – What? <ul><li>Derived from Test Approach, Requirements, Project Plan, Functional Spec., and Design Spec </li></ul><ul><li>Details out project-specific Test Approach </li></ul><ul><li>Lists general (high level) Test Case areas </li></ul><ul><li>Include testing Risk Assessment </li></ul><ul><li>Include preliminary Test Schedule </li></ul><ul><li>Lists Resource requirements </li></ul>
  11. 12. Test Plan – Why? <ul><li>Identify Risks and Assumptions up front to reduce surprises later. </li></ul><ul><li>Communicate objectives to all team members. </li></ul><ul><li>Foundation for Test Spec, Test Cases, and ultimately the Bugs we find. </li></ul><ul><li>Failing to plan = planning to fail. </li></ul>
  12. 13. Test Plan – Definition <ul><li>The test strategy identifies multiple test levels, which are going to be performed for the project. Activities at each level must be planned well in advance and it has to be formally documented. Based on the individual plans, the individual test levels are carried out. </li></ul>
  13. 14. Test Plan – Consists of… <ul><li>Unit Testing Tools </li></ul><ul><ul><li>Required tool to test at unit level </li></ul></ul><ul><li>Priority of Program units </li></ul><ul><ul><li>Module-wise priority </li></ul></ul><ul><li>Naming convention for test cases </li></ul><ul><li>Status reporting mechanism </li></ul><ul><li>Regression test approach </li></ul>
  14. 15. Test Plan – Consists of… <ul><li>ETVX Criteria </li></ul><ul><ul><li>E ntry means the entry point to that phase. </li></ul></ul><ul><ul><ul><li>For example, for unit testing, the coding must be complete and then only one can start unit testing </li></ul></ul></ul><ul><ul><li>T ask is the activity that is performed </li></ul></ul><ul><ul><li>V alidation is the way in which the progress and correctness and compliance are verified for that phase </li></ul></ul><ul><ul><li>E x it tells the completion criteria of that phase, after the validation is done. </li></ul></ul><ul><ul><ul><li>For example, the exit criterion for unit testing is all unit test cases must pass </li></ul></ul></ul>
  15. 16. Risk Analysis <ul><li>A risk is a potential for loss or damage to an Organization from materialized threats. Risk Analysis attempts to identify all the risks and then quantify the severity of the risks </li></ul><ul><li>Risk Identification </li></ul><ul><ul><li>Software Risks </li></ul></ul><ul><ul><li>Business Risks </li></ul></ul><ul><ul><li>Testing Risks </li></ul></ul><ul><ul><li>Premature Release Risk </li></ul></ul><ul><ul><li>Risk Methods </li></ul></ul>
  16. 17. Risk Analysis continued… <ul><li>Software Risks </li></ul><ul><ul><li>Knowledge of the most common risks associated with Software development, and the platform you are working on </li></ul></ul><ul><li>Business Risks </li></ul><ul><ul><li>Most common risks associated with the business using the Software </li></ul></ul><ul><li>Testing Risks </li></ul><ul><ul><li>Knowledge of the most common risks associated with Software Testing for the platform you are working on, tools being used, and test methods being applied </li></ul></ul>
  17. 18. Risk Analysis continued… <ul><li>Premature Release Risk </li></ul><ul><ul><li>Ability to determine the risk associated with releasing unsatisfactory or untested Software Products </li></ul></ul><ul><li>Risk Methods </li></ul><ul><ul><li>Strategies and approaches for identifying risks or problems associated with implementing and operating information technology, products and process; assessing their likelihood, and initiating strategies to test those risks </li></ul></ul>
  18. 19. Test Execution
  19. 20. Software Testing Fundamentals <ul><li>Testing objectives include </li></ul><ul><ul><li>Testing is a process of executing a program with the intent of finding an error </li></ul></ul><ul><ul><li>A good test case is one that has a high probability of finding an as yet undiscovered error </li></ul></ul><ul><ul><li>A successful test is one that uncovers an as yet undiscovered error </li></ul></ul>Testing should systematically uncover different classes of errors in a minimum amount of time and with a minimum amount of effort. A secondary benefit of testing is that it demonstrates that the software appears to be working as stated in the specifications
  20. 21. When Testing should start? <ul><li>Testing early in the life cycle reduces the errors. Test deliverables are associated with every phase of development. The goal of Software Tester is to find bugs, find them as early as possible, and make them sure they are fixed </li></ul><ul><li>The number one cause of Software bugs is the Specification </li></ul><ul><li>The next largest source of bugs is the Design </li></ul>
  21. 22. When to Stop Testing? <ul><li>Some reasons to stop test are: </li></ul><ul><ul><li>Deadlines (release deadlines, testing deadlines.) </li></ul></ul><ul><ul><li>Test cases completed with certain percentages passed </li></ul></ul><ul><ul><li>Test budget depleted </li></ul></ul><ul><ul><li>Coverage of code/functionality/requirements reaches a specified point </li></ul></ul><ul><ul><li>The rate at which Bugs can be found is too small </li></ul></ul><ul><ul><li>Beta or Alpha Testing period ends </li></ul></ul><ul><ul><li>The risk in the project is under acceptable limit </li></ul></ul><ul><li>This can be difficult to determine. </li></ul><ul><li>Many modern software applications are so complex, and run in such as interdependent environment, that complete testing can never be done. </li></ul>
  22. 23. Test Execution <ul><li>Testing of an application includes: </li></ul><ul><ul><li>Unit Testing </li></ul></ul><ul><ul><li>Integration testing </li></ul></ul><ul><ul><li>System Testing </li></ul></ul><ul><ul><li>Acceptance testing </li></ul></ul>These are the functional testing strategies and few other functional, non-functional, performance and other testing methods can also be applied on the software.
  23. 24. Test Execution – Unit testing <ul><li>The unit test plan is the overall plan to carry out the unit test activities. The lead tester prepares it and it will be distributed to the individual testers </li></ul><ul><li>Basic input/output of the units along with their basic functionality will be tested </li></ul><ul><li>input units will be tested for the format, alignment, accuracy and the totals </li></ul><ul><li>The UTP will clearly give the rules of what data types are present in the system, their format and their boundary conditions </li></ul><ul><li>Testing the screens, files, database etc., are to be given in proper sequence </li></ul>
  24. 25. Test Execution – Integration testing <ul><li>The integration test plan is the overall plan for carrying out the activities in the integration test level </li></ul><ul><li>This section clearly specifies the kinds of interfaces fall under the scope of testing internal, external interfaces, with request and response is to be explained </li></ul><ul><li>Two approaches practiced are Top-Down and Bottom-Up integrations </li></ul><ul><li>Given this correctly, the testing activities will lead to the product, slowly building the product, unit by unit and then integrating them </li></ul>
  25. 26. Test Execution – System testing <ul><li>The system test plan is the overall plan carrying out the system test level activities </li></ul><ul><li>System testing is based on the requirements </li></ul><ul><li>All requirements are to be verified in the scope of system testing </li></ul><ul><li>The requirements can be grouped in terms of the functionality </li></ul><ul><li>Based on this, there may be priorities also among the functional groups </li></ul><ul><li>Apart from this what special testing is performed are also stated here </li></ul>
  26. 27. Test Execution – Non-functional testing <ul><li>Non-functional testing includes: </li></ul><ul><ul><li>Installation testing – Installation environment, practical obstacles etc. </li></ul></ul><ul><ul><li>Compatibility testing – compatibility with other system software </li></ul></ul><ul><ul><li>Configuration testing - how well the product works with a broad range of hardware/peripheral equipment configurations as well as on different operating systems and software </li></ul></ul><ul><ul><li>Security testing - secure from mistaken/accidental users, hackers, and other malevolent attackers </li></ul></ul><ul><ul><li>Recovery testing - how well a system recovers from crashes, hardware failures, or other catastrophic problems </li></ul></ul><ul><ul><li>Usability testing - Testing for 'user-friendliness' </li></ul></ul>
  27. 28. Test Execution – Performance testing <ul><li>Performance testing includes: </li></ul><ul><ul><li>Load Testing – Testing with the intent of determining how well the product handles competition for system resources. The competition may come in the form of network traffic, CPU utilization or memory allocation </li></ul></ul>
  28. 29. Test Execution – Performance testing <ul><ul><li>Stress testing - Testing with the intent of determining how well a product performs when a load is placed on the system resources that nears and then exceeds capacity </li></ul></ul>
  29. 30. Bug/Defect Management
  30. 31. BUG LIFE CYCLE - What is a bug? <ul><li>A software bug is an error, flaw, mistake, failure, or fault in a computer program that prevents it from behaving as intended. </li></ul>
  31. 32. BUG LIFE CYCLE <ul><li>In software testing, the term life cycle refers to the various stages that a defect/bug assumes over its life. </li></ul>What is a Bug Life Cycle?
  32. 33. BUG LIFE CYCLE <ul><li>The different stages involved in a bug life cycle are as follows: </li></ul><ul><li>Finding Bugs </li></ul><ul><li>Reporting/ Documentation </li></ul><ul><li>Fixing </li></ul><ul><li>Retesting </li></ul><ul><li>Closing </li></ul>Stages involved in Bug Life Cycle
  33. 34. BUG LIFE CYCLE <ul><li>Finding Bugs: </li></ul><ul><ul><li>Software Tester finds bug while testing. </li></ul></ul><ul><ul><li>It is then logged and assigned to a programmer to be fixed. </li></ul></ul><ul><li>Reporting/ Documentation: </li></ul><ul><li>In software, bugs need to be tracked and managed to </li></ul><ul><ul><li>Communicate bug for reproducibility, resolution, and regression. </li></ul></ul><ul><ul><li>Track bug status (open, resolved, closed). </li></ul></ul><ul><ul><li>Ensure bug is not forgotten, lost or ignored </li></ul></ul>Stages explained
  34. 35. BUG LIFE CYCLE <ul><li>Fixing: </li></ul><ul><ul><li>Once the bug is assigned to the developer, he fixes the bug. </li></ul></ul><ul><ul><li>Once the programmer fixes the code , he assigns it back to the tester and the bugs enters the resolved state. </li></ul></ul><ul><li>Retesting: </li></ul><ul><ul><li>The tester then performs a regression test to confirm that the bug is indeed fixed . </li></ul></ul><ul><li>Closing: </li></ul><ul><ul><li>If the bug is fixed, then the tester closes the bug. </li></ul></ul><ul><ul><li>Here the bug then enters its final state, the closed state. </li></ul></ul>Stages explained Continued…
  35. 36. Different status of a Bug
  36. 37. Description of Various Status of a bug <ul><li>New: When the bug is posted for the first time, its state will be “NEW”. This means that the bug is not yet approved. </li></ul><ul><li>Open : After a tester has posted a bug, the lead of the tester approves that the bug is genuine and he changes the state as “OPEN”. </li></ul><ul><li>Assign: Once the lead changes the state as “OPEN”, he assigns the bug to corresponding developer or developer team. The state of the bug now is changed to “ASSIGN”. </li></ul><ul><li>Test: Once the developer fixes the bug, he assigns the bug to the testing team for retesting. Before he releases the software with bug fixed, he changes the state of bug to “TEST”. It specifies that the bug has been fixed and is released to testing team. </li></ul>
  37. 38. Description of Various Status of a bug <ul><li>Deferred: The bug, changed to deferred state means the bug is expected to be fixed in next releases. </li></ul><ul><li>Rejected: If the developer feels that the bug is not genuine, he rejects the bug. Then the state of the bug is changed to “REJECTED”. </li></ul><ul><li>Duplicate: If the bug is repeated twice or the two bugs mention the same concept of the bug, then one bug status is changed to “DUPLICATE”. </li></ul>
  38. 39. Description of Various Status of a bug <ul><li>Verified: Once the bug is fixed and the status is changed to “TEST”, the tester tests the bug. If the bug is not present in the software, he approves that the bug is fixed and changes the status to “VERIFIED”. </li></ul><ul><li>Reopened: If the bug still exists even after the bug is fixed by the developer, the tester changes the status to “REOPENED”. The bug traverses the life cycle once again. </li></ul><ul><li>Closed: Once the bug is fixed, it is tested by the tester. If the tester feels that the bug no longer exists in the software, he changes the status of the bug to “CLOSED”. This state means that the bug is fixed, tested and approved. </li></ul>
  39. 40. Severity of a Bug <ul><li>It indicates the impact each defect has on the testing efforts or users and administrators of the application under test. </li></ul><ul><li>This information is used by developers and management as the basis for assigning priority of work on defects. </li></ul>
  40. 41. Priority Levels of a Bug <ul><li>Critical : </li></ul><ul><ul><li>An item that prevents further testing of the product or function under test can be classified as Critical Bug. No workaround is possible for such bugs. </li></ul></ul><ul><ul><ul><li>Examples of this include a missing menu option or security permission required to access a function under test. </li></ul></ul></ul><ul><li>Major / High : </li></ul><ul><ul><li>A defect that does not function as expected/designed or cause other functionality to fail to meet requirements can be classified as Major Bug. The workaround can be provided for such bugs. </li></ul></ul><ul><ul><ul><li>Examples of this include inaccurate calculations; the wrong field being updated, etc </li></ul></ul></ul>
  41. 42. Priority Levels of a Bug <ul><li>Average / Medium : </li></ul><ul><ul><li>The defects which do not conform to standards and conventions can be classified as Medium Bugs. Easy workarounds exists to achieve functionality objectives. </li></ul></ul><ul><ul><ul><li>Examples include matching visual and text links which lead to different end points. </li></ul></ul></ul><ul><li>Minor / Low : </li></ul><ul><ul><li>Cosmetic defects which does not affect the functionality of the system can be classified as Minor Bugs. </li></ul></ul>
  42. 43. Various Bug tracking tools <ul><li>The various bug tracking tools available are: </li></ul><ul><li>Quality Center® – from HP </li></ul><ul><li>Bugzilla® - from Mozilla </li></ul><ul><li>Dev Track® – from TechExcel </li></ul>
  43. 44. Product Delivery
  44. 45. Product Delivery -Test Deliverables <ul><li>Test Trace-ability Matrix </li></ul><ul><li>Test Plan </li></ul><ul><li>Testing Strategy </li></ul><ul><li>Test Cases (for functional testing) </li></ul><ul><li>Test Scenarios (for non-functional testing) </li></ul><ul><li>Test Scripts </li></ul><ul><li>Test Data </li></ul><ul><li>Test Results </li></ul><ul><li>Test Summary Report </li></ul><ul><li>Release Notes </li></ul><ul><li>Tested Build </li></ul>
  45. 46. Product Delivery - Test Metrics <ul><li>Measuring the correctness of the testing process with measurable is known to be test metrics. </li></ul>
  46. 47. Product Delivery - Test Metrics <ul><li>There are several test metrics identified as part of the overall testing activity in order to track and measure the entire testing process. </li></ul><ul><li>These test metrics are collected at each phase of the testing life cycle/SDLC, analyzed and appropriate process improvements are determined and implemented. The metrics should be constantly collected and evaluated as a parallel activity together with testing, both for manual and automated testing irrespective of the type of application </li></ul>
  47. 48. Product Delivery - Test Metrics - Classification <ul><li>Project Related Metrics – such as </li></ul><ul><ul><li>Test Size, </li></ul></ul><ul><ul><li># of Test Cases tested per day –Automated (NTTA) </li></ul></ul><ul><ul><li># of Test Cases tested per day –Manual (NTTM) </li></ul></ul><ul><ul><li># of Test Cases created per day – Manual (TCED) </li></ul></ul><ul><ul><li>Total number of review defects (RD) </li></ul></ul><ul><ul><li>Total number of testing defects (TD) etc. </li></ul></ul>
  48. 49. Product Delivery – Test Metrics – Classification <ul><li>Process Related Metrics – such as </li></ul><ul><ul><li>Schedule Adherence (SA) </li></ul></ul><ul><ul><li>Effort Variance (EV) </li></ul></ul><ul><ul><li>Schedule Slippage (SS) </li></ul></ul><ul><ul><li>Test Cases and Scripts Rework Effort, etc. </li></ul></ul><ul><li>Customer related Metrics – such as </li></ul><ul><ul><li>Percentage of defects leaked per release (PDLPR) </li></ul></ul><ul><ul><li>Percentage of automation per release (PAPR) </li></ul></ul><ul><ul><li>Application Stability Index (ASI) etc. </li></ul></ul>
  49. 50. Product Delivery – Acceptance testing – UAT <ul><li>The client at their place performs the acceptance testing. It will be very similar to the system test performed by the Software Development Unit </li></ul><ul><li>There is no specific clue on the way they will carry out the testing, since the client performs this test </li></ul><ul><li>It will not differ much from the system testing </li></ul><ul><li>This is just one level of testing done by the client for the overall product and it includes test cases including the unit and integration test level details </li></ul>