- Move copy-pasted code to User API - Clean the database after each test - Refactor documents search test