Changeset 101974 in webkit
- Timestamp:
- Dec 4, 2011, 11:42:19 PM (15 years ago)
- Location:
- trunk/LayoutTests
- Files:
-
- 2 edited
-
ChangeLog (modified) (1 diff)
-
http/tests/websocket/tests/hybi/echo_wsh.py (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/LayoutTests/ChangeLog
r101971 r101974 1 2011-12-04 Takashi Toyoshima <toyoshim@chromium.org> 2 3 Add binary support in WebSocket test server's echo handler. 4 https://bugs.webkit.org/show_bug.cgi?id=73649 5 6 Reviewed by Eric Seidel. 7 8 * http/tests/websocket/tests/hybi/echo_wsh.py: Support binary frames. 9 1 10 2011-12-04 Kent Tamura <tkent@chromium.org> 2 11 -
trunk/LayoutTests/http/tests/websocket/tests/hybi/echo_wsh.py
r90726 r101974 1 # Copyright 2009, Google Inc.1 # Copyright 2009, 2011, Google Inc. 2 2 # All rights reserved. 3 3 # … … 29 29 30 30 31 from mod_pywebsocket import msgutil 32 33 34 _GOODBYE_MESSAGE = 'Goodbye' 31 _GOODBYE_MESSAGE = u'Goodbye' 35 32 36 33 … … 41 38 def web_socket_transfer_data(request): 42 39 while True: 43 line = msgutil.receive_message(request) 44 msgutil.send_message(request, line) 45 if line == _GOODBYE_MESSAGE: 40 line = request.ws_stream.receive_message() 41 if line is None: 46 42 return 43 if isinstance(line, unicode): 44 request.ws_stream.send_message(line, binary=False) 45 if line == _GOODBYE_MESSAGE: 46 return 47 else: 48 request.ws_stream.send_message(line, binary=True)
Note:
See TracChangeset
for help on using the changeset viewer.