fix endpoint tests