Changed tests to match the new API