From 04acfa679fd846ac829ded5562093b3766c85154 Mon Sep 17 00:00:00 2001 From: Dan Goodliffe Date: Sun, 18 Jan 2026 01:36:06 +0000 Subject: Process new field, content-type, in input stream --- test/testing-util.cpp | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'test/testing-util.cpp') diff --git a/test/testing-util.cpp b/test/testing-util.cpp index 010b2c6..6e75354 100644 --- a/test/testing-util.cpp +++ b/test/testing-util.cpp @@ -34,6 +34,7 @@ namespace WebStat { std::vector qss; std::vector refs; std::vector uas; + std::vector ct; }; Strings strings; @@ -65,6 +66,7 @@ namespace WebStat { {strings.qss, 100, getStrGen(1, 50)}, {strings.refs, 50, getStrGen(10, 50)}, {strings.uas, 10, getStrGen(50, 70)}, + {strings.ct, 10, getStrGen(10, 20)}, }) { std::generate_n(std::back_inserter(out), count, stringGenerator); } @@ -86,10 +88,11 @@ namespace WebStat { std::ofstream logfile {path}; for (size_t line = 0; line < entries; ++line) { - std::println(logfile, R"LOG({} {} {} GET "/{}" "?{}" HTTP/1.1 200 {} {} "{}" "{}")LOG", + std::println(logfile, R"LOG({} {} {} GET "/{}" "?{}" HTTP/1.1 200 {} {} "{}" "{}" "{}")LOG", randomString(strings.vhosts), randomString(strings.ips), tick += tickDistrib(generator), randomString(strings.paths), randomString(strings.qss), sizeDistrib(generator), - durationDistrib(generator), randomString(strings.refs), randomString(strings.uas)); + durationDistrib(generator), randomString(strings.refs), randomString(strings.uas), + randomString(strings.ct)); } } -- cgit v1.2.3