tests: Run relayd-grouping tests by grouping type
authorKienan Stewart <kstewart@efficios.com>
Tue, 26 Sep 2023 13:39:41 +0000 (09:39 -0400)
committerJérémie Galarneau <jeremie.galarneau@efficios.com>
Fri, 8 Mar 2024 16:53:54 +0000 (11:53 -0500)
commit7e547df6a875230134157556398e767574a3da69
tree474244010443cf5f67f5ebbb6df45fc711eb96a1
parentf506900f904887310c26a441ea86352fc27242c2
tests: Run relayd-grouping tests by grouping type

Observed issue
==============

The `relayd-grouping/test_ust` test takes ~2 minutes to run. A
significant amount of that time is statring and stopping the relay and
sesion daemons.

Solution
========

Each test function is run with a different grouping setup for the
relayd. Rather than iterating over each test and then grouping
variations, the iteration can be changed to organize the tests run by
grouping setup. This allows us to start th relay and session daemons
once per grouping setup, rather than twice for each test function.

Further more, each test function is run twice: once with auto-generated
session names, once with user-defined session names. This behaviour can
be cut out to reduce the runtime of the test further.

On my development machine, the test went from running in 113s to 18s.

Known drawbacks
===============

This no longer exercises the automatic session naming. I don't think
that the automatic session naming paths are pertinent with regards to
the grouping settings; however it appears it can impact output
directories (eg. in
`test_ust_uid_streaming_snapshot_add_output_custom_name`).

Change-Id: I89d8cb224e594dd68b7e8f3367d1907ecfa2bf13
Signed-off-by: Kienan Stewart <kstewart@efficios.com>
Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
tests/regression/tools/relayd-grouping/test_ust
This page took 0.024842 seconds and 4 git commands to generate.