mirror of
https://gitlab.freedesktop.org/pipewire/wireplumber.git
synced 2026-01-06 02:10:13 +01:00
tests: si-standard-link: sync core before finishing
Makes sure core has finished any pending task before finishing the test.
This commit is contained in:
parent
2caac5fa87
commit
bce0b79980
1 changed files with 12 additions and 0 deletions
|
|
@ -127,9 +127,21 @@ test_si_standard_link_setup (TestFixture * f, gconstpointer user_data)
|
|||
f->sink_item = load_endpoint (f, "fakesink", "Audio/Sink");
|
||||
}
|
||||
|
||||
static void
|
||||
on_core_sync_done (WpCore *core, GAsyncResult *res, TestFixture * f)
|
||||
{
|
||||
g_autoptr (GError) error = NULL;
|
||||
gboolean ret = wp_core_sync_finish (core, res, &error);
|
||||
g_assert_no_error (error);
|
||||
g_assert_true (ret);
|
||||
g_main_loop_quit (f->base.loop);
|
||||
}
|
||||
|
||||
static void
|
||||
test_si_standard_link_teardown (TestFixture * f, gconstpointer user_data)
|
||||
{
|
||||
wp_core_sync (f->base.core, NULL, (GAsyncReadyCallback) on_core_sync_done, f);
|
||||
g_main_loop_run (f->base.loop);
|
||||
g_clear_object (&f->sink_item);
|
||||
g_clear_object (&f->src_item);
|
||||
g_clear_object (&f->session);
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue