dom96 / httpbeast

A highly performant, multi-threaded HTTP 1.1 server written in Nim.
MIT License
450 stars 53 forks source link

Allow to change port for tests #87

Open CyberTailor opened 1 year ago

CyberTailor commented 1 year ago

When port 8080 is busy, tests fail. https://bugs.gentoo.org/901143

victormihalache commented 10 months ago

You can use the following run method to specify a custom port:

run(onRequest, initSettings(port=Port(2000)))

Note that it's normal behaviour for it to fail when the port is busy, any program will fail to use a port that's being used by another program.