> Could you give an example of a specification that would be > hard to replace with a test?
Anything the customer is expected to understand: - Concept of Operations - Requirements / Use Cases - Conceptual Design / Architecture - Acceptance Test
Anything the whole technical team should understand (not just programmers): - Architecture - Detailed Design - Algorithms
Anything outside the code: - Database Design - User Interface Design
Those are just examples. Do you need every one on every project? Absolutely not. In my opinion you almost always need a ConOps, the rest are "as needed" depending on size, content, and complexity.
Most of these specifications live well above the "unit test" level of granularity. IMHO specifications are for communicating what the forest looks like, not counting rings in individual trees. Unit tests are for counting rings.