Skip to content

Refactor tests that might be unnecessary #740

@surister

Description

@surister

in test_http.py, for example tests that use:

class SharedStateRequestHandler(BaseHTTPRequestHandler):
Do not seem to be very useful, we setup an HTTP server that parses things from the headers and puts the parsed stuff to a dictionary, then we check that that dictionary has what we expected.

Why are we testing this on a threaded HTTP server, we could literally just get the headers from a request and check that it's what we'd expect, without any overhead of setting up a thread and an http server. Other tests that also start an http server have the same issue, we could test the exact same thing without all of this machinery.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions