Lesson340 words

Comprehensive testing strategy

Design a comprehensive testing strategy

The shape

Loading Diagram...
Figure 1 — Mermaid diagram

| Context or type | Scope | Typical placement | |---|---|---|---| | Local development / inner loop | Selected fast, relevant checks on the developer's machine | Before push and throughout development | | Unit test | One component, outside dependencies removed or replaced | Run frequently, including in PR validation | | Integration test | Two or more components, often with supporting infrastructure | As soon as its required components and environment are available | | Load / performance test | System under expected and peak traffic | Start early and repeat at meaningful CI/CD points in staging or a production-like environment |

Choosing where a test belongs

Move tests as early as practical so defects are found when they generally cost less to fix. “Local” describes the inner-loop context, not an intrinsic test level: a developer can run unit, integration, or performance checks locally when the needed dependencies and capacity exist. A test that needs a real database is not an isolated unit test merely because it runs before a push.

Load testing is a different question

Unit and integration tests ask whether isolated components and their interactions behave correctly. Load tests ask whether the workload handles expected and peak traffic. Define measurable thresholds, run representative load tests in staging or a production-like environment, start early, and repeat at points justified by cost and workload risk.

Flaky tests

A rerun can help detect flakiness: Azure DevOps can mark a test flaky when it fails and then passes on rerun. That is not a resolution. Track and analyze the unreliable test, create or resolve the underlying defect, and then fix, remove, or unmark it to close the loop.

Primary sources

Ready to study Designing and Implementing Microsoft DevOps Solutions (AZ-400)?

Practice tests, flashcards, and all study notes — free, no sign-up needed.

Start Studying — Free