A smoke test is broad and shallow, checking that a build is stable enough to test at all, and it runs immediately after deployment. A sanity check is narrow and deep, verifying one specific fix or area after a change. Regression testing is the broad suite confirming existing behavior still works, run nightly or before release since it is too slow for every commit.
Why interviewers ask this
This is terminology, but interviewers use it to check that you can plan a pipeline rather than just run tests. The distinction they actually care about is when each suite runs and what decision it gates. Tying smoke to a deployment gate, sanity to verifying a specific change, and regression to a scheduled or pre release run shows you think in terms of feedback loops rather than labels.
How to structure your answer
- Define each in one line, using breadth and depth as the axis.
- Say when each one runs in the pipeline.
- Say what decision each suite gates.
- Mention how you stop the regression suite growing forever.
Example answer
I think of it on two axes, breadth and depth. Smoke is wide and shallow: does the app start, does the home page render, can a user log in, does the main API respond. It runs right after every deployment to any environment and it gates whether it is even worth running anything else. If smoke fails we stop and fix the build rather than debugging fifty downstream failures. Sanity is narrow and deep: a developer fixed a discount calculation, so I exercise that calculation hard plus whatever sits immediately around it. It is fast, targeted, and runs on the branch before merge. Regression is the broad suite confirming that everything that used to work still works, and because it is slow it runs nightly and before a release rather than on every commit. The part I actively manage is regression suite growth. Suites only ever get bigger unless someone prunes them, so I periodically hunt for tests that have never failed for a real reason, tests duplicating coverage at a lower layer, and tests for features that were removed. A four hour suite nobody trusts is worth less than a forty minute one people act on.
Walking into this interview soon? GhostPilot listens to your live call, spots the question the moment it is asked, and puts a structured answer on your screen in real time. Try it on your next mock, or grab a $29 Session Pass, no subscription, for the real thing.
See how it worksFollow-up questions to expect
- How would you decide which fifteen tests belong in the smoke suite?
- How do you justify deleting a test to a nervous stakeholder?
- What is the difference between regression testing and re testing a fix?
Related qa engineer questions
Your interviewer will ask their own version of this. Paste your actual job description into the free Question Predictor and get the 20 questions that role is most likely to ask, with what each one is really probing.
Predict my questions