Minor improvements for tests.