35 Software Testing – Lecture II

Integration Testing:

 

The main objective of integration testing Objective is to take unit tested modules and build a program structure based on the prescribed design. Two major approaches are

  • Non-incremental Integration Testing.
  • Incremental Integration Testing.

Non-incremental Integration Testing is commonly called the “Big Bang” approach. All components are combined in advance. The entire program is tested as a whole. Many seemingly-unrelated errors are encountered. Correction is difficult because isolation of causes is complicated. Once a set of errors are corrected, more errors occur, and testing appears to enter an endless loop.

 

Incremental integration testing are of three kind:

  • Top-down integration
  • Bottom-up integration
  • Sandwich integration

    The program is constructed and tested in small increments. Errors are easier to isolate and correct.

Interfaces are more likely to be tested completely. A systematic test approach is applied.

 

In top-down integration the modules are integrated by moving downward through the control hierarchy, beginning with the main module. Subordinate modules are incorporated in either a depth-first or breadth-first fashion. This approach verifies major control or decision points early in the test process.

 

DF: All modules on a major control path are integrated.

 

BF: All modules directly subordinate at each level are integrated.

 

The major disadvantages are stubs need to be created to substitute for modules that have not been built or tested yet; this code is later discarded. Because stubs are used to replace lower level modules, no significant data flow can occur until much later in the integration/testing process.

 

In bottom-up integration, integration and testing starts with the most atomic modules in the control hierarchy. The major advantage is that this approach verifies low-level data processing early in the testing process. Need for stubs is eliminated. The major disadvantages is driver modules need to be built to test the lower-level modules; this code is later discarded or expanded into a full-featured version. Drivers inherently do not contain the complete algorithms that will eventually use the services of the lower-level modules; consequently, testing may be incomplete.

 

Sandwich Integration consists of a combination of both top-down and bottom-up integration. This Occurs both at the highest level modules and also at the lowest level modules. Proceeds using functional groups of modules, with each group completed before the next: High and low-level modules are grouped based on the control and data processing they provide for a specific program feature. Integration within the group progresses in alternating steps between the high and low level modules of the group. When integration for a certain functional group is complete, integration and testing moves onto the next group. Reaps the advantages of both types of integration while minimizing the need for drivers and stubs. Requires a disciplined approach so that integration doesn’t tend towards the “big bang” scenario.

In regression testing, each new addition or change to baselined software may cause problems with functions that previously worked flawlessly. Regression testing re-executes a small subset of tests that have already been conducted. It also ensures that changes have not propagated unintended side effects. The strategy helps to ensure that changes do not introduce unintended behavior or additional errors. Regression testing may be done manually or through the use of automated capture/playback tools. Regression test suite contains three different classes of test cases:

A representative sample of tests that will exercise all software functions.

  • Additional tests that focus on software functions that are likely to be affected by the change. Tests that focus on the actual software components that have been changed.

Validation testing follows integration testing, the distinction between conventional and object-oriented software disappears. It focuses on user-visible actions and user-recognizable output from the system. It demonstrates conformity with requirements. Designed to ensure that:

  • All functional requirements are satisfied.
  • All behavioral characteristics are achieved.
  • All performance requirements are attained.

After each validation test, the function or performance characteristic conforms to specification and is accepted. A deviation from specification is uncovered and a deficiency list is created. A configuration review or audit ensures that all elements of the software configuration have been properly developed, cataloged, and have the necessary detail for entering the support phase of the software life cycle.

 

Alpha Testing is conducted at the developer’s site by end users. Software is used in a natural setting with developers watching intently. Testing is conducted in a controlled environment. Beta Testing is conducted at end-user sites. Developer is generally not present. It serves as a live application of the software in an environment that cannot be controlled by the developer. The end-user records all problems that are encountered and reports these to the developers at regular intervals. After beta testing is complete, software engineers make software modifications and prepare for release of the software product to the entire customer base.

In Recovery Testing tests for recovery from system faults. Forces the software to fail in a variety of ways and verifies that recovery is properly performed. Tests re-initialization, check pointing mechanisms, data recovery, and restart for correctness. In Security Testing it verifies that protection mechanisms built into a system will, in fact, protect it from improper access. In Stress Testing, executes a system in a manner that demands resources in abnormal quantity, frequency, or volume.

Usability is a measure of how easy it is to use something (“user-friendliness”). Usability is the extent to which a product can be used by specified users to achieve specified goals with effectiveness, efficiency and satisfaction in a specified context of use.” A means for measuring how well people can use some human-made object (such as a web page, a computer interface, a document, or a device) for its intended purpose. It involves carefully creating a scenario, or realistic situation, where the person performs a list of tasks using the product being tested while observers watch and take notes.

 

In black-box testing, knowing the specified function that a product has been designed to perform, test to see if that function is fully operational and error free. Black box testing includes tests that are conducted at the software interface. They are not concerned with internal logical structure of the software.

 

In white-box testing knowing the internal workings of a product, test that all internal operations are performed according to specifications and all internal components have been exercised. Involves tests that concentrate on close examination of procedural detail. Logical paths through the software are tested. Test cases exercise specific sets of conditions and loops. White box testing is testing where we use the information available from the code of the component to generate tests. This information is usually used to achieve coverage in one way or another.

 

A website, is a central location of various web pages that are all related and can be accessed by visiting the home page using a browser. A web portal is a customized website that immerses information from a wide array of sources in a consistent and uniformed manner. Website testing is the name given to Software Testing that focuses on web applications. Complete testing of a web-based system before going live can help address issues before the system is revealed to the public. Website testing includes:

  •  Functionality Testing
  • Usability Testing
  • Interface Testing
  • Compatibility Testing
  • Performance Testing
  • Security Testing

Functionality Testing

Test for all the links in web pages, database connection, forms used for submitting or getting information from user in the web pages, Cookie testing etc.

Usability Testing:

Is used to test for navigation. It is also used commonly for content checking and other useful information like Sitemap.

Interface Testing:

Check if all the interactions between these servers are executed and errors are handled properly. Check what happens if user interrupts any transaction in-between? Check what happens if connection to the web server is reset in between?

Compatibility Testing:

It tests the browser compatibility, operating system compatibility, mobile browsing and printing options.

Web Stress testing:

It verifies can system sustain in peak load times? How the system reacts to stress and how it recovers from crashes?

Security Testing:

—   Security Scanning: involves identifying network and system weaknesses, and provides solutions for reducing these risks.

—   Penetration testing: simulates an attack from a malicious hacker. This testing involves analysis of a particular system to check for potential vulnerabilities to an external hacking attempt.

— Ethical hacking: Unlike malicious hackers who steal for their own gains, the intent is to expose security flaws in the system.

— Risk Assessment: This testing involves analysis of security risks observed in the Website. This testing recommends controls and measures to reduce the risk.

 

Summary

 

Software testing plays a major role in delivering a quality assured software product. Black box testing is concerned with the functionality of the software where as White box testing deals with the internal structure of the code. Website testing includes usability, compatibility, performance and security checking.