S.E.asinmnt Testing Strategies

download S.E.asinmnt Testing Strategies

of 8

Transcript of S.E.asinmnt Testing Strategies

  • 8/8/2019 S.E.asinmnt Testing Strategies

    1/8

    SOFTWARE TESTING STRATEGIES

    A strategy for software testing integrates software test case design methods into a well- planned series of steps that result in the successful construction of software. Thereforeany testing strategy must be incorporate test planning, test case design, test execution,

    and resultant data collection and evaluation.CHARACTERISTICS OF SOFTWARE TESTING STRATEGIES

    1. It should be flexible enough to promote a customized testing approach.2. At the same time, it should be rigid enough to promote reasonable planning and

    management tracking as the project progresses.

    STRATEGIC APPROACH TO SOFTWARE TESTING

    Testing is a set of activities that can be planned in advance and conducted systematically.

    For this reason a template for software testing-a set of steps into which we can placespecific test case design techniques and testing methods-should be defined for thesoftware process.

    A strategy must provide guidance for the practitioner and a set of milestones for themanager. Because the steps strategy occurs at the time when deadline pressure begins torise, progress must be measurable and problems must surface as early as possible.

    STRATEGIC ISSUES

    The following issues must be addressed if a successful testing strategy is to be

    implemented.1. Specific project requirement in a quantifiable manner long before testing

    commences:Although the overriding objective of testing is to find errors, a good testing

    strategy also assesses other quality characteristics such as portability, maintainability,and usability. These should be specified in a way that is measurable so that testingresults are unambiguous.

    2. State testing objectives explicitly:The specific objectives of testing should be stated in measurable terms, such

    as mean time to failure, the cost to find and fix defects, test effectiveness, test coverage,etc.

    3. Understand the users of the software and develop a profile for each user category:Use-case that describes the interaction scenario for each class of user can

    reduce overall testing effort by focusing testing on actual use of the product.

    4. Develop a testing plan that emphasizes rapid cycle testing:

  • 8/8/2019 S.E.asinmnt Testing Strategies

    2/8

  • 8/8/2019 S.E.asinmnt Testing Strategies

    3/8

  • 8/8/2019 S.E.asinmnt Testing Strategies

    4/8

    VARIOUS INCREMENTAL INTEGRATION STRATEGIES

    The various incremental integration strategies are:1. Top-down Integration2. Bottom-up Integration

    3. Regression Testing.

    They could be explained as under:

    Top-down Integration:

    Top-down integration testing is an incremental approach to construction program structure. Modules are integrated by moving downward through thecontrol hierarchy, beginning with the main control module (main program).Modules subordinate to the main module are incorporated into the structure ineither a depth-first or breadth-first manner.

    The integration process is performed in a series of five steps which are as follows:

    1. The main control module is used as a test driver and stubs are substituted for allcomponents directly subordinate to the main control module.

    2. Depending on the integration approach selected, subordinate stubs are replacedone at a time with actual components.

    3. Tests are conducted as each component is integrated.4. On completion of each set of tests, another stub is replaced with the real

    component.

    M1

    M2 M3M4

    M5 M6M7

    M8

  • 8/8/2019 S.E.asinmnt Testing Strategies

    5/8

    5. Regression testing may be conducted to ensure that new errors have not beenintroduced.

    The process continues from step 2 until the entire program structure is built.

    Bottom-up Integration:

    Bottom-up integration testing begins construction and testing with atomicmodules, that is, components at the lowest levels in the program structure.

    A bottom-up integration strategy may be implemented with the following steps:

    1. Low-level components are combined into clusters that perform a specificsoftware sub-function.

    2. A control program for testing (drivers) is written to co-ordinate test case inputand output.

    3. The cluster is tested.4. Drivers are removed and clusters are combined moving upward in the program structure.

    As integration moves upward, the need for separate test drivers lessens. In fact, if the toptwo levels of program structure are integrated top down, the number of drivers can bereduced substantially and integration of clusters is greatly simplified.

    Regression Testing:

    Each time a new module is added as part of integration testing, the software

    changes. New data flow paths are established, new I/O may occur, and new controllogic is invoked. These changes may cause problems with functions that previouslyworked flawlessly. In the context of an integration test strategy, regression testing isthe re-execution of some subset of tests that have already been conducted to ensurethat changes have not propagated unintended side effects. Regression test is theactivity that helps to ensure that changes do not introduce unintended behavior or additional errors.

    VALIDATION TESTING

    Validation testing begins when the software is completely assembled as a package,

    interfacing errors have been uncovered and corrected, and a final series of softwaretesting is to be done. In simple words validation succeeds when software functions ina manner that can be reasonably expected by a customer.

    Reasonable expectations of the customer are defined in the System RequirementsSpecification (SRS)-a document that describes all user visible attributes of thesoftware. The specification contains a section called Validation Criteria. Informationcontained in that section forms the basis for a validation testing approach.

  • 8/8/2019 S.E.asinmnt Testing Strategies

    6/8

    ALPHA AND BETA TESTING

    It is virtually impossible for a software developer to foresee how the customer willreally use a program. Thus when custom software is built for a customer, a series of acceptance tests are conducted to enable the customer to validate all requirements.

    Acceptance tests are conducted by the end user and can be either an informal testdrive or a planned and systematically executed series of tests. Therefore acceptancetesting is conducted to uncover cumulative errors that might degrade the system over time. If the software is developed as a product to be used by many customers it isimpractical to perform formal acceptance tests with each one. Thus the process calledalpha and beta testing is used to uncover errors that only the end user seems able tofind.

    The alpha test is conducted at the developers site by a customer. The software is usedin a natural setting with the developer by user and recording errors and usage

    problems. Alpha tests are conducted in a controlled environment.

    The beta test is conducted at one or more customer sites by the end user of thesoftware. While conducting this test the developer is not present and therefore it is alive application of the software in an environment that cannot be controlled by thedeveloper. The customer records all the problems that are encountered and reportsthese to the developer at regular intervals. As a result of problems reported during

    beta tests software engineers make modifications and then prepare for the release of the software product to the entire customer base.

    SYSTEM TESTING

    Software is incorporated with system elements and a series of system integration andvalidation tests are conducted. These tests fall outside the scope of the software

    process and are not conducted by the software engineers.

    On discovering an error the developers should do the following: Design error-handling paths that test all information coming from the other parts

    of the system. Conduct a series of tests that simulate bad data or other potential errors at the

    software interface. Record the results of tests. Participate in design and planning of the system tests to ensure that the software is

    adequately tested.

    System testing is actually a series of different tests whose primary purpose is to fullyexercise the computer-based system. Although each test has a different purpose, all work to verify that system elements have been properly integrated and perform allocatedfunctions.

    STRESS TESTING

    The earlier testing techniques resulted in thorough evaluation of normal programfunctions and performance. Stress tests are designed to confront programs with abnormal

  • 8/8/2019 S.E.asinmnt Testing Strategies

    7/8

    situations. In essence, the tester who performs stress testing asks how high can we crank this up before it fails?

    Stress testing executes a system in a manner that demands resources in abnormalquantity, frequency, or volume. I n other words, the tester attempts to break the program.

    PERFORMANCE TESTING

    Performance testing is designed to test the run-time performance of software within thecontext of an integrated system. Performance testing occurs throughout all steps in thetesting process. However, it is not until all system elements are fully integrated that thetrue performance of a system can be ascertained.

    Performance tests are often coupled with stress testing and usually require both hardwareand software instrumentation. That is, it is often necessary to measure resource utilization

    in an exacting fashion.

    THE ART OF DEBUGGING

    Debugging occurs as a consequence of successful testing. That is, when a test caseuncovers an error, debugging is the process that results in the removal of the error.

    DEBUGGING APPROACHES

    Regardless of the approach that is taken, debugging has one overriding objective: to findand correct the cause of a software error. The objective is realized by a combination of systematic evaluation, intuition, and luck.

    In general, three categories for debugging approaches may be proposed:1. Brute Force2. Backtracking3. Cause Elimination.

    The brute force category of debugging is the most common and least efficient method for isolating the cause of a software error. In it the sub parts of the system are randomlyoperated in order to locate the error.

    Backtracking is a fairly common debugging approach that can be used successfully insmall programs. Beginning at the site where a symptom has been uncovered, the sourcecode is traced backward until the site of the cause is found.

    The cause elimination approach is manifested by induction or deduction and introducesthe concept of binary partitioning. Data related to the error occurrence are organized to

  • 8/8/2019 S.E.asinmnt Testing Strategies

    8/8

    isolate potential causes. A cause hypothesis is devised and the aforementioned data areused to prove or disprove the hypothesis.

    SUMMARY

    Software testing accounts for the largest percentage of technical effort in thesoftware process.

    The objective of software testing is to uncover errors. To fulfill this objective, aseries of test steps are planned and executed which consist of unit, integration andsystem tests.

    Each test step is accomplished through a series of systematic test techniques thatassist in the design of the test cases. With each testing step, the level of abstraction with which software is considered is broadened.

    Debugging is viewed as an art. Beginning with a symptomatic indication of a problem, the debugging activity must track down the cause of an error. Of the

    many resources available during debugging, the most valuable is the counsel of other members of the software engineering staff.

    The requirement for higher quality software demands a more systematic approachto testing.