Functional Testing
Functional testing verifies that a system does what it is specified to do — that each feature behaves correctly according to its defined requirements.
What Functional Testing Covers
Functional testing asks a simple, direct question for every requirement: does this feature behave the way it's supposed to? It typically follows a black box approach, focused entirely on inputs and expected outputs rather than internal implementation.
- Does submitting a valid login redirect to the correct dashboard?
- Does an invalid discount code display the correct error message?
- Does adding an item to a cart correctly update the displayed total?
Common Mistakes
- Testing only positive scenarios (valid input, expected flow) and neglecting negative scenarios (invalid input, error handling).
- Writing functional tests based on assumptions rather than the actual documented requirements.
- Not updating functional test cases when requirements change, leaving outdated tests that no longer reflect intended behaviour.
- Confusing functional testing (does it do the right thing) with usability testing (is it pleasant and intuitive to use) — they're related but distinct.
Professional Tip
For every functional requirement, deliberately write at least one negative test case alongside the positive one — confirming a feature correctly rejects invalid input is just as important as confirming it accepts valid input.
Your Turn
Write three functional test cases for a user registration form: one for successful registration, one for a duplicate email, and one for a password that doesn't meet complexity requirements.
Mini Quiz
What does functional testing primarily verify?