Better 404 error testing + Fix coverage and remove dead code.