We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 975ca15 commit d3cf9b8Copy full SHA for d3cf9b8
multicast/hear.py
@@ -701,6 +701,20 @@ def handle(self):
701
>>>
702
>>> multicast.endSocket(tst_fixture_sock)
703
704
+
705
+ Testcase 4: `handle` raises on valid STOP requests.
706
707
+ >>> tst_fixture_sock = multicast.genSocket()
708
+ >>> handler.request = ("The Test is STOP", tst_fixture_sock)
709
+ >>> handler.client_address = ("224.0.1.3", 54321)
710
+ >>> try:
711
+ ... handler.handle()
712
+ ... except multicast.exceptions.ShutdownCommandReceived:
713
+ ... print('ShutdownCommandReceived raised')
714
+ ShutdownCommandReceived raised
715
+ >>>
716
+ >>> multicast.endSocket(tst_fixture_sock)
717
718
"""
719
(data, sock) = self.request
720
if data is None or not sock:
0 commit comments