Fixing tests

Merged: kavita's PRs for unauthorized_user_spec branch (all tests green) with my branch for all other tests and vendor tests (all tests green).