convert unittests to new FAIL/PASS API
Convert existing tests to use the FAIL/PASS API. The idea is that every step in a test is checked and that the test should not leak memory on its success path.
There are very many tests, some of which have lots of duplication. Consider per test whether the test can be improved (cleaned up) further.
This is not something can is meant to be done in one step. A commit per source file is ok. PRs can include multiple commits.