Chapter 3 - Unit and Integration Testing

0.0(0)
Studied by 0 people
call kaiCall Kai
learnLearn
examPractice Test
spaced repetitionSpaced Repetition
heart puzzleMatch
flashcardsFlashcards
GameKnowt Play
Card Sorting

1/32

flashcard set

Earn XP

Description and Tags

33 Terms

1
New cards

Four Levels of Testing

1) Component (Unit) Testing, 2) Integration Testing, 3) System Testing, 4) Acceptance Testing.

2
New cards

Component (Unit) Testing

Testing of individual software programs, procedures, or components as they are written.

3
New cards

Integration Testing

Testing interfaces between modules to ensure they communicate and operate together as expected.

4
New cards

System Testing

Testing of completely integrated groups of programs / the entire system against specified requirements.

5
New cards

Acceptance Testing

Testing to verify system readiness for operational implementation or customer use.

6
New cards

Who performs Component Testing?

Usually performed by the programmer who wrote the code.

7
New cards

Objectives of Component Testing

1) Verify CSU satisfies requirements, 2) Verify algorithms are correct, 3) Verify internal structures and interfaces match design.

8
New cards

Informality of Component Testing

Often informal/ad-hoc; testing ends when the programmer 'feels comfortable' and fixes known deficiencies.

9
New cards

Stopping Criteria in Component Testing

Pre-defined criteria that specify when unit testing is officially complete.

10
New cards

Functional Testing (Black-Box)

Testing that software functions operate, inputs are accepted, and outputs are correct without using knowledge of internal program code.

11
New cards

Categories of Errors Found by Black-Box Testing

Incorrect/missing functions, interface errors, data structure/database access errors, performance errors, and initialization/termination errors.

12
New cards

Sources of Expected Results in Functional Testing

Algorithms from design documents, step-by-step code walkthroughs, or former equivalent software components.

13
New cards

Equivalence Partitioning (EP)

A black-box method that divides inputs into equivalence classes so that testing one representative value tests all values in that class.

14
New cards

Sampling Method

Similar to Equivalence Partitioning but more thorough; selects a certain number of multiple values within each class (avoiding random/non-reproducible values).

15
New cards

Boundary Value Analysis (BVA)

A refinement of EP that selects test cases at the extreme edges (boundaries) of equivalence classes (e.g., 0/1 and 10/11 for range 1..10).

16
New cards

Robustness Testing

Testing the outer bounds of equivalence classes with abnormal or invalid inputs (e.g., ESC key, invalid types) to ensure no catastrophic crashes occur.

17
New cards

Cause-Effect Graphing

A formal black-box technique representing specifications as a digital logic network (combinatorial circuit) to explore combinations of inputs and identify ambiguities.

18
New cards

Cause vs. Effect (in Graphing)

Cause = distinct input condition or equivalence class; Effect = output condition or system state transformation.

19
New cards

Cause-Effect Graphing Workflow

1) Identify causes & effects in spec, 2) Draw cause-effect graph, 3) Convert graph into a Decision Table, 4) Convert table columns into test cases.

20
New cards

Test Harness / Test Environment

Special supporting code (Drivers and Stubs) developed to execute and isolate a unit test.

21
New cards

Stub (Definition)

A dummy subprogram that replaces a module subordinate to (called by) the module under test, simulating its behavior or returning constant values.

22
New cards

Driver (Definition)

A 'main' calling procedure that accepts test inputs, calls the module under test, and receives/evaluates output results.

23
New cards

Structural Testing (White-Box)

Examining internal logic structures, control paths, conditions, loops, and data structures of a software unit.

24
New cards

Objectives of White-Box Testing

Guarantee all independent paths are exercised at least once, test true/false sides of all decisions, and execute loops within and at boundaries.

25
New cards

Flow Graph Components

Edges (arrows = flow of control), Nodes (circles = actions/statements), Regions (areas bounded by edges & nodes), Predicate Nodes (nodes with conditions/branching).

26
New cards

Predicate Node

A flow graph node containing a condition that has two or more outgoing edges.

27
New cards

Cyclomatic Complexity V(G) Formulas

1) V(G) = Edges - Nodes + 2, 2) V(G) = Predicate Nodes + 1, 3) V(G) = Regions + 1.

28
New cards

Meaning of Cyclomatic Number V(G)

Indicates the minimum number of independent execution paths that must be tested within a module.

29
New cards

Instruction Block (IB) Testing

A set of sequential instructions where running the first executes all; IB testing requires executing every instruction block at least once.

30
New cards

Decision-to-Decision Path (DDP) Testing

Begins at program start or a decision node and ends at program end or the next decision node; encompasses IB testing and requires executing all branches at least once.

31
New cards

Key Aspects of Integration Testing

1) Testing interfaces between software modules, 2) Testing the interface between the integrated assembly and its external environment.

32
New cards

Execution Mode of Integration Testing

Involves testing modules in executable combinations (e.g., compiled .exe assemblies) rather than isolated units.

33
New cards