Fix failing tests caused by the test API changes.
Merge pull request #848 from jails/bug/tests

Fix failing tests caused by the test API changes.