Skip to content

tests: Drop arbitrary and flaky waits from actions tests

Philip Withnall requested to merge pwithnall/glib:actions-test-fix into main

The actions test previously waited an arbitrary 100ms for various D-Bus messages to be sent/received, before checking the results of those messages.

Normally, this would work, but on heavily loaded CI systems, it would sometimes fail. For example, https://gitlab.gnome.org/GNOME/glib/-/jobs/1611701.

Fix that by waiting for the condition being checked to evaluate to true, rather than waiting an arbitrary period of time. On faster machines, this will speed the tests up too.

Assume that the global default GMainContext is in use, so a GMainContext* pointer doesn’t have to be passed around.

Signed-off-by: Philip Withnall pwithnall@endlessos.org


Also includes a fix for some tiny leaks in the test.

Merge request reports