2.2 unit testing
•Unit testing focuses verification effort on the
smallest unit of software design—the
software component or module. Using the
component-level design description as a
guide, important control paths are tested to
uncover errors within the boundary of the
module.
Stubs and drivers
Thesedummypiecesofcodearethestubs.
Ontheotherhand,Driversaretheones,
whicharethe"calling"programs.Driversare
used in bottom up testing
approach.Driversaredummycode,whichis
usedwhenthesubmodulesarereadybutthe
mainmoduleisstillnotready....Thisdummy
codeisthencalledDriver.
•Integration testing
•Integration testing is the second level of the software
testing process comes after unit testing. In this testing,
units or individual components of the software are
tested in a group. The focus of the integration testing
level is to expose defects at the time of interaction
between integrated components or units.
•Unit testinguses modules for testing purpose, and
these modules are combined and tested in integration
testing. The Software is developed with a number of
software modules that are coded by different coders or
programmers. The goal of integration testing is to check
the correctness of communication among all the
modules.
Video lecture on
•Integration testing:
Top down integration
Top-downintegrationtestingisanincremental
approachtoconstructionofthesoftware
architecture.Modulesareintegratedby
movingdownwardthroughthecontrol
hierarchy,beginningwiththemaincontrol
moduleTop-downintegration.(mainprogram).
Beta Testing of a product is performed by "real
users" of the software application in a "real
environment" and can be considered as a form of
external user acceptance testing.
Beta version of the software is released to a
limited number of end-users of the product to
obtain feedback on the product quality. Beta
testing reduces product failure risks and provides
increased quality of the product through
customer validation.
•Define functional Testing.
•Functional tests at the system level are used ensure that the
behavior of the system
•adheres to the requirement specifications.
•What are the two major requirements in the Performance testing.
•Functional Requirement: User describe what functions the
software should
•perform. We test for compliance of the requirement at the system
level with the
•functional based system test.
•Quality Requirement: They are nonfunctional in nature but
describe quality
•levels expected for the software
•What are the steps for top down integration?
•Main control module is used as a test driver and stubs
are substituted for all
•components directly subordinate to the main module.
•Depending on integration approach (Depth or breadth
first) subordinate stubs are
•replaced one at a time with actual components.
•Tests are conducted as each component is integrated.
•The completion of each set of tests another stub is
replaced with real component
•What is meant by regression testing?
•Regression testing is used to check for defects
propagated to other modules by
•changes made to existing program. Thus,
regression testing is used to reduce the side
•effects of the changes.
•Advantages of Black Box Testing
•The test is unbiased because the designer and the tester are independent
of each other.
•The tester does not need knowledge of any specific programming
languages.
•The test is done from the point of view of the user, not the designer.
•Test cases can be designed as soon as the specifications are complete.
•Disadvantages of Black Box Testing
•The test can be redundant if the software designer has already run a test
case.
•The test cases are difficult to design.
•Testing every possible input stream is unrealistic because it would take a
inordinate amount of time; therefore, many program paths will go
untested.