2 ms·
When I did TDD, we'd start by writing a test. The tests wouldn't compile (Java) or link (C++) because the function being tested didn't exist yet. Then we'd wr
by AnimalMuppet 5y ago
When I did TDD, we'd start by writing a test. The tests wouldn't compile (Java) or link (C++) because the function being tested didn't exist yet. Then we'd write the (empty) function. The test would fail, because the function didn't exist. (It's very important that you see the test fail! You need to know that the test actually can detect if the function doesn't work.)
Then we'd implement the function, and re-run the test.