Skip to main content
CBE Nexus · Undergraduate Software Engineering

Chapter 8: Software Testing, Verification and Quality Assurance

Test design, unit and integration testing, automation, coverage, static analysis, reliability and quality management.

Course catalogue

Home › Software Engineering › Chapter 8

Learning outcomes

After studying this chapter, learners should be able to explain the core concepts, analyse a realistic engineering problem, select and justify an appropriate method, communicate a design clearly, identify risks, and verify the resulting work against explicit criteria.

Study method: Read each topic, reproduce the diagrams from memory, complete the practical activity, answer the revision questions before checking guidance, and maintain a glossary of unfamiliar technical terms.

Diagram 1. Engineering reasoning cycle
Problem & context→Requirements→Design→Implementation→Evidence & review

Feedback from testing and operation returns to requirements and design; the process is iterative rather than a one-way sequence.

1. Quality concepts and verification versus validation

Quality concepts and verification versus validation is a core engineering concern because software systems must satisfy stakeholder needs while remaining understandable, testable and operable. Begin by stating the problem, the system boundary and the assumptions that shape the solution. Identify the people and services that interact with the system, the information they exchange, and the consequences of incorrect or delayed behaviour. A sound engineering decision is not simply a fashionable technology choice: it is a reasoned response to constraints, evidence and quality objectives.

In practice, document the decision before implementation. Record the alternatives considered, the advantages and limitations of each, and the reason the selected approach fits the context. Translate the decision into observable behaviour, interface contracts and acceptance criteria. Keep responsibilities cohesive, minimize unnecessary coupling, and define how errors, exceptional conditions and changes will be handled. Review the design with another developer and use a small experiment or prototype where uncertainty is high.

For a worked example, imagine a university learning portal serving students, lecturers and administrators. Trace one user task from the interface through the application logic to persistent data and operational monitoring. Identify validation points, permissions, expected responses and recovery behaviour. Then consider how the same design behaves when a user submits incomplete information, a dependency becomes unavailable, or demand rises sharply. This scenario turns abstract terminology into engineering decisions that can be inspected and tested.

Engineering check: Can another team member explain the purpose, inputs, outputs, dependencies, failure behaviour and verification method without relying on undocumented assumptions? If not, improve the specification and supporting evidence.

2. Test levels, test types and test strategy

Test levels, test types and test strategy is a core engineering concern because software systems must satisfy stakeholder needs while remaining understandable, testable and operable. Begin by stating the problem, the system boundary and the assumptions that shape the solution. Identify the people and services that interact with the system, the information they exchange, and the consequences of incorrect or delayed behaviour. A sound engineering decision is not simply a fashionable technology choice: it is a reasoned response to constraints, evidence and quality objectives.

In practice, document the decision before implementation. Record the alternatives considered, the advantages and limitations of each, and the reason the selected approach fits the context. Translate the decision into observable behaviour, interface contracts and acceptance criteria. Keep responsibilities cohesive, minimize unnecessary coupling, and define how errors, exceptional conditions and changes will be handled. Review the design with another developer and use a small experiment or prototype where uncertainty is high.

For a worked example, imagine a university learning portal serving students, lecturers and administrators. Trace one user task from the interface through the application logic to persistent data and operational monitoring. Identify validation points, permissions, expected responses and recovery behaviour. Then consider how the same design behaves when a user submits incomplete information, a dependency becomes unavailable, or demand rises sharply. This scenario turns abstract terminology into engineering decisions that can be inspected and tested.

Engineering check: Can another team member explain the purpose, inputs, outputs, dependencies, failure behaviour and verification method without relying on undocumented assumptions? If not, improve the specification and supporting evidence.

3. Requirements traceability and acceptance criteria

Requirements traceability and acceptance criteria is a core engineering concern because software systems must satisfy stakeholder needs while remaining understandable, testable and operable. Begin by stating the problem, the system boundary and the assumptions that shape the solution. Identify the people and services that interact with the system, the information they exchange, and the consequences of incorrect or delayed behaviour. A sound engineering decision is not simply a fashionable technology choice: it is a reasoned response to constraints, evidence and quality objectives.

In practice, document the decision before implementation. Record the alternatives considered, the advantages and limitations of each, and the reason the selected approach fits the context. Translate the decision into observable behaviour, interface contracts and acceptance criteria. Keep responsibilities cohesive, minimize unnecessary coupling, and define how errors, exceptional conditions and changes will be handled. Review the design with another developer and use a small experiment or prototype where uncertainty is high.

