In part 1 of this series I went over a couple rules that I follow when writing unit tests. Now I'm going to dig in to some of the specifics of how to unit test certain types of behavior that can be a little tricky to do properly. »
Unit tests are important. So are end-to-end tests that mimic real user behavior. All the other stuff in between on the testing pyramid - not so much. »
Recently my friend and benchee co-maintainer Tobi had an idea to use benchee to run benchmarks with random data »
There is far and way a single assertion in ExUnit that is responsible for more test flakiness than any other. It's probably the culprit for more than half of all test failures that shouldn't fail. »
I love automation of things. I especially love automating the simple parts of code review, since much of that stuff can be easily automated with static analysis tools. »