Update unit tests and cleanup