[WebSocket] Prevent unnecessary pywebsocket warnings on layout tests.
authorcommit-queue@webkit.org <commit-queue@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Wed, 31 Aug 2011 09:06:24 +0000 (09:06 +0000)
committercommit-queue@webkit.org <commit-queue@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Wed, 31 Aug 2011 09:06:24 +0000 (09:06 +0000)
commit082aa1d7a5e29d355f5cebe3cda6f83d5be7f965
treedc70cb1b477a31c51e140c8676facbda608f4b7f
parent6c74e71c96c51d1e907a902df65e049b9cf81325
[WebSocket] Prevent unnecessary pywebsocket warnings on layout tests.
https://bugs.webkit.org/show_bug.cgi?id=67182

Patch by Takashi Toyoshima <toyoshim@chromium.org> on 2011-08-31
Reviewed by Kent Tamura.

Some layout tests for WebSocket raised Exception to prevent unnecessary
pywebsocket warning. But it doesn't work any more on pywebsocket 0.6b4.
Now pywebsocket support AbortedByUserException to prevent warning.
This change make raise AbortedByUserException instead of Exception.

handshake-fail-by-prepended-null_wsh.py didn't use Exception, but
expected abnormal closure on sending response could raise unexpected
Exception by chance. This change also takes care of it.

* http/tests/websocket/tests/hixie76/bad-handshake-crash_wsh.py:
* http/tests/websocket/tests/hixie76/frame-length-longer-than-buffer_wsh.py:
* http/tests/websocket/tests/hixie76/frame-length-overflow_wsh.py:
* http/tests/websocket/tests/hixie76/handshake-fail-by-maxlength_wsh.py:
* http/tests/websocket/tests/hixie76/handshake-fail-by-no-connection-header_wsh.py:
* http/tests/websocket/tests/hixie76/handshake-fail-by-no-cr_wsh.py:
* http/tests/websocket/tests/hixie76/handshake-fail-by-no-upgrade-header_wsh.py:
* http/tests/websocket/tests/hixie76/handshake-fail-by-prepended-null_wsh.py:
* http/tests/websocket/tests/hixie76/long-invalid-header_wsh.py:
* http/tests/websocket/tests/hybi/bad-handshake-crash_wsh.py:
* http/tests/websocket/tests/hybi/handshake-fail-by-extensions-header_wsh.py:
* http/tests/websocket/tests/hybi/handshake-fail-by-maxlength_wsh.py:
* http/tests/websocket/tests/hybi/handshake-fail-by-no-accept-header_wsh.py:
* http/tests/websocket/tests/hybi/handshake-fail-by-no-connection-header_wsh.py:
* http/tests/websocket/tests/hybi/handshake-fail-by-no-cr_wsh.py:
* http/tests/websocket/tests/hybi/handshake-fail-by-no-upgrade-header_wsh.py:
* http/tests/websocket/tests/hybi/handshake-fail-by-wrong-accept-header_wsh.py:
* http/tests/websocket/tests/hybi/long-invalid-header_wsh.py:
* http/tests/websocket/tests/hybi/masked-frames_wsh.py:
Use AbortedByUserException instead of Exception.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@94164 268f45cc-cd09-0410-ab3c-d52691b4dbfc
20 files changed:
LayoutTests/ChangeLog
LayoutTests/http/tests/websocket/tests/hixie76/bad-handshake-crash_wsh.py
LayoutTests/http/tests/websocket/tests/hixie76/frame-length-longer-than-buffer_wsh.py
LayoutTests/http/tests/websocket/tests/hixie76/frame-length-overflow_wsh.py
LayoutTests/http/tests/websocket/tests/hixie76/handshake-fail-by-maxlength_wsh.py
LayoutTests/http/tests/websocket/tests/hixie76/handshake-fail-by-no-connection-header_wsh.py
LayoutTests/http/tests/websocket/tests/hixie76/handshake-fail-by-no-cr_wsh.py
LayoutTests/http/tests/websocket/tests/hixie76/handshake-fail-by-no-upgrade-header_wsh.py
LayoutTests/http/tests/websocket/tests/hixie76/handshake-fail-by-prepended-null_wsh.py
LayoutTests/http/tests/websocket/tests/hixie76/long-invalid-header_wsh.py
LayoutTests/http/tests/websocket/tests/hybi/bad-handshake-crash_wsh.py
LayoutTests/http/tests/websocket/tests/hybi/handshake-fail-by-extensions-header_wsh.py
LayoutTests/http/tests/websocket/tests/hybi/handshake-fail-by-maxlength_wsh.py
LayoutTests/http/tests/websocket/tests/hybi/handshake-fail-by-no-accept-header_wsh.py
LayoutTests/http/tests/websocket/tests/hybi/handshake-fail-by-no-connection-header_wsh.py
LayoutTests/http/tests/websocket/tests/hybi/handshake-fail-by-no-cr_wsh.py
LayoutTests/http/tests/websocket/tests/hybi/handshake-fail-by-no-upgrade-header_wsh.py
LayoutTests/http/tests/websocket/tests/hybi/handshake-fail-by-wrong-accept-header_wsh.py
LayoutTests/http/tests/websocket/tests/hybi/long-invalid-header_wsh.py
LayoutTests/http/tests/websocket/tests/hybi/masked-frames_wsh.py