Merge "Cleanup and refactoring of test utilities"