For a worked example, imagine a university learning portal serving students, lecturers and administrators. Trace one user task from the interface through the application logic to persistent data and operational monitoring. Identify validation points, permissions, expected responses and recovery behaviour. Then consider how the same design behaves when a user submits incomplete information, a dependency becomes unavailable, or demand rises sharply. This scenario turns abstract terminology into engineering decisions that can be inspected and tested.

Engineering check: Can another team member explain the purpose, inputs, outputs, dependencies, failure behaviour and verification method without relying on undocumented assumptions? If not, improve the specification and supporting evidence.

4. Equivalence partitioning and boundary analysis

Equivalence partitioning and boundary analysis is a core engineering concern because software systems must satisfy stakeholder needs while remaining understandable, testable and operable. Begin by stating the problem, the system boundary and the assumptions that shape the solution. Identify the people and services that interact with the system, the information they exchange, and the consequences of incorrect or delayed behaviour. A sound engineering decision is not simply a fashionable technology choice: it is a reasoned response to constraints, evidence and quality objectives.

In practice, document the decision before implementation. Record the alternatives considered, the advantages and limitations of each, and the reason the selected approach fits the context. Translate the decision into observable behaviour, interface contracts and acceptance criteria. Keep responsibilities cohesive, minimize unnecessary coupling, and define how errors, exceptional conditions and changes will be handled. Review the design with another developer and use a small experiment or prototype where uncertainty is high.

For a worked example, imagine a university learning portal serving students, lecturers and administrators. Trace one user task from the interface through the application logic to persistent data and operational monitoring. Identify validation points, permissions, expected responses and recovery behaviour. Then consider how the same design behaves when a user submits incomplete information, a dependency becomes unavailable, or demand rises sharply. This scenario turns abstract terminology into engineering decisions that can be inspected and tested.

Engineering check: Can another team member explain the purpose, inputs, outputs, dependencies, failure behaviour and verification method without relying on undocumented assumptions? If not, improve the specification and supporting evidence.

5. Decision tables, state transitions and pairwise tests

Decision tables, state transitions and pairwise tests is a core engineering concern because software systems must satisfy stakeholder needs while remaining understandable, testable and operable. Begin by stating the problem, the system boundary and the assumptions that shape the solution. Identify the people and services that interact with the system, the information they exchange, and the consequences of incorrect or delayed behaviour. A sound engineering decision is not simply a fashionable technology choice: it is a reasoned response to constraints, evidence and quality objectives.

In practice, document the decision before implementation. Record the alternatives considered, the advantages and limitations of each, and the reason the selected approach fits the context. Translate the decision into observable behaviour, interface contracts and acceptance criteria. Keep responsibilities cohesive, minimize unnecessary coupling, and define how errors, exceptional conditions and changes will be handled. Review the design with another developer and use a small experiment or prototype where uncertainty is high.

For a worked example, imagine a university learning portal serving students, lecturers and administrators. Trace one user task from the interface through the application logic to persistent data and operational monitoring. Identify validation points, permissions, expected responses and recovery behaviour. Then consider how the same design behaves when a user submits incomplete information, a dependency becomes unavailable, or demand rises sharply. This scenario turns abstract terminology into engineering decisions that can be inspected and tested.

Engineering check: Can another team member explain the purpose, inputs, outputs, dependencies, failure behaviour and verification method without relying on undocumented assumptions? If not, improve the specification and supporting evidence.

6. Unit testing and test doubles

Unit testing and test doubles is a core engineering concern because software systems must satisfy stakeholder needs while remaining understandable, testable and operable. Begin by stating the problem, the system boundary and the assumptions that shape the solution. Identify the people and services that interact with the system, the information they exchange, and the consequences of incorrect or delayed behaviour. A sound engineering decision is not simply a fashionable technology choice: it is a reasoned response to constraints, evidence and quality objectives.

In practice, document the decision before implementation. Record the alternatives considered, the advantages and limitations of each, and the reason the selected approach fits the context. Translate the decision into observable behaviour, interface contracts and acceptance criteria. Keep responsibilities cohesive, minimize unnecessary coupling, and define how errors, exceptional conditions and changes will be handled. Review the design with another developer and use a small experiment or prototype where uncertainty is high.

