| 1066 | SC_TEST_EXPECT(threadPool.create(2)); |
| 1067 | } |
| 1068 | SC_TEST_EXPECT(httpServer.init(Span<ServerConnection>(connections))); |
| 1069 | SC_TEST_EXPECT(httpServer.start(loop, "127.0.0.1", port)); |
| 1070 | SC_TEST_EXPECT(fileServer.init(threadPool, loop, webServerFolder)); |
| 1071 | struct ServerContext |
| 1072 | { |
| 1073 | HttpAsyncFileServer& fileServer; |
| 1074 | HttpAsyncFileServer::StreamQueue<2>* streams; |
| 1075 | } serverCtx = {fileServer, streams}; |
| 1076 | httpServer.onRequest = [this, &serverCtx](HttpConnection& connection) |
| 1077 | { |
| 1078 | SC_TEST_EXPECT( |
| 1079 | serverCtx.fileServer.handleRequest(serverCtx.streams[connection.getConnectionID().getIndex()], connection)); |
nothing calls this directly
no test coverage detected