[PATCH 3 of 6] tests: add tests for poorly behaving HTTP server

Yuya Nishihara yuya at tcha.org
Sat Apr 15 23:30:30 EDT 2017


On Fri, 14 Apr 2017 00:44:07 -0700, Gregory Szorc wrote:
> # HG changeset patch
> # User Gregory Szorc <gregory.szorc at gmail.com>
> # Date 1492147168 25200
> #      Thu Apr 13 22:19:28 2017 -0700
> # Node ID 80bd24abcf67d5dc8b5f5bf83c796e1f71fc5bd9
> # Parent  283a95fe4ce5b91af4e2ed8ed1d3fe18ef3544bb
> tests: add tests for poorly behaving HTTP server

> +closebeforeaccept
> +   If true, close() the server socket when a new connection arrives before
> +   accept() is called. The server will then exit.
> +
> +closeafteraccept
> +   If true, the server will close() the client socket immediately after
> +   accept().

Just a nitpick. IIRC, it's the same on TCP layer to close before/after accept()
because the initial handshake would be handled in background. But these options
might be good for test coverage.


More information about the Mercurial-devel mailing list