
I don't have a problem with using TDD *and* type-safety to the full extent
of usefulness, but the lifecycle/process isn't what TDD experts would call
proper TDD.
I do use HSpec, very happily. The author has done a truly excellent job
with it.
Process is something like:
write types, validate types
-> fill holes, validate terms against types
-> compose functions to see if results are sane, go back to 1st or 2nd step
if not.
-> Are there useful invariants QuickCheck can express? Write those first.
Repeat cycle as needed.
-> Decide on meaningful but compact functional/integration tests, repeat
cycle as needed.
Example HSpec tests (just functional/integration):
http://github.com/bitemyapp/bloodhound/
On Tue, Jun 24, 2014 at 3:55 PM, Gautier DI FOLCO wrote: Hi all, I'm a huge fan of TDD (Test-Driven Development) et I used to use tools
such as RSpec (Ruby). So naturally, I looked to HSpec, but it seems not
idiomatic in Haskell.
I have a bunch of questions:
- Do you do TDD?
- Which tools do you use?
- Is doctest "better" (in some senses) than HSpec? Why?
- Are HSpec and Doctest complementary? If so, in which case do you use one
or another?
- Is there some Haskell-specific good practices do to TDD? Thanks in advance for your lights. _______________________________________________
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe