Strategies for unit testing an HTTP server.

  • Thread starter Alice Bevan–McGregor
  • Start date
A

Alice Bevan–McGregor

Hello!

Two things are missing from the web server I've been developing before
I can release 1.0: unit tests and documentation. Documentation being
entirely my problem, I've run into a bit of a snag with unit testing;
just how would you go about it?

Specifically, I need to test things like HTTP/1.0 request/response
cycles, HTTP/1.0 keep-alives, HTTP/1.1 pipelined reuqest/response
cycles, HTTP/1.1 connection: close, HTTP/1.1 chunked
requests/responses, etc.

What is the recommended / best way to test a daemon in Python? (Note
that some of the tests need to keep the "client" socket open.) Is
there an easy way to run a daemon in another thread, then kill it after
running some tests across it?

Even better, are there any dedicated (Python or non-Python) HTTP/1.1
compliance testing suites?

Thank you for any assistance,

— Alice.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,769
Messages
2,569,579
Members
45,053
Latest member
BrodieSola

Latest Threads

Top