Testing Basics
Testing Basics
Requirements
Business requirements are gathered in this phase. This phase is the main focus of the project managers
and stake holders Meetings with managers, stake holders and users are held in order to determine the
requirements. Who is going to use the system? How will they use the system? What data should be
input into the system?What data should be output by the system? These are general questions that get
answered during a requirements gathering phase. This produces a nice big list of functionality that the
system should provide, which describes functions the system should perform, business logic that
processes data, what data is stored and used by the system, and how the user interface should work.
The overall result is the system as a whole and how it performs, not how it is actually going to do it.
Design
The software system design is produced from the results of the requirements phase. Architects have the
ball in their court during this phase and this is the phase in which their focus lies. This is where the
details on how the system will work is produced. Architecture, including hardware and software,
communication, software design (UML is produced here) are all part of the deliverables of a design
phase.
Implementation
Code is produced from the deliverables of the design phase during implementation, and this is the
longest phase of the software development life cycle. For a developer, this is the main focus of the life
cycle because this is where the code is produced. Implementation my overlap with both the design and
testing phases. Many tools exists (CASE tools) to actually automate the production of code using
information gathered and produced during the design phase.
Testing
During testing, the implementation is tested against the requirements to make sure that the product is
actually solving the needs addressed and gathered during the requirements phase. Unit tests and
system/acceptance tests are done during this phase. Unit tests act on a specific component of the
system, while system tests act on the system as a whole.
Waterfall Model
Advantages
• Simple and easy to use.
• Easy to manage due to the rigidity of the model – each phase has specific deliverables and a
review process.
• Phases are processed and completed one at a time.
• Works well for smaller projects where requirements are very well understood.
Disadvantages
• Adjusting scope during the life cycle can kill a project
• No working software is produced until late during the life cycle.
• High amounts of risk and uncertainty.
• Poor model for complex and object-oriented projects.
• Poor model for long and ongoing projects.
• Poor model where requirements are at a moderate to high risk of changing.
Advantages
• Simple and easy to use.
• Each phase has specific deliverables.
• Higher chance of success over the waterfall model due to the development of test plans early on
during the life cycle.
• Works well for small projects where requirements are easily understood.
• Faults are prevented and it stops fault multiplication.
• Avoids the downward flow of defect.
• Lower defect Resolution cost due to earlier detection.
• Improved quality and reliability.
• Reduction in the amount of Re-work.
• Improved Risk Management Validation and Verification at each level of stage containment
• Allows testers to be active in the project early in the project’s lifecycle. They develop critical
knowledge about the system.
Disadvantages
• Very rigid, like the waterfall model.
• Little flexibility and adjusting scope is difficult and expensive.
• Software is developed during the implementation phase, so no early prototypes of the software
are produced.
• Model doesn’t provide a clear path for problems found during testing phases.
Software testing life cycle identifies what test activities to carry out to accomplish quality assurance
process in a software development project.
There are different kinds of software development life cycle such as Waterfall, Spiral, Agile, and many
others. Software testing has its own life cycle that intersects with every stage of the SDLC either it is
Waterfall, Spiral or Agile. However, SDLC varies form one to another based on size of project, test
team, test in Scope/out of scope, and code release date (how frequently). So, knowledge about some of
the major phase in STLC, quality assurance activities during phases and role of a tester, makes you as a
tester always ready to accomplish your task with a mark. This picture describes one of widely used
STLC phases.
Generally STLC for a single test cycle consists of phases: 1) Planning, 2) Analysis, 3) Design, 4) Initial
Testing 5) Testing Cycles, 6) Final Testing and Implementation and 7) Post release
Planning :
Testing is the process of showing the presence of defects. Testing is the process of exercising or evaluating
a system or
system component by manual or automated means to verify
that it satisfies specified requirements, or to identify differences
between expected and actual results
Process of testing :
Types of testing :
Unit testing :
The most ‘micro’ scale of Testing (A unit = smallest testable software component).Performed
by Programmer .
A tester can help. Requires detailed knowledge of the internal program design and code. The
units are tested in isolation.
Ensures the component is working according to the detailed design/build specifications of the
module.
Also known as component, module, or program testing.
Integration Testing :
Testing of more than one (tested) unit together to determine if they function correctly. Focus on
interfaces
Communication between units .Helps assembling incrementally a whole system, ensuring the
correct ‘flow’ of data from the first through the final component.
Done by developers/designers and testers in collaboration
Also called Interface Testing or Assembly Testing.
System testing :
Testing the system as a whole - Black-box type testing that is based on overall requirements
specifications; covers all combined parts of a system.
Ensures that system meets all functional and business requirements.
Focus :
Verifying that specifications are met
Validating that the system can be used for the intended purpose
The system test design is derived from the system design documents and is used in this phase.
It can involve a number of specialized types of tests to check performance, stress,
documentation etc. Sometimes testing is automated using testing tools.
Done by Independent testing group.
Approach
Should be performed in real operating environment .
Customer should be able to perform any test based on their business processes.
Final Customer sign-off.