Skip to content

Commit

Permalink
Fix failing test.
Browse files Browse the repository at this point in the history
In Selenium 2.53.0, the error code mapper would not match the
UnsupportedCommandException and so would return the default
value of UNHANDLED_ERROR. In 3.0, we correctly map this to
the more appropriate error code of UNKNOWN_COMMAND, which
describes the lack of a match more appropriately.
  • Loading branch information
shs96c committed Oct 13, 2016
1 parent cdba733 commit f276459
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -182,7 +182,7 @@ public void handlesInvalidCommandsToRootOfDriverService()
assertEquals(500, response.getStatus());

JsonObject jsonResponse = new JsonParser().parse(response.getBody()).getAsJsonObject();
assertEquals(ErrorCodes.UNHANDLED_ERROR, jsonResponse.get("status").getAsInt());
assertEquals(ErrorCodes.UNKNOWN_COMMAND, jsonResponse.get("status").getAsInt());

JsonObject value = jsonResponse.get("value").getAsJsonObject();
assertTrue(value.get("message").getAsString().startsWith("POST /"));
Expand Down

0 comments on commit f276459

Please sign in to comment.