Fix tests and routes