CS FundamentalsModerateAccenture · Capgemini

A CI pipeline takes 40 minutes: end-to-end UI tests (30 min) run first, then unit tests (3 min), then linting (1 min). Most failures are lint or unit failures. What reordering follows the fail-fast principle and the test pyramid?

  1. A. Lint, then unit tests, then integration tests, then the slow end-to-end tests
  2. B. End-to-end tests first because they are most realistic
  3. C. Run only end-to-end tests and drop unit tests
  4. D. Run everything only nightly

Correct answer: A. Lint, then unit tests, then integration tests, then the slow end-to-end tests

Cheap, fast checks that fail most often should run first so developers get feedback in minutes. The pyramid also says to have many fast unit tests and few slow end-to-end tests.

More Software Engineering, Git and Cloud Basics questions

Exams that ask this topic