Simplifies assert checks in tests.

* Also ensures `assert.equal` is always in the right order.