Use try/catch when parsing response body, rather than checking status codes
Made a test more terse