Q21 of 38 · CI/CD & DevOps

What is a smoke test and when do you run it in a CI/CD pipeline?

CI/CD & DevOpsJuniorci-cdsmoke-testpipelinepost-deploydeployment

Short answer

Short answer: A smoke test is a small, fast suite of critical-path checks that confirms a build is stable enough for deeper testing. Run it immediately after deployment — if smoke fails, the pipeline stops before spending time on a broken build.

Detail

A smoke test (also called a build verification test) covers the core happy paths: login works, the homepage loads, the API returns 200. It runs in minutes, not hours.

In a CI/CD pipeline you typically run the smoke suite twice: once against a staging environment after promotion, and again as a post-deploy check in production after a release. If smoke fails, the pipeline stops and triggers rollback or an alert — saving the cost of running a full regression against a broken deployment.

Smoke tests must be fast (under 5 minutes), stable, and cover real user value rather than internal plumbing. A smoke suite with 20% flakiness defeats its own purpose.

// WHAT INTERVIEWERS LOOK FOR

Distinction between smoke and full regression. Knowing smoke runs after each deployment, not just before. Mentioning it as the gate before full regression and again post-deploy in production.