[chromedriver] Translate DevTools InvalidParams into InvalidArgument
When DevTools reports an error with code InvalidParams, translate it into an InvalidArgument error instead of UnknownError. This lets us perform certain checks on the devtools side that are not possible on the chromedriver side and return InvalidArgument when they fail without comparing against the error description on chromedriver. Additionally, we can avoid duplicating certain parameter checking on the chromedriver side. This patch also adds tests for the ParseInspectorError function. Bug: chromedriver:3025 Change-Id: I4a01136c87a53a1c5b2baac20c1ea65a60699d4f Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1706618 Commit-Queue: Nina Satragno <nsatragno@chromium.org> Commit-Queue: John Chen <johnchen@chromium.org> Auto-Submit: Nina Satragno <nsatragno@chromium.org> Reviewed-by:John Chen <johnchen@chromium.org> Cr-Commit-Position: refs/heads/master@{#678397}
Showing
Please register or sign in to comment