Skip to content
This repository was archived by the owner on Jan 13, 2021. It is now read-only.

Commit 8542efe

Browse files
committed
Test evicting from the encoder.
1 parent 78bc47f commit 8542efe

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

test/test_hyper.py

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -763,6 +763,16 @@ def test_setting_table_size_to_the_same_does_nothing(self):
763763

764764
assert out == b'\x82'
765765

766+
def test_evicting_header_table_objects(self):
767+
e = Encoder()
768+
769+
# Set the header table size large enough to include one header.
770+
e.header_table_size = 66
771+
header_set = [('a', 'b'), ('long-custom-header', 'longish value')]
772+
e.encode(header_set)
773+
774+
assert len(e.header_table) == 1
775+
766776

767777
class TestHPACKDecoder(object):
768778
# These tests are stolen entirely from the IETF specification examples.

0 commit comments

Comments
 (0)