Converting tests to use the proper error handlers
Simplifying the deprecated error route block