Make assertions about API calls in unit tests, too.