4 years ago

Do you guys follow pure TDD, or do you plan out your target API head of time?

Posted 4 years ago by tag

I started off a project a while back to practice TDD and I realized that I immediately hit a wall. I wasn't sure what I even wanted to test, and when I finally did, I ended up with what I thought was a pretty awkward (but easily testable) API.

I've started working on a new library and this time instead of starting off with tests, I've decided to start off "sketching" what I want the public API be, then using that as a guideline for tests, and then letting the tests guide the actual implementation of that API.

Anyone else do something similar, or do you just dive right in with TDD without a gameplan first? If so, how do you go about deciding upon your public API?

Please sign in or create an account to participate in this conversation.