Software testing and_quality_assurance_powerpoint_presentation

Preview:

Citation preview

C L I C K

321

M A V

E

R I CS

OF WA

R E

T EST ING

N

Q A I

A

T

Y AS

S

U

R

A

E

D

L T U CN

3

Testing Policy• Only exhaustive testing can show a program is

free from defects. However, exhaustive testing is impossible;

• Testing policies define the approach to be used in selecting system tests; For example,– All functions accessed through menus should

be tested;– Combinations of functions accessed through the

same menu should be tested;– Where user input is required, all functions must

be tested with correct and incorrect input.

Requirements System testing

Architectural Integration Design Testing

Detail Unit Design Testing

Implementation

Software Testing & Development Life Cycle

moduleto betested

Software Engineer

Result

Test Cases

Unit Testing

moduleto betested

Test Cases

InterfaceLocal Data Structures

Unit Testing

Boundary ConditionsIndependent pathsError Handling Paths

DRIVER

MODULE

STUBSTUB

Test Cases

InterfaceLocal Data Structures

Boundary ConditionsIndependent pathsError Handling Paths

Result

Integration Testing Involves building a system from its components and testing it for problems that arise from component interactions.Top-down integration

Develop the skeleton of the system and populate it with components.

Bottom-up integrationIntegrate infrastructure components then add functional components.To simplify error localisation,

systems should be incrementally integrated.

Integration Testing

The Big-bang Approach.

Incremental Approach.

A Stub is a special code arrangement when called by any other module, stimulates the behaviour of an well designed and existing module which is not yet constructed or developed.

What is mean by

stub

Top-Down Integration

Top module is tested with

Stub

Stubs are all Replaced one at a time, Depth first

As new modules are integrated, some subset of tests is re-run

A

B

C

F G

D E

Bottom-Up Integration

A

B F G

Drivers are replaced one at a time, Depth First.

Worker modules are grouped into builds and Integrated

C

D ECluster

Thread-Based Integration

A

B F G

Top Modules are tested with stubs

Worker modules are grouped into builds and Integrated

C

D ECluster

Systems testing

One

• System Functional Test• Test entire system against the functional

requirements.

Two

• System Performance Test• Test the non-functional requirements of the system. For example,• System Performance Test

• Test the non-functional requirements of the system. For example,

Three

• System Acceptance Test• Set of tests that the software must pass before it is

accepted by the client.

Trivial example•You have been asked to write a term paper on ‘Integration Testing in Component Based System’. To do this, you need to find references from a range of library databases.1• You logs on to the KFUPM library system and uses the

search facility to find relevant papers from IEEE, ACM and Elsevier databases. 2

• One paper of special interest requires authentication and you have to fill an online form to receive the paper.• If you are allowed, the paper will be downloaded and

ready for collection.• An email will be send to you once the paper is ready.

3Scenario-based

Testing

Trivial Example-System TestingTest the login mechanism using correct and incorrect login.

Test the search facility using queries against known source to check that the search mechanism is actually documents.

Test system presentation facility to check that information about documents is displayed properly.

Test the mechanism to request permission for downloading.

Test the e-mail response indicating that the download document is available

Regression Testing Change do not always effect the entire

program.

After each change• Entire test suite of a system must be

run again.

Need for an automatic test suite execution.

Test activities

These steps generally remain same from

unit testing to system testing.

Coverage criterion;• Equivalence Partitioning• Boundary-Value Analysis• Coverage-Based Testing• Control-flow• Data-flow

Expected behavior of every test input to be

generated. (Test Oracles)

Testing environment.

Test Case selection

Test Oracles

Text Execution

Test inputs on the ‘program-under-test’

• Record the actual behavior.

Generally can be automated to an

extend !!!!

Test Evaluation

Compare the actual behavior with the expected behavior.

Generally can be automated to an

extend !!!!

Test Reporting

Report the outcome of the testing.• Developers• Project Mangers etc.

Generally can be automated to an

extend !!!!

Key points

Each type of testing is aimed at detecting different kinds of failures

Testing boils down to the selection and execution of test cases.

A system typically undergoes a range of testing types.

Created BySrivignesh

The ability to convert ideas to things is

the secret of

outward success.

Recommended