Added a test that we check the error code of tests