I assume most people have read the Painless Functional Specification articles by Joel. In part two, What’s a Spec?, a sample spec is provided. However there is no mention of requirements. I have two questions:
-
How do requirements fit into the sample functional spec? I assume the requirements must be known before a functional spec can be written. So they can’t be part of the functional spec, but where are they recorded?
-
How does test driven development (TDD) fit into the whole func spec / tech spec split Joel outlines (below):
A functional specification describes how a product will work entirely
from the user’s perspective. It doesn’t care how the thing is
implemented. It talks about features. It specifies screens, menus,
dialogs, and so on.A technical specification describes the internal implementation of the
program. It talks about data structures, relational database models,
choice of programming languages and tools, algorithms, etc.
Functional design
This is the WHAT.
What are you designing? What will users do with it? What value will it provide them?
The functional spec is the requirements. Each operation the various users perform (create account, log in, view time) is a requirement of the system.
You have to go deeper, though, and ask yourself, “what happens if Mike can’t remember his password?” “What does ‘exciting’ mean to Cindy?” etc. (This is why Joel notes it isn’t a complete spec—it is missing many details.)
TDD
Test driven design is the HOW
How do the classes, methods, etc. work? How are errors handled? How does data flow through the code?