19
qSize Analysis: An Approach for Estimating Software Testing Size and Effort Vu Nguyen [email protected] m QASymphony

Bug deBug Chennai 2012 Talk - V3 analysis an approach for estimating software testing size and effort by Vu Nguyen

  • View
    1.184

  • Download
    1

Embed Size (px)

DESCRIPTION

Dr. Vu Nguyen is a Director of Software Engineering at QASymphony and a Lecturer at the University of Science, Vietnam National University. At both places, he is involved in developing software tools and performing research in software estimation, testing, maintenance, and process. Quality assurance management is an essential component of the software development lifecycle. To ensure quality, applicability, and usefulness of a product, development teams must spend considerable time and resources testing, which makes the estimation of the software testing effort, a critical activity. In this talk, we present an approach, namely V3 Analysis, to estimating the size of software testing work. The approach measures the size of a software test case based on its checkpoints, preconditions and test data, as well as the types of testing. We also introduce a supporting toolkit that you can use to estimate testing effort quickly for your projects.

Citation preview

Page 1: Bug deBug Chennai 2012 Talk - V3 analysis an approach for estimating software testing size and effort by Vu Nguyen

qSize Analysis: An Approach

for Estimating Software Testing Size and Effort

Vu [email protected]

Page 2: Bug deBug Chennai 2012 Talk - V3 analysis an approach for estimating software testing size and effort by Vu Nguyen

2

Agenda

• Background and Motivation• qSize Analysis

– Test Size Estimation (Test Case Point Analysis)– Test Effort Estimation

• Conclusion

Page 3: Bug deBug Chennai 2012 Talk - V3 analysis an approach for estimating software testing size and effort by Vu Nguyen

3

Background

• Software estimation– process of determining the cost, time, staff, and

other related attributes of software projects• It is important for the success or failure of

software projects• Methods and Metrics

– Source Lines of Code (SLOC)– Function Points– COCOMO – Expert Judgment

Page 4: Bug deBug Chennai 2012 Talk - V3 analysis an approach for estimating software testing size and effort by Vu Nguyen

4

Motivation

• Testing accounts for up to 50% of project effort [1]

• Current problems– lack of reliable methods designed for estimating

size and effort of software testing– vague definitions of testing productivity

• Our aim is to introduce– a method for estimating the size and effort of

testing activities– a simple toolkit for this estimation process

Page 5: Bug deBug Chennai 2012 Talk - V3 analysis an approach for estimating software testing size and effort by Vu Nguyen

5

Agenda

• Background and Motivation• qSize Analysis

– Test Size Estimation (Test Case Point Analysis)– Test Effort Estimation

• Conclusion

Page 6: Bug deBug Chennai 2012 Talk - V3 analysis an approach for estimating software testing size and effort by Vu Nguyen

6

qSize Analysis’ Principles

• Size measures the mass and complexity of each test cycle of a testing project

• Test case’s complexity is based on– Number of checkpoints– Complexity of test setup or precondition– Complexity of test data

• Test Case Point (TCP) is used as size unit• Calibration or model refinement is key to estimating

effort– calibration based on feedback from previous testing

cycles• Focusing on independent testing (V & V)

Page 7: Bug deBug Chennai 2012 Talk - V3 analysis an approach for estimating software testing size and effort by Vu Nguyen

7

Test Case

qSize Analysis’ Process

Test CaseCount TCPs of all Test

Cases

Estimate Testing Effort

Parameters

Counted Size

Estimated Effort

[Test Cycle i]

Test Cycle Size Actual Effort

Effort by Activity

…. …. …. ….

Test cycle i …. …. ….

…. …. …. ….

Historical Data of this Project

Update Historical

Data

Calibrate Estimation

Model

Page 8: Bug deBug Chennai 2012 Talk - V3 analysis an approach for estimating software testing size and effort by Vu Nguyen

8

Count Size of Test Cycle

• Size of a test cycle is the total of TCPs of all test cases to be executed in that test cycle

• Steps:

Test Case

Count Checkpoints

Determine Set Up Complexity

Determine Test Data

Complexity

Adjust based on Test Type

(optional)

Unadjusted TCPs

TCPs

Page 9: Bug deBug Chennai 2012 Talk - V3 analysis an approach for estimating software testing size and effort by Vu Nguyen

9

Count Size of Test Cycle (cont’d)

• Checkpoints– Checkpoint is the condition in which the tester

verifies whether the result produced by the target function matches the expected criterion

– One test case consists of one or many checkpoints

One checkpoint is counted as one TCP

Page 10: Bug deBug Chennai 2012 Talk - V3 analysis an approach for estimating software testing size and effort by Vu Nguyen

10

Count Size of Test Cycle (cont’d)

• Test Setup or Precondition– Test setup specifies the condition to execute the

test case – Four levels of Test Setup complexity

• Each is assigned a number of TCPsNumber of TCP(*)

