Updating tests for the new api