AZ400-Q: select pipeline test layers
A team wants fast feedback for each pull request, confidence that its API works with a real database, and evidence that a release can sustain expected traffic. Which testing strategy is best?
- A) Run unit tests on every pull request, run integration tests with an isolated database in CI, and run load tests in an appropriate preproduction environment. ✓
- B) Run only end-to-end tests in production after every release.
- C) Run load tests on every developer commit and skip unit tests to save time.
- D) Require a code review; it replaces automated tests.
Answer: A. Test layers have different speed, cost, and confidence. Unit tests provide rapid local feedback, integration tests validate boundaries, and load tests assess performance under a realistic environment and workload.
Why not the others: Production-only detection is late and risky. Load testing every commit is slow and expensive. Review is valuable but does not execute the system.