For a worked example, imagine a university learning portal serving students, lecturers and administrators. Trace one user task from the interface through the application logic to persistent data and operational monitoring. Identify validation points, permissions, expected responses and recovery behaviour. Then consider how the same design behaves when a user submits incomplete information, a dependency becomes unavailable, or demand rises sharply. This scenario turns abstract terminology into engineering decisions that can be inspected and tested.

Engineering check: Can another team member explain the purpose, inputs, outputs, dependencies, failure behaviour and verification method without relying on undocumented assumptions? If not, improve the specification and supporting evidence.

7. Integration, contract and component testing

Integration, contract and component testing is a core engineering concern because software systems must satisfy stakeholder needs while remaining understandable, testable and operable. Begin by stating the problem, the system boundary and the assumptions that shape the solution. Identify the people and services that interact with the system, the information they exchange, and the consequences of incorrect or delayed behaviour. A sound engineering decision is not simply a fashionable technology choice: it is a reasoned response to constraints, evidence and quality objectives.

In practice, document the decision before implementation. Record the alternatives considered, the advantages and limitations of each, and the reason the selected approach fits the context. Translate the decision into observable behaviour, interface contracts and acceptance criteria. Keep responsibilities cohesive, minimize unnecessary coupling, and define how errors, exceptional conditions and changes will be handled. Review the design with another developer and use a small experiment or prototype where uncertainty is high.

For a worked example, imagine a university learning portal serving students, lecturers and administrators. Trace one user task from the interface through the application logic to persistent data and operational monitoring. Identify validation points, permissions, expected responses and recovery behaviour. Then consider how the same design behaves when a user submits incomplete information, a dependency becomes unavailable, or demand rises sharply. This scenario turns abstract terminology into engineering decisions that can be inspected and tested.

Engineering check: Can another team member explain the purpose, inputs, outputs, dependencies, failure behaviour and verification method without relying on undocumented assumptions? If not, improve the specification and supporting evidence.

8. System, end-to-end and acceptance testing

System, end-to-end and acceptance testing is a core engineering concern because software systems must satisfy stakeholder needs while remaining understandable, testable and operable. Begin by stating the problem, the system boundary and the assumptions that shape the solution. Identify the people and services that interact with the system, the information they exchange, and the consequences of incorrect or delayed behaviour. A sound engineering decision is not simply a fashionable technology choice: it is a reasoned response to constraints, evidence and quality objectives.

In practice, document the decision before implementation. Record the alternatives considered, the advantages and limitations of each, and the reason the selected approach fits the context. Translate the decision into observable behaviour, interface contracts and acceptance criteria. Keep responsibilities cohesive, minimize unnecessary coupling, and define how errors, exceptional conditions and changes will be handled. Review the design with another developer and use a small experiment or prototype where uncertainty is high.

For a worked example, imagine a university learning portal serving students, lecturers and administrators. Trace one user task from the interface through the application logic to persistent data and operational monitoring. Identify validation points, permissions, expected responses and recovery behaviour. Then consider how the same design behaves when a user submits incomplete information, a dependency becomes unavailable, or demand rises sharply. This scenario turns abstract terminology into engineering decisions that can be inspected and tested.

Engineering check: Can another team member explain the purpose, inputs, outputs, dependencies, failure behaviour and verification method without relying on undocumented assumptions? If not, improve the specification and supporting evidence.

9. Regression testing and risk-based prioritization

Regression testing and risk-based prioritization is a core engineering concern because software systems must satisfy stakeholder needs while remaining understandable, testable and operable. Begin by stating the problem, the system boundary and the assumptions that shape the solution. Identify the people and services that interact with the system, the information they exchange, and the consequences of incorrect or delayed behaviour. A sound engineering decision is not simply a fashionable technology choice: it is a reasoned response to constraints, evidence and quality objectives.

In practice, document the decision before implementation. Record the alternatives considered, the advantages and limitations of each, and the reason the selected approach fits the context. Translate the decision into observable behaviour, interface contracts and acceptance criteria. Keep responsibilities cohesive, minimize unnecessary coupling, and define how errors, exceptional conditions and changes will be handled. Review the design with another developer and use a small experiment or prototype where uncertainty is high.

For a worked example, imagine a university learning portal serving students, lecturers and administrators. Trace one user task from the interface through the application logic to persistent data and operational monitoring. Identify validation points, permissions, expected responses and recovery behaviour. Then consider how the same design behaves when a user submits incomplete information, a dependency becomes unavailable, or demand rises sharply. This scenario turns abstract terminology into engineering decisions that can be inspected and tested.

