Stages of Software Testing: The 6 STLC Phases and 4 Test Levels
Stages of software testing can mean six STLC phases or four test levels. Get each phase's entry and exit criteria, and what a weekly team can compress.
You’re asked to set up a testing process, and the first two guides you open on the stages of software testing hand you lists that don’t match. One runs from requirement analysis to test closure. The other climbs from unit tests to acceptance tests. Both are right, and a team that merges them builds a process with a gap in what it tests.
The first list is the software testing life cycle (STLC), and the second is the test levels. If your team ships every week, you’ll leave knowing which part of each phase can shrink and which decision can’t.
What you’ll learn
- The difference between STLC phases and test levels, and what a process misses when it tracks only one
- Entry criteria, work and exit criteria for each of the six phases
- How unit, integration, system and acceptance tests move through those phases
- Which phases a weekly release can shrink, and the decision each one still has to make
What Are the Stages of Software Testing?
The stages of software testing are the steps testing moves through between a requirement and a release, and the term covers two different lists. The STLC phases say what testing should be doing at a given moment. The test levels say how big a piece of the system a given test is checking.
| STLC phases | Test levels | |
|---|---|---|
| What it orders | The work of testing, in time | The scope of the thing under test |
| The list | Requirement analysis, test planning, test case development, environment setup, test execution, test closure | Unit, integration, system, acceptance |
| The question it answers | What should testing be doing right now? | How much of the product does this test touch? |
| Who owns it | Whoever owns quality for the release | Developers at the bottom, QA in the middle, the business at the top |
| A gap here means | A decision got skipped, like what done means | A whole class of bug has no test that can see it |
The two lists cross. Every level goes through every phase, each on its own clock.
STLC phases are when testing does what, and test levels are how much of the system a test touches.
The 6 STLC Phases, With Entry and Exit Criteria
Each phase starts when its entry criteria hold and ends when its exit criteria do, and the exit of one phase is the entry of the next. A phase that starts before its entry criteria hold is working from a guess.
| # | Phase | Starts when | The work | Done when |
|---|---|---|---|---|
| 1 | Requirement analysis | Requirements or user stories exist, even rough ones | Read them for what can be tested, find the gaps, raise questions | Each requirement is testable or has an open question with an owner |
| 2 | Test planning | Testable requirements and a target release | Set scope, owners, levels, the automation approach, and what done means | A plan the release owner has agreed to |
| 3 | Test case development | An agreed plan | Write cases and the data each one needs, mapped to requirements | Every in-scope requirement has a reviewed case |
| 4 | Environment setup | Known cases and their data needs | Stand up the environment, seed data and test accounts | A smoke test passes on the build you mean to test |
| 5 | Test execution | A ready environment and the build under test | Run cases, log defects, retest fixes, rerun the regression set | The plan’s exit bar is met, such as no open critical defects |
| 6 | Test closure | Execution’s exit bar is met, or a decision to ship with known issues | Record what was tested, what wasn’t, and what escaped | The release decision and next cycle’s changes are written down |
1. Requirement Analysis
Analysis reads each requirement the way a tester would, looking for what can’t be checked yet. I’ve been part of many companies with different QA philosophies, and the weakest kind of QA is too married to the spec. A requirement says what one feature should do, and checking exactly that misses how people actually move through the product. Great QA isn’t possible without understanding the product, so testers spend this phase learning the product as well as the ticket.
2. Test Planning
Planning turns testable requirements into decisions about scope and ownership. The one that matters most is what counts as done, because execution can’t finish without it. The test plan is where those decisions get written down.
3. Test Case Development
Test case development writes each case as steps and an expected result, with the data it needs. It’s also where you pick which cases get automated, ranked by payoff against upkeep the way a test automation strategy orders them. Newer AI testing tools have started drafting cases here too, which moves the human work toward reviewing them.
4. Environment Setup
Cases need somewhere to run that behaves like production. A test environment covers everything around the build, from servers to seeded test data, that makes a result carry over to real users. The exit criterion is a smoke test on the exact build you mean to test, so a broken environment gets caught before any case runs against it.
5. Test Execution
Execution runs the cases and logs each defect with the steps to reproduce it. Once fixes land, it reruns the regression testing set, so a fix for one defect doesn’t break something that worked last week. Execution ends when the plan’s exit bar is met.
6. Test Closure
Closure writes down which bugs got past testing, whether your team caught them after release or a user did. Keep the output short. Pair each escaped bug with the case that would have caught it, and put that case in the next cycle’s plan.
Start Test Cases From a Draft
Skip the blank page. Review the tests Pie drafts from your app.
The 4 Test Levels and How They Cross the Phases
Test levels sort tests by scope, from one function up to the whole product in a user’s hands. Ham Vocke’s practical test pyramid, published on Martin Fowler’s site, describes the same idea as buckets of different granularity, with fewer tests the higher you go.
- Unit: One function or class in isolation, with its dependencies swapped for stand-ins. Developers write and run these on every change.
- Integration: Pieces working together with real dependencies, like a service and its database or two services over an API. Teams run these with the same frameworks they use for unit tests or with dedicated integration testing software.
- System: The whole assembled product, tested end to end in an environment built like production. QA usually owns this level.
- Acceptance: Whether the product meets the need it was built for, judged by product owners or users. User acceptance testing (UAT) lives here.
Each level runs through all six phases, and the clock stretches as you go up. A developer writing a unit test goes through all six in minutes, often without naming any of them. At the system level, each phase can have its own owner and its own meeting, and the cycle takes days. Test automation carries most of the lower levels on its own, which is why the phases blur there and stay visible at the top.
What a Weekly Team Can Compress, and What It Can’t Skip
A team shipping every week doesn’t have six phases of calendar time. It has the same six decisions to make. Each phase exists to settle one question, and the document around that question is the part you can shrink. DORA’s research puts the goal plainly: “fast feedback on the impact of changes throughout the software delivery lifecycle.” Phases that run as a block after development is done are the opposite of that.
| Phase | The decision you can’t skip | The weekly version |
|---|---|---|
| Requirement analysis | What is testable, and what’s still unclear | Ten minutes on the ticket before work starts |
| Test planning | What done means for this change | Two or three lines in the ticket or pull request |
| Test case development | Which cases, and which get automated | Automated cases written alongside the code |
| Environment setup | Whether the environment behaves like production | Built once in code, rebuilt by the pipeline on every change |
| Test execution | Whether the agreed cases passed | The pipeline on every merge, plus a scheduled full run |
| Test closure | What escaped, and what changes next week | One line per escaped bug, with the case that would have caught it |
Two rows don’t shrink the way the others do. Environment setup is the one phase you pay for once instead of every release. Build it in code and each later cycle inherits it. Execution can move into the pipeline, but its exit bar can’t move with it. If nobody wrote down what done means in planning, execution has no point at which it ends, and the release ships on a feeling.
Pick the one decision your team made last release without a record, and put it in the ticket for the next one.
Where Pie Sits in the Testing Life Cycle
Pie takes the repeatable work out of two phases, test case development and execution. Here is what our agentic testing platform does there:
- Draft tests: Pie explores your app’s flows and writes tests from what it finds, so test case development starts from a draft your team reviews.
- Scheduled runs: A Loop runs your suite on a schedule you set, so execution doesn’t wait for somebody to start it.
- Issue triage: Pie sorts a run’s related findings into issues, ready for your team to triage.
The other four phases run on what your team knows about the product. Planning sets the exit bar that Pie’s results are judged against. Pie tests the web URL or app build you give it, which keeps environment setup in your hands.
Six Decisions, Smaller Documents
The stages of software testing are two lists, and they answer different questions. Phases put testing’s work in order, and levels decide how much of the product each test can see. A process with all six phases and only unit tests has no test at three of the four levels.
The phases were written for long release cycles, and the documents around them can shrink to fit a weekly one. The decisions can’t. Find the one decision your team skips, settle it at the next sprint planning, and keep the document around it as short as it can be.
Put Test Execution on a Schedule
Pie drafts the tests and runs them on your schedule. Your team keeps the six decisions.