You are on page 1of 16

Introduction

To
Software Testing
Table of Contents:

1. Introduction to Software Engineering


2. Software Development Life Cycle.
3. SDLC Models
4. Introduction to Testing
5. Testing Types
6. Testing process
7. Testing life cycle
8. Bug life cycle
9. Bug reporting
10. Introduction to Automation
11. Test Automation Tools
12. Testing FAQ & Terminology
1. Introduction to Software Engineering

Software Engineering:

(SE) is the discipline of designing, creating, and


maintaining software by applying technologies and practices from
computer science, project management, engineering, application
domains and other fields.

The term software engineering was popularized after 1968, during


the 1968 NATO Software Engineering Conference (held in Garmisch,
Germany) by its chairman F.L. Bauer, and has been in widespread
use since.

The term software engineering has been commonly used with a


variety of distinct meanings:

• As the informal contemporary term for the broad range of


activities that was formerly called programming and systems
analysis.
• As the broad term for all aspects of the practice of computer
programming, as opposed to the theory of computer
programming, which is called computer science.
• As the term embodying the advocacy of a specific approach to
computer programming, one that urges that it be treated as
an engineering discipline rather than an art or a craft, and
advocates the codification of recommended practices in the
form of software engineering methodologies
• Software engineering is the application of a systematic,
disciplined, quantifiable approach to the development,
operation, and maintenance of software, that is, the
application of engineering to software," and " the study of
approaches as in " – IEEE Standard 610.12.
Software engineering is concerned with the application of
engineering principles to the conception, development and
verification of a software system. This discipline deals with
identifying, defining, realizing and verifying the required
characteristics of the resultant software. These software
characteristics may include: functionality, reliability,
maintainability, availability, testability, ease-of-use, portability,
and other attributes. Software engineering addresses these
characteristics by preparing design and technical specifications
that, if implemented properly, will result in software that can be
verified to meet these requirements.

Software engineering is also concerned with the characteristics of


the software development process. In this regard, it deals with
characteristics such as cost of development, duration of
development, and risks in development of software.

The Need for Software Engineering


