Hacker News new | ask | show | jobs
by susshshshah 362 days ago
How do you know what tests to write if you don’t understand the code?
3 comments

Same way you normally would? Tests are concerned with behaviour. The code that implements the behaviour is immaterial.
How do you do TDD without having code in the first place? How do QA verifies without reading the source?
I’m not sure I understand this statement. You give your program parameters X and expect result Y, but instead get Z. There is your test, embedded in the problem statement.