Fix test errors

The tests passed locally with the `tox` command.