| Conditions | 1 |
| Total Lines | 14 |
| Code Lines | 9 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 0 | ||
| 1 | """ |
||
| 14 | @pytest.fixture |
||
| 15 | def make_server(): |
||
| 16 | # Per default, bind to localhost on random user port. |
||
| 17 | def _wrapper(host='', port=0, *, api_tokens=None): |
||
| 18 | config = HttpConfig(host, port, api_tokens=api_tokens) |
||
| 19 | |||
| 20 | server = ReceiveServer(config) |
||
| 21 | |||
| 22 | thread = Thread(target=server.handle_request) |
||
| 23 | thread.start() |
||
| 24 | |||
| 25 | return server |
||
| 26 | |||
| 27 | return _wrapper |
||
| 28 | |||
| 33 |