From 6f2db0e34b5aeeba8d303b8bd82e947a2daa9303 Mon Sep 17 00:00:00 2001 From: David Gibson Date: Tue, 13 Sep 2022 14:35:29 +1000 Subject: test: Move perf.js report file to $LOGDIR/web The tests generate a performance report in $BASEPATH/perf.js and hooks/pre-push copies it to the website. To avoid cluttering the working directory, instead put perf.js in $LOGDIR/web, since it's a test output artefact. Update hooks/pre-push to copy from its new location. Signed-off-by: David Gibson --- test/lib/perf_report | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'test/lib') diff --git a/test/lib/perf_report b/test/lib/perf_report index b4fa685..8fd0588 100755 --- a/test/lib/perf_report +++ b/test/lib/perf_report @@ -14,7 +14,7 @@ # Author: Stefano Brivio PERF_LINK_COUNT=0 -PERF_JS="${BASEPATH}/perf.js" +PERF_JS="${LOGDIR}/web/perf.js" PERF_TEMPLATE_HTML="document.write('"' Throughput in Gbps, latency in µs. Threads are iperf3 processes, passt and pasta are currently single-threaded.
@@ -126,6 +126,7 @@ for (var i = 0; i < perf_links.length; i++) { # perf_init() - Process first part of template perf_init() { + mkdir -p "$(dirname "${PERF_JS}")" echo "${PERF_TEMPLATE_HTML}" > "${PERF_JS}" perf_report_sub commit "$(echo ${COMMIT} | sed "s/'/\\\'/g")" } -- cgit v1.2.3