configitems: register the 'badserver.closeaftersendbytes' config
authorPierre-Yves David <pierre-yves.david@octobus.net>
Fri, 30 Jun 2017 03:27:54 +0200
changeset 33193 cbb50fd830ea
parent 33192 c538fca0d511
child 33194 c077eac329e2
configitems: register the 'badserver.closeaftersendbytes' config
tests/badserverext.py
--- a/tests/badserverext.py	Fri Jun 30 03:27:44 2017 +0200
+++ b/tests/badserverext.py	Fri Jun 30 03:27:54 2017 +0200
@@ -50,6 +50,9 @@
 configitem('badserver', 'closeafterrecvbytes',
     default=0,
 )
+configitem('badserver', 'closeaftersendbytes',
+    default=0,
+)
 
 # We can't adjust __class__ on a socket instance. So we define a proxy type.
 class socketproxy(object):
@@ -272,7 +275,7 @@
             closeafterrecvbytes = self._ui.configint('badserver',
                                                      'closeafterrecvbytes')
             closeaftersendbytes = self._ui.configint('badserver',
-                                                     'closeaftersendbytes', 0)
+                                                     'closeaftersendbytes')
 
             if closeafterrecvbytes or closeaftersendbytes:
                 socket = socketproxy(socket, self.errorlog,