Lecture1-Intro to software testing Flashcards

1
Q

Why do we do software testing?

A

Software failures are costly and testing can help prevent these failures.

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

What is the process of testing(4)?

A

Test Planning –> Test development–>Running test cases–>Evaluating test results

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

Failure vs fault vs error

A

Error:
-A mistake usually made by PEOPLE.cause of a fault
Fault:
-The result of an error(BUG)
Failure:
-Occurs when the code corresponding to a fault executes. Observable incorrect behaviour of a program.

ERROR –>CAN LEAD TO –>FAULT –>CAN LEAD TO –>FAILURE

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

What are the 3 levels of software testing?

A

1.Unit testing
2.Integration testing
3.System testing

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

What is unit testing?

A

-Individual units(a function) are tested in isolation.
-Determine whether each unit functions as designed.

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

What is integration testing?

A

-Test a group of related units together(testing database access)
-Find interface issues between units

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

What is system testing?

A

-Test the complete software system
-Evaluate the system’s compliance with the specified requirements.

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

What are the 2 basic approaches to identify test cases?

A

1.Black-box testing
2.White-box testing

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

What is black-box testing?

A

-based on software description(specification)
-covers as much SPECIFIED behaviour as possible
-cannot reveal errors due to implementation details.

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

What is white-box testing?

A

-based on the code
-covers as much CODED behaviour as possible
-cannot reveal errors due to missing paths

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

What are the 4 QA approaches?

A

-Testing
-Static verification
-Inspection /review
-Formal proof

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

Which QA approach has the most subjective bias?

A

Inspection/ review

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

What does the testing approach consist of and what are its pros and cons (1 of each) ?

A

Exercising software to try and generate failures.
Pros: no false positives
Cons: incomplete

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

What does the static verification approach consist of and what are its pros(1) and cons (2) ?

A

Identify specific problems statically considering all possible executions.
Pros: complete
Cons: false positive(main issue),expensive

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

What does the inspection/review approach consist of and what are its pros(2) and cons (2) ?

A

Systematic group review of program text to detect faults.
Pros: systematic, thorough
Cons: informal, subjective

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

What does the formal proof approach consist of and what are its pros (1)and cons (2) ?

A

Proving that the program text implements the program specification.
Pros: strong guarantees
Cons: complex, expensive (requires a specification)

17
Q

What is correctness?

A

-Do the specification and the program meet the customer/user’s expectations?
-Program P is correct with respect to specification S

*Test can never reveal the absence of a bug(fault).
*We run the program by running the code.

18
Q

What is validation ?

A

Process of evaluating software at the end of software development to ensure compliance with intended usage. => DO THE RIGHT THINGS

19
Q

What is verification?

A

The process of determining whether the products of a given phase of the software development process fulfill the requirements established during the previous phase=>DO THE THINGS RIGHT

20
Q

What is an example of validation vs verification?

A

Divide 2 numbers :

Validation : Does it divide ?
Verification: Is the division correct?

21
Q

Describe this process : Testing–>Test Failure–>Debugging

A

Testing: Evaluating software by observing its execution.
Test failure: Execution that results in a failure.
Debugging: The process of finding a fault given a failure.

22
Q

What are the three conditions that must be present for a failure to be observed (RIP)?

A

REACHABILITY : The location that contain the fault must be reached.
INFECTION: After executing the location, state of the program must be incorrect.
PROPAGATION:The infected state must propagate to cause some output of the program to be incorrect.

*Failure is a result of fault, but not all faults are a result of failure

23
Q

What is the content of a test case?(6)

A

-Summary
-Pre-conditions
-Inputs
-Expected outputs
-Observed outputs
-Pass/fail

24
Q

What is complete testing?

A

At the end of testing, you know there are no remaining unknown bugs.

25
Q

Why is complete coverage impossible?

A

-Domain of possible inputs is too large.
-Too many possible paths through the program.

26
Q

Bonus question : What do we categorize testing inheritance as (what level of testing, what approach) ?

A

Integration, white box