{[ promptMessage ]}

Bookmark it

{[ promptMessage ]}

Ch4-ISP

# Ch4-ISP - Introduction to Software Testing Chapter 4 Input...

This preview shows pages 1–5. Sign up to view the full content.

1 Introduction to Software Testing Chapter 4 Input Space Partition Testing Paul Ammann & Jeff Offutt http://www cs gmu edu/ offutt/softwaretest http://www.cs.gmu.edu/~offutt/softwaretest/ Ch. 4 : Input Space Coverage Four Structures for Modeling Software Graphs Logic Input Space Syntax Applied to FSMs Source Applied to Applied to © Ammann & Offutt 2 Use cases Specs Design Source DNF Specs Input Models Integ Source Introduction to Software Testing (Ch 4)

This preview has intentionally blurred sections. Sign up to view the full version.

View Full Document
2 Input Domains The input domain to a program contains all the possible inputs to that program For even small programs, the input domain is so large that it might as well be infinite Testing is fundamentally about choosing finite sets of values from the input domain Input parameters define the scope of the input domain Parameters to a method Data read from a file © Ammann & Offutt 3 Global variables User level inputs Domain for each input parameter is partitioned into regions At least one value is chosen from each region Introduction to Software Testing (Ch 4) Benefits of ISP Can be equally applied at several levels of testing Unit Integration System Relatively easy to apply with no automation Easy to adjust the procedure to get more or fewer tests © Ammann & Offutt 4 No implementation knowledge is needed just the input space Introduction to Software Testing (Ch 4)
3 Partitioning Domains Domain D Partition scheme q of D The partition q defines a set of blocks , Bq = b 1 , b 2 , … b Q 1 2 The partition must satisfy two properties : 1. blocks must be pairwise disjoint (no overlap) 2. together the blocks cover the domain D (complete) b b © Ammann & Offutt 5 b i b j = , i j, b i , b j B q 1 2 b 3 b = D b Bq Introduction to Software Testing (Ch 4) Using Partitions – Assumptions Choose a value from each partition Each value is assumed to be equally useful for testing Application to testing Find characteristics in the inputs : parameters, semantic descriptions, … Partition each characteristic Choose tests by combining values from characteristics Example Characteristics Input X is null Order of the input file F (sorted, inverse sorted, arbitrary, …) © Ammann & Offutt 6 Min separation of two aircraft Input device (DVD, CD, VCR, computer, …) Introduction to Software Testing (Ch 4)

This preview has intentionally blurred sections. Sign up to view the full version.

View Full Document
4 Choosing Partitions Choosing (or defining) partitions seems easy, but is easy to get wrong Consider the “ order of file F b 1 = sorted in ascending order b 2 = sorted in descending order b 3 = arbitrary order but … something’s fishy … Solution: Each characteristic should address just one property File F sorted ascending b1 = true © Ammann & Offutt 7 What if the file is of length 1?
This is the end of the preview. Sign up to access the rest of the document.

{[ snackBarMessage ]}

### Page1 / 16

Ch4-ISP - Introduction to Software Testing Chapter 4 Input...

This preview shows document pages 1 - 5. Sign up to view the full document.

View Full Document
Ask a homework question - tutors are online