mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2025-12-15 12:58:29 +01:00
This fixes a race condition which frequently caused the `memory-monitor-dbus.py` test to fail. The registration of the `LowMemoryMonitor` object on the bus, and the `GMemoryMonitorDBus`’s connection to the warning signal raced, such that it was possible for the mock `LowMemoryMonitor` to emit a warning signal before the `GMemoryMonitorDBus` proxy was listening, and hence the proxy would never see the signal. Fix this by explicitly synchronising the two before proceeding to the tests. Make the same changes in the `memory-monitor-portal.py` test too, even though that one was not failing. This should remove the need for a 2s wait on every test run. Signed-off-by: Philip Withnall <pwithnall@gnome.org> Fixes: #2887
5.0 KiB
Executable File
5.0 KiB
Executable File