by mc_ · 6y ago · 0 comments
Fred (of Learn You Some Erlang) wrote a great book/site[1] on property testing in Erlang and Elixir, well worth the price of the book.
I find property testing is a muscle; the more time I can spend writing them, the "better" I get at writing useful tests. But the muscle atrophies quickly for me, so having the existing tests helps speed up getting into the mindset again.
I think the model checking (proper_statem in the PropEr code) is the real winner though. We can model a part of our system, write state transitions and then test those against both the model and a running system and compare our results. Any discrepancy points to either the model or the system being wrong (which is its own joy/pain to figure out).
No comments yet.