Fixed the unit tests

Fixed there unit tests again to match our new API