fix endpoint test