Fix wrong value type passed to format string
Make error strings lowercase
Integrate rollback into withdrawal algorithm
Refactor a bunch of our test helpers to make them more flexible

This also changes most of them use unique IDs for the DB entries they create,
meaning they can now be called multiple times in a single test.