unit test improvements