We previously introduced proxy objects and observers for file objects
to help implement low-level tests for the SSH wire protocol.
In this commit, we do the same for sockets in order to help test the
HTTP server.
We only proxy/observe some socket methods. I didn't feel like
implementing all the methods because there are so many of them and
implementing them will provide no short term value. We can always
implement them later.
- no-check-commit because we implement foo_bar methods on stdlib types
While debugging the test failure on Python 3.6, the caller at line 751 can pass 5 positional arguments.
Here is the traceback after running test-wireproto-command-branchmap.t:
I am not sure whether this exact code path is tested on Python 2 or not. Can you have a look?