Update expectation for permessage-deflate compression result for empty payload
It seems newer zlib library omits unnecessary compressed block and just puts
uncompressed block for empty input.
Release note: n/a
R=yhirano@chromium.org
Review URL: https://codereview.appspot.com/179880043
git-svn-id: https://pywebsocket.googlecode.com/svn/trunk@859 4ff78f4a-9131-11de-b045-6380ec9940d4
diff --git a/src/test/test_msgutil.py b/src/test/test_msgutil.py
index 5fedcf9..053f4ae 100755
--- a/src/test/test_msgutil.py
+++ b/src/test/test_msgutil.py
@@ -758,16 +758,12 @@
msgutil.send_message(request, '')
- # Payload in binary: 0b00000010 0b00000000
+ # Payload in binary: 0b00000000
# From LSB,
# - 1 bit of BFINAL (0)
- # - 2 bits of BTYPE (01 that means fixed Huffman)
- # - 7 bits of the first code (0000000 that is the code for the
- # end-of-block)
- # - 1 bit of BFINAL (0)
# - 2 bits of BTYPE (no compression)
- # - 3 bits of padding
- self.assertEqual('\xc1\x02\x02\x00',
+ # - 5 bits of padding
+ self.assertEqual('\xc1\x01\x00',
request.connection.written_data())
def test_send_message_with_null_character(self):