← Back to context

Comment by reificator

5 years ago

> > To hyperbole a bit, I'd rather spend time writing property based tests and a few types in haskell in a way.

> I'd rather spend some time making sure I'm building the right thing, rather than testing that what I built correctly does the wrong thing.

I don't believe the GP was saying to use tests instead of planning. They were saying to use the tests as planning.

They called out property-based testing in which you describe behavior of the system as a set of rules, such as `f(x) % 2 == 0`, and the test harness tests many inputs trying to find the simplest example that fails that criteria.

They also called out defining types (in their chosen language, not a step removed in a UML diagram), which allows you to think about how the data is shaped before you write an implementation that forces a shape.