Convert asserts to raises and return them as 400s and 409s