[libdazzle] tests: cleanup after test execution



commit 9c4ba0184057139a8d4dff692ccb80771ede1004
Author: Christian Hergert <chergert redhat com>
Date:   Sun Dec 3 04:11:55 2017 -0800

    tests: cleanup after test execution
    
    We should also clean up things after execution, not just before.

 tests/test-file-transfer.c |    4 ++++
 1 files changed, 4 insertions(+), 0 deletions(-)
---
diff --git a/tests/test-file-transfer.c b/tests/test-file-transfer.c
index 9893a2e..0f512d1 100644
--- a/tests/test-file-transfer.c
+++ b/tests/test-file-transfer.c
@@ -66,6 +66,10 @@ test_basic (void)
   r = dzl_file_transfer_execute (xfer, G_PRIORITY_DEFAULT, NULL, &error);
   g_assert_no_error (error);
   g_assert_cmpint (r, ==, TRUE);
+
+  dzl_directory_reaper_execute (reaper, NULL, NULL);
+  g_assert (!g_file_query_exists (root, NULL));
+  g_assert (!g_file_query_exists (copy, NULL));
 }
 
 gint


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]