Testing
Testing
Introduction
• The aim of program testing is to help in identifying all defects in a
program.
• However, in practice, even after satisfactory completion of the
testing phase, it is not possible to guarantee that a program is
error free.
Basic Concepts and Terminologies
• How to test a program?
• Testing a program involves executing the program with a set of test inputs
and observing if the program behaves as expected.
• If the program fails to behave as expected, then the input data and the
conditions under which it fails are noted for later debugging and error
correction.
• However, unless the conditions under which a software fails are noted down,
it becomes difficult for the developers to reproduce a failure observed by the
testers.
• For example, a software might fail for a test case only when a network
connection is enabled. Unless this condition is documented in the failure
report, it becomes difficult to reproduce the failure.
Terminologies
• After all the units of a program have been integrated together and
tested, system testing is taken up.
• The system testing procedures are the same for both object-
oriented and procedural programs, since system test cases are
designed solely based on the SRS document and the actual
implementation (procedural or object-oriented) is immaterial.
• There are three main kinds of system testing. These are essentially
similar tests, but differ in who carries out the testing:
1. Alpha Testing: Alpha testing refers to the system testing carried
out by the test team within the developing organisation.
2. Beta Testing: Beta testing is the system testing performed by a
select group of friendly customers.
3. Acceptance Testing: Acceptance testing is the system testing
performed by the customer to determine whether to accept the
delivery of the system.
• As can be observed from the above discussions, in the different
types of system tests, the test cases can be the same, but the
difference is with respect to who designs test cases and carries
out testing.
• Before a fully integrated system is accepted for system testing,
smoke testing is performed. Smoke testing is done to check
whether at least the main functionalities of the software are
working properly.
• Unless the software is stable and at least the main functionalities
are working satisfactorily, system testing is not undertaken.
• The functionality tests are designed to check whether the
software satisfies the functional requirements as documented in
the SRS document.
• The performance tests, on the other hand, test the conformance
of the system with the non-functional requirements of the system.
Smoke Testing
• Smoke testing is carried out before initiating system testing to
ensure that system testing would be meaningful, or whether many
parts of the software would fail.
• The idea behind smoke testing is that if the integrated program
cannot pass even the basic tests, it is not ready for a vigorous
testing.
• For smoke testing, a few test cases are designed to check whether
the basic functionalities are working.
• For example, for a library automation system, the smoke tests may
check whether books can be created and deleted, whether
member records can be created and deleted, and whether books
can be loaned and returned.
Performance Testing