Fixed bugs in the test environment.