Update unit tests to make them work correctly