[Unit Testing] Unit Test as a Bug Report
When a test fails, that test failure report should be your best place to find what went wrong and give you clues to tracking the root cause . What's in a good Test Failure Bug Report? What are you testing? What should it do? What was the output (actual behavior)? What was the expected output (expected behavior)? (Example of good failure report) In the screenshot above, it's clear that we are testing 'compose()'. What is should do is to 'return a function'. It also shows expected, and actual, addition to the operator for our assert method. Resources: https://medium.com/javascript-scene/what-every-unit-test-needs-f6cd34d9836d