Complexity Level

Description

0 None • The set up is not applicable or important to execute the test case • Or, the set up is just reused from the previous test case to continue the current test case

1 Low • The condition for executing the test case is available with some simple modifications required• Or, some simple set-up steps are needed

3 Medium • Some explicit preparation is needed to execute the test case • Or, The condition for executing is available with some additional modifications required • Or, some additional set-up steps are needed

5 High • Heavy hardware and/or software configurations are needed to execute the test case

Page 11: Bug deBug Chennai 2012 Talk - V3 analysis an approach for estimating software testing size and effort by Vu Nguyen

Count Size of Test Cycle (cont’d)• Test Data

– Test Data is used to execute the test case– Four levels of Test Data complexity

• Each is assigned a number of TCPsNumber

of TCP (*)Complexity

LevelDescription

0 None • No test data preparation is needed

1 Low • Simple test data is needed and can be created during the test case execution time• Or, the test case uses a slightly modified version of existing test data and requires little

or no effort to modify the test data

3 Medium • Test data is deliberately prepared in advance with extra effort to ensure its completeness, comprehensiveness, and consistency

6 High • Test data is prepared in advance with considerable effort to ensure its completeness, comprehensiveness, and consistency

• This could include using support tools to generate data and a database to store and manage test data

• Scripts may be required to generate test data

(*) based on our survey of 18 senior QA engineers. You can adjust according to your project’s experience.

Page 12: Bug deBug Chennai 2012 Talk - V3 analysis an approach for estimating software testing size and effort by Vu Nguyen

12

Count Size of Test Cycle (cont’d)• Adjust TCPs based on Type of Test

– This is an OPTIONAL step– Adjustment is based on types of test cases

• Each type of test case is assigned a weight• Adjusted TCP = Counted TCP x Weight(*)

Page 13: Bug deBug Chennai 2012 Talk - V3 analysis an approach for estimating software testing size and effort by Vu Nguyen

13

Estimate Effort of Test Cycle• Overview

– Two estimation methods• Based on Test Velocity• Regression analysis of Size and Effort of

completed test cycles– Effort distributed by activity

• Test Planning• Test Analysis and Design• Test Execution• Test Tracking and Reporting

Each may be performed multiple times

Page 14: Bug deBug Chennai 2012 Talk - V3 analysis an approach for estimating software testing size and effort by Vu Nguyen

14

Estimate Effort of Test Cycle (cont’d)

• Estimate Effort based on Test Velocity

Effort = Size / Test Velocity

– Test Velocity is measured as TCP/person-hour• dependent on project• calculated based on data from completed test

cycles of the same project

Page 15: Bug deBug Chennai 2012 Talk - V3 analysis an approach for estimating software testing size and effort by Vu Nguyen

15

Estimate Effort of Test Cycle (cont’d)

• Estimate effort using Linear Regression Analysis– Find out the equation of effort and size using

similar completed test cycles of a project

0 100 200 300 400 500 600 700 800 900 1000

0

10

20

30

40

50

60

70

80

90

100

f(x) = 0.0728501072514328 x + 1.64076780728634

Adjusted TCP

Eff

ort

(P

M)

Equation of Size and Effort

Page 16: Bug deBug Chennai 2012 Talk - V3 analysis an approach for estimating software testing size and effort by Vu Nguyen

16

Calibrate the qSize Estimation Model

• Calibration: a process adjusting parameters for a model using historical data or experiences

• With qSize Estimation model, you can calibrate:(1) TCP for to each complexity level of Test Setup(2) TCP for to each complexity level of Test Data(3) Test Velocity(4) Effort distribution(5) Weights of test case types

• Process can be done with the help of tools

Tool Demo

Page 17: Bug deBug Chennai 2012 Talk - V3 analysis an approach for estimating software testing size and effort by Vu Nguyen

17

Conclusion

• qSize Analysis is an agile approach to estimating size and effort of test cycle– Estimate Size in TCP– Estimate Effort using Test Velocity or Regression– An Excel toolkit to simplify the approach

• Advantages and experiences learned– Easy to implement– Independent with the level of details of test cases– Found useful

• Limitations and future improvements– A new approach– Need more empirical validations

Page 18: Bug deBug Chennai 2012 Talk - V3 analysis an approach for estimating software testing size and effort by Vu Nguyen

Thank You

Page 19: Bug deBug Chennai 2012 Talk - V3 analysis an approach for estimating software testing size and effort by Vu Nguyen

References

• [1] Y. Yang, Q. Li, M. Li, Q. Wang, An empirical analysis on distribution patterns of software maintenance effort, International Conference on Software Maintenance, 2008, pp. 456-459

• [2] N. Patel, M. Govindrajan, S. Maharana, S. Ramdas, “Test Case Point Analysis”, Cognizant Technology Solutions, White Paper, 2001

• [3] QASymphony: www.qasymphony.com