Testing Flashcards

1
Q

What is the primary goal of testing?

A

To reduce the risk of failure that costs money and causes harm.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

What is the formula for testing cost-benefit analysis?

A

Effort in Testing (£) = Reduced Probability × Cost of Failure (£).

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

What does testing reveal?

A

The presence of errors, not their absence.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

What are the two aims of testing?

A

Demonstrate software meets requirements and discover incorrect or undesirable behavior.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

What is a test harness?

A

A collection of software and data for automated testing, including an execution engine and script repository.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

Why use a test harness?

A

To automate test execution, generate reports, and improve productivity and repeatability.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

What is unit testing?

A

Testing individual components in isolation.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

What types of test cases are used in unit testing?

A

Verification (normal operation) and Defect Detection (anomalous inputs).

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

What is Test-Driven Development (TDD)?

A

A development approach where tests are written before code, guiding incremental coding.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

What are TDD benefits?

A

Code coverage, regression testing, simplified debugging, and documentation.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

What is regression testing?

A

Testing to ensure changes do not break existing functionality.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

What are the steps in regression testing?

A

Re-run all tests, ensure they pass, and commit changes only if successful.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

Why is automated testing preferred for regression testing?

A

It is more efficient and faster than manual testing.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

What are emergent properties in system quality?

A

Reliability, scalability, and usability, which are not easily testable with code.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

What causes software bugs?

A

Human errors in design or programming.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

How are software bugs measured?

A

Using software metrics like errors per 1,000 lines of code.

17
Q

What is the cost-quality trade-off triangle?

A

Quality is inversely related to time, cost, and features.

18
Q

Why does testing follow a diminishing returns pattern?

A

The more tests run, the fewer new bugs are found, leading to stopping tests when predicted bugs end.

19
Q

What documentation supports testing?

A

Requirements specification, user manual, design specifications, test plans, and quality assurance documents.

20
Q

What are software inspections?

A

Code and documentation reviews to find defects without executing the system.

21
Q

What is a common form of inspection?

A

Code walkthroughs or pair programming.