Engineering check: Can another team member explain the purpose, inputs, outputs, dependencies, failure behaviour and verification method without relying on undocumented assumptions? If not, improve the specification and supporting evidence.

10. Automation frameworks and maintainable test suites

Automation frameworks and maintainable test suites is a core engineering concern because software systems must satisfy stakeholder needs while remaining understandable, testable and operable. Begin by stating the problem, the system boundary and the assumptions that shape the solution. Identify the people and services that interact with the system, the information they exchange, and the consequences of incorrect or delayed behaviour. A sound engineering decision is not simply a fashionable technology choice: it is a reasoned response to constraints, evidence and quality objectives.

In practice, document the decision before implementation. Record the alternatives considered, the advantages and limitations of each, and the reason the selected approach fits the context. Translate the decision into observable behaviour, interface contracts and acceptance criteria. Keep responsibilities cohesive, minimize unnecessary coupling, and define how errors, exceptional conditions and changes will be handled. Review the design with another developer and use a small experiment or prototype where uncertainty is high.

For a worked example, imagine a university learning portal serving students, lecturers and administrators. Trace one user task from the interface through the application logic to persistent data and operational monitoring. Identify validation points, permissions, expected responses and recovery behaviour. Then consider how the same design behaves when a user submits incomplete information, a dependency becomes unavailable, or demand rises sharply. This scenario turns abstract terminology into engineering decisions that can be inspected and tested.

Engineering check: Can another team member explain the purpose, inputs, outputs, dependencies, failure behaviour and verification method without relying on undocumented assumptions? If not, improve the specification and supporting evidence.

11. Static analysis, code review and coverage

Static analysis, code review and coverage is a core engineering concern because software systems must satisfy stakeholder needs while remaining understandable, testable and operable. Begin by stating the problem, the system boundary and the assumptions that shape the solution. Identify the people and services that interact with the system, the information they exchange, and the consequences of incorrect or delayed behaviour. A sound engineering decision is not simply a fashionable technology choice: it is a reasoned response to constraints, evidence and quality objectives.

In practice, document the decision before implementation. Record the alternatives considered, the advantages and limitations of each, and the reason the selected approach fits the context. Translate the decision into observable behaviour, interface contracts and acceptance criteria. Keep responsibilities cohesive, minimize unnecessary coupling, and define how errors, exceptional conditions and changes will be handled. Review the design with another developer and use a small experiment or prototype where uncertainty is high.

For a worked example, imagine a university learning portal serving students, lecturers and administrators. Trace one user task from the interface through the application logic to persistent data and operational monitoring. Identify validation points, permissions, expected responses and recovery behaviour. Then consider how the same design behaves when a user submits incomplete information, a dependency becomes unavailable, or demand rises sharply. This scenario turns abstract terminology into engineering decisions that can be inspected and tested.

Engineering check: Can another team member explain the purpose, inputs, outputs, dependencies, failure behaviour and verification method without relying on undocumented assumptions? If not, improve the specification and supporting evidence.

12. Defect management, reliability and quality metrics

Defect management, reliability and quality metrics is a core engineering concern because software systems must satisfy stakeholder needs while remaining understandable, testable and operable. Begin by stating the problem, the system boundary and the assumptions that shape the solution. Identify the people and services that interact with the system, the information they exchange, and the consequences of incorrect or delayed behaviour. A sound engineering decision is not simply a fashionable technology choice: it is a reasoned response to constraints, evidence and quality objectives.

In practice, document the decision before implementation. Record the alternatives considered, the advantages and limitations of each, and the reason the selected approach fits the context. Translate the decision into observable behaviour, interface contracts and acceptance criteria. Keep responsibilities cohesive, minimize unnecessary coupling, and define how errors, exceptional conditions and changes will be handled. Review the design with another developer and use a small experiment or prototype where uncertainty is high.

For a worked example, imagine a university learning portal serving students, lecturers and administrators. Trace one user task from the interface through the application logic to persistent data and operational monitoring. Identify validation points, permissions, expected responses and recovery behaviour. Then consider how the same design behaves when a user submits incomplete information, a dependency becomes unavailable, or demand rises sharply. This scenario turns abstract terminology into engineering decisions that can be inspected and tested.

Engineering check: Can another team member explain the purpose, inputs, outputs, dependencies, failure behaviour and verification method without relying on undocumented assumptions? If not, improve the specification and supporting evidence.