Software is often found in products and situations where 'absolute'
reliability is required, even under demanding conditions, such as
monitoring and controlling nuclear power plants, or keeping a
modern airliner aloft such applications contain millions of lines of
code, making them comparable in complexity to the most complex
modern machines. For example, a modern airliner has several
million physical parts (and the space shuttle about ten million
parts, while the software for such an airliner can run to 4 million
lines of code. It would be impossible to manage the development,
testing, and maintenance of such immense and complex software
without the application of rigorous software engineering practices

Software engineering resembles many different fields in many


different ways. The following paragraphs make some simple
comparisons.
Mathematics

Programs have many mathematical properties. For example the


correctness and complexity of many algorithms are mathematical
concepts that can be rigorously proven. Programs are finite, so in
principle, developers could know many things about a program in a
rigorous mathematical way. The use of mathematics within
software engineering is often called formal methods. However,
computability theory shows that not everything useful about a
program can be proven. Mathematics works best for small pieces of
code and has difficulty scaling up.

Engineering

Software Engineering is considered by many to be an engineering


discipline because there are pragmatic approaches and expected
characteristics of engineers. Proper analysis, documentation, and
commented code are signs of an engineer. David Parnas has argued
that software engineering is engineering. Programs have many
properties that can be measured. For example, the performance
and scalability of programs under various workloads can be
measured. The effectiveness of caches, bigger processors, faster
networks, newer databases is engineering issues. Mathematical
equations can sometimes be deduced from the measurements.
Mathematical approaches work best for system-wide analysis, but
often are meaningless when comparing different small fragments of
code.

Manufacturing

Programs are built in as a sequence of steps. By properly defining


and carrying out those steps, much like a manufacturing assembly
line, advocates hope to improve the productivity of developers and
the quality of final programs. This approach inspires the many
different processes and methodologies. While others, such as the
authors of the Programmer's Stone, contend this view "[is] in fact
claiming to be able to implement an Artificial Intelligence that
simulates a production line designer"[9].
Project management

Commercial (and many non-commercial) software projects require


management. There are budgets and schedules to set. People to
hire and lead. Resources (office space, computers) to acquire. All of
this fits more appropriately within the purview of management.

Art

Programs contain many artistic elements, akin to writing or


painting. User interfaces should be aesthetically pleasing to users.
Code should be aesthetically pleasing to programmers. What is
considered "good design" is usually subjective, and must be decided
by one's own sense of aesthetics. Even the decision of whether a
variable name or class name is clear and simple is an artistic
question. Donald Knuth asserted that programming is an art.

Performance

The act of writing software requires that developers summon the


energy to find the answers they need while they are at the
keyboard. Creating software is a performance that resembles what
athletes do on the field, and actors and musicians do on stage.
Some argue that SEs need inspiration to spark the creation of code.
Sometimes a creative spark is needed to create the architecture or
to develop a unit of code to solve a particularly intractable
problem. Others argue that discipline is the key attribute. Pair
programming emphasizes this point of view. Both Kent Beck and
Watts Humphrey have argued this emphasis. See also Performance
Engineering.
2. Software Development Life Cycle
(SDLC)
Software Development Life Cycle (SDLC)

What is SDLC? And how it is initiated.

Market Research

A market study is made to identify a potential customer's need. This


process is also known as market research. Here, the already existing
need and the possible/potential needs that are available in a
segment of the society are studied carefully. The market study is
done based on a lot of assumptions. Assumptions are the crucial
factors in the development or inception of a product's development.
Unrealistic assumptions can cause a nosedive in the entire venture.
Though assumptions are abstract, there should be a move to
develop tangible assumptions to come up with a successful product.

Research and Development

Once the Market study is made, the customer's need is given to the
Research and Development (R&D) Department to conceptualize a
cost-effective system that could potentially solve customer's needs
better than the competitors. Once the conceptual system is
developed and tested in a hypothetical environment, the
development team takes control of it. The development team
adopts one of the software development methodologies that is
given below, develops the proposed system, and gives it to the
customers.

The Marketing group starts selling the software to the available


customers and simultaneously works in developing a niche segment
that could potentially buy the software. In addition, the marketing
group passes the feedback from the customers to the developers
and the R&D group to make possible value additions in the product.
While developing a software, the company out sources the non-core
activities to the other companies who specialize in those activities.
This accelerates the software development process largely. Some
companies work on tie-ups to bring out a highly matured product in
a short period.

Following are the basic popular models used by many software


development firms.

1. System Development Life Cycle (SDLC) Model


2. Prototyping Model
3. Rapid Application Development Model
4. Component Assembly Model

This is also known as Classic Life Cycle Model (or) Linear Sequential
Model (or) Waterfall Method. This has the following activities.

1. System/Information Engineering and Modeling


2. Software Requirements Analysis
3. Systems Analysis and Design
4. Code Generation
5. Testing
6. Maintenance

System/Information Engineering and Modeling

As software is always of a large system (or business), work begins by


establishing requirements for all system elements and then
allocating some subset of these requirements to software. This
system view is essential when software must interface with other
elements such as hardware, people and other resources. System is
the basic and very critical requirement for the existence of
software in any entity. So if the system is not in place, the system
should be engineered and put in place. In some cases, to extract
the maximum output, the system should be re-engineered and
spruced up. Once the ideal system is engineered or tuned, the
development team studies the software requirement for the
system.
Software Requirement Analysis

This is also known as feasibility study. In this phase, the


development team visits the customer and studies their system.
They investigate the need for possible software automation in the
given system. By the end of the feasibility study, the team furnishes
a document that holds the different specific recommendations for
the candidate system. It also includes the personnel assignments,
costs, project schedule, and target dates. The requirements
gathering process is intensified and focused specially on software.
To understand the nature of the program(s) to be built, the system
engineer ("analyst") must understand the information domain for
the software, as well as required function, behavior, performance
and interfacing. The essential purpose of this phase is to find the
need and to define the problem that needs to be solved.

System Analysis and Design

In this phase, the software development process, the software's


overall structure and its nuances are defined. In terms of the
client/server technology, the number of tiers needed for the
package architecture, the database design, the data structure
design etc are all defined in this phase. A software development
model is created. Analysis and Design are very crucial in the whole
development cycle. Any glitch in the design phase could be very
expensive to solve in the later stage of the software development.
Much care is taken during this phase. The logical system of the
product is developed in this phase.

Code Generation

The design must be translated into a machine-readable form. The


code generation step performs this task. If the design is performed
in a detailed manner, code generation can be accomplished without
much complication. Programming tools like Compilers, Interpreters,
and Debuggers are used to generate the code. Different high level
programming languages like C, C++, Pascal, and Java are used for
coding. With respect to the type of application, the right
programming language is chosen.
Testing

Once the code is generated, the software program testing begins.


Different testing methodologies are available to unravel the bugs
that were committed during the previous phases. Different testing
tools and methodologies are already available. Some companies
build their own testing tools that are tailor made for their own
development operations.

Maintenance

Software will definitely undergo change once it is delivered to the


customer. There are many reasons for the change. Change could
happen because of some unexpected input values into the system.
In addition, the changes in the system could directly affect the
software operations. The software should be developed to
accommodate changes that could happen during the post
implementation period.
3. System Development Life Cycle Model
(SDLC Models)
Following are the basic popular models used by many software
development firms.

1. Prototyping Model
2. Rapid Application Development Model
3. Component Assembly Model
4. Water fall Model

1. Prototyping Model
This is a cyclic version of the linear model. In this model, once the
requirement analysis is done and the design for a prototype is
made, the development process gets started. Once the prototype is
created, it is given to the customer for evaluation. The customer
tests the package and gives his/her feed back to the developer who
refines the product according to the customer's exact expectation.
After a finite number of iterations, the final software package is
given to the customer. In this methodology, the software is evolved
as a result of periodic shuttling of information between the
customer and developer. This is the most popular development
model in the contemporary IT industry. Most of the successful
software products have been developed using this model - as it is
very difficult (even for a whiz kid!) to comprehend all the
requirements of a customer in one shot. There are many variations
of this model skewed with respect to the project management
styles of the companies. New versions of a software product evolve
as a result of prototyping.
2. Rapid Application Development (RAD) Model
The RAD is a linear sequential software development process that
emphasizes an extremely short development cycle. The RAD
software model is a "high speed" adaptation of the linear sequential
model in which rapid development is achieved by using a
component-based construction approach. Used primarily for
information systems applications, the RAD approach encompasses
the following phases:

Business modeling

The information flow among business functions is modeled in a way


that answers the following questions:

What information drives the business process?


What information is generated?
Who generates it?
Where does the information go?
Who processes it?

Data modeling

The information flow defined as part of the business modeling phase


is refined into a set of data objects that are needed to support the
business. The characteristic (called attributes) of each object is
identified and the relationships between these objects are defined.

Process modeling

The data objects defined in the data-modeling phase are


transformed to achieve the information flow necessary to
implement a business function. Processing the descriptions is
created for adding, modifying, deleting, or retrieving a data object.

Application generation

RAD assumes the use of the RAD tools like VB, VC++, Delphi etc
rather than creating software using conventional third generation
programming languages. The RAD works to reuse existing program
components (when possible) or create reusable components (when
necessary). In all cases, automated tools are used to facilitate
construction of the software.

Testing and turnover

Since the RAD process emphasizes reuse, many of the program


components have already been tested. This minimizes the testing
and development time.

3. Component Assembly Model


Object technologies provide the technical framework for a
component-based process model for software engineering. The
object oriented paradigm emphasizes the creation of classes that
encapsulate both data and the algorithm that are used to
manipulate the data. If properly designed and implemented, object
oriented classes are reusable across different applications and
computer based system architectures. Component Assembly Model
leads to software reusability. The integration/assembly of the
already existing software components accelerate the development
process. Nowadays many component libraries are available on the
Internet. If the right components are chosen, the integration aspect
is made much simpler.

4. Water Fall Model


The waterfall model is a software development model (a process
for the creation of software) in which development is seen as
flowing steadily downwards (like a waterfall) through the phases of
requirements analysis, design, implementation, testing (validation),
integration, and maintenance. The origin of the term "waterfall" is
often cited to be an article published in 1970 by W. W. Royce;
ironically, Royce himself advocated an iterative approach to
software development and did not even use the term "waterfall".
Royce originally described what is now known as the waterfall
model as an example of a method that he argued "is risky and
invites failure".
The Systems Development Life Cycle (SDLC) is a conceptual model
used in project management that describes the stages involved in
an information system development project from an initial
feasibility study through maintenance of the completed application.
Various SDLC methodologies have been developed to guide the
processes involved including the waterfall model (the original SDLC
method), rapid application development (RAD), joint application
development (JAD), the fountain model and the spiral model.
Mostly, several models are combined into some sort of hybrid
methodology. Documentation is crucial regardless of the type of
model chosen or devised for any application, and is usually done in
parallel with the development process. Some methods work better
for specific types of projects, but in the final analysis, the most
important factor for the success of a project may be how closely
particular plan was followed.

The image below is the classic Waterfall model methodology, which


is the first SDLC method and it describes the various phases involved
in development.

Briefly on different Phases:

Feasibility

The feasibility study is used to determine if the project should get


the go-ahead. If the project is to proceed, the feasibility study will
produce a project plan and budget estimates for the future stages
of development.

Requirement Analysis and Design

Analysis gathers the requirements for the system. This stage


includes a detailed study of the business needs of the organization.
Options for changing the business process may be considered.
Design focuses on high level design like, what programs are needed
and how are they going to interact, low-level design (how the
individual programs are going to work), interface design (what are
the interfaces going to look like) and data design (what data will be
required). During these phases, the software's overall structure is
defined. Analysis and Design are very crucial in the whole
development cycle. Any glitch in the design phase could be very
expensive to solve in the later stage of the software development.
Much care is taken during this phase. The logical system of the
product is developed in this phase.

Implementation

In this phase the designs are translated into code. Computer


programs are written using a conventional programming language or
an application generator. Programming tools like Compilers,
Interpreters, and Debuggers are used to generate the code.
Different high level programming languages like C, C++, Pascal, and
Java are used for coding. With respect to the type of application,
the right programming language is chosen.

Testing

In this phase the system is tested. Normally programs are written as


a series of individual modules, these subject to separate and
detailed test. The system is then tested as a whole. The separate
modules are brought together and tested as a complete system. The
system is tested to ensure that interfaces between modules work
(integration testing), the system works on the intended platform
and with the expected volume of data (volume testing) and that the
system does what the user requires (acceptance/beta testing).
Maintenance

Inevitably the system will need maintenance. Software will


definitely undergo change once it is delivered to the customer.
There are many reasons for the change. Change could happen
because of some unexpected input values into the system. In
addition, the changes in the system could directly affect the
software operations. The software should be developed to
accommodate changes that could happen during the post
implementation period.

You might also like