Diagram 2. Traceability from need to evidence
Stakeholder need→Requirement→Design element→Test case→Result

Traceability helps teams demonstrate that important needs have been implemented and verified.

Practical laboratory / applied project

Work in a small team to design a modest feature for a campus learning portal. Produce a one-page problem statement, stakeholder list, system context diagram, concise requirements, a design sketch, a risk register and a test plan. Implement a small demonstrator or prototype where appropriate. Use version control, record meaningful commits, request peer review and keep evidence of decisions.

Submission evidence: problem statement; assumptions; diagram; decision log; prototype or pseudocode; test cases and results; short reflection. Your assessor should be able to trace each major requirement to a design decision and a verification activity.

Assessment rubric (100 marks): problem analysis 15; technical accuracy 20; design quality 20; implementation or prototype 15; testing and evidence 15; communication and reflection 10; collaboration and version-control practice 5.

Diagram 3. Continuous improvement loop
Plan→Build→Verify→Release→Observe↺

Revision questions and answer guidance

  1. 1. Define the central purpose of this chapter and distinguish it from the adjacent discipline.

    Answer guidance: Define terms precisely, use a relevant example, explain the reasoning, and state assumptions or limitations.

  2. 2. Explain the main concepts using a realistic software product example.

    Answer guidance: Define terms precisely, use a relevant example, explain the reasoning, and state assumptions or limitations.

  3. 3. Draw and label a suitable architecture, process or data-flow diagram.

    Answer guidance: Define terms precisely, use a relevant example, explain the reasoning, and state assumptions or limitations.

  4. 4. Compare two approaches and state the conditions under which each is appropriate.

    Answer guidance: Define terms precisely, use a relevant example, explain the reasoning, and state assumptions or limitations.

  5. 5. Identify assumptions that should be documented before implementation.

    Answer guidance: Define terms precisely, use a relevant example, explain the reasoning, and state assumptions or limitations.

  6. 6. Describe a failure mode and explain how an engineer would detect it.

    Answer guidance: Define terms precisely, use a relevant example, explain the reasoning, and state assumptions or limitations.

  7. 7. Propose a test or validation method for the most important requirement.

    Answer guidance: Define terms precisely, use a relevant example, explain the reasoning, and state assumptions or limitations.

  8. 8. Explain the security, privacy or ethical implications of the design.

    Answer guidance: Define terms precisely, use a relevant example, explain the reasoning, and state assumptions or limitations.

  9. 9. Interpret a small set of technical evidence such as a query plan, test result or metric.

    Answer guidance: Define terms precisely, use a relevant example, explain the reasoning, and state assumptions or limitations.

  10. 10. Recommend a maintainability improvement and justify its likely benefit.

    Answer guidance: Define terms precisely, use a relevant example, explain the reasoning, and state assumptions or limitations.

  11. 11. Describe how the design should change when scale or workload increases.

    Answer guidance: Define terms precisely, use a relevant example, explain the reasoning, and state assumptions or limitations.

  12. 12. Explain how version control and peer review contribute to quality.

    Answer guidance: Define terms precisely, use a relevant example, explain the reasoning, and state assumptions or limitations.

  13. 13. Create a concise implementation plan with measurable acceptance criteria.

    Answer guidance: Define terms precisely, use a relevant example, explain the reasoning, and state assumptions or limitations.

  14. 14. Evaluate a trade-off involving cost, performance, reliability or usability.

    Answer guidance: Define terms precisely, use a relevant example, explain the reasoning, and state assumptions or limitations.

  15. 15. Reflect on the limitations of your proposed solution and identify further investigation.

    Answer guidance: Define terms precisely, use a relevant example, explain the reasoning, and state assumptions or limitations.

Revision checklist

Further study and academic integrity

Use current university textbooks, peer-reviewed research, official technical standards and primary product documentation to deepen this introductory framework. Check publication dates and version numbers because engineering tools and recommended practices evolve. Cite sources in the style required by your institution. Do not present generated text, code or diagrams as experimental evidence; independently verify every claim, calculation and implementation.

Scope note: These are structured undergraduate study notes, not a substitute for an accredited university module, supervised laboratory instruction or current vendor documentation. Confirm local curriculum and assessment requirements with your institution.

← Return to the Software Engineering course catalogue

Official Education References

Use these official organisations for curriculum guidance, examinations and further learning information.