[tracker/wip/carlosg/libtracker-miner-cleanups: 24/36] tests: Minor update to TrackerMonitor test



commit d96d9eeccae71397d797e3e110732c3d8eea81e2
Author: Carlos Garnacho <carlosg gnome org>
Date:   Fri Oct 20 01:17:01 2017 +0200

    tests: Minor update to TrackerMonitor test
    
    Due to how the file is created, we shall get an additional UPDATED
    event that TrackerMonitor doesn't merge together anymore. This is
    now merged together in the upper layers, so just acknowledge the
    extra event in this test.

 tests/libtracker-miner/tracker-monitor-test.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/tests/libtracker-miner/tracker-monitor-test.c b/tests/libtracker-miner/tracker-monitor-test.c
index f0a6da8..828ce7c 100644
--- a/tests/libtracker-miner/tracker-monitor-test.c
+++ b/tests/libtracker-miner/tracker-monitor-test.c
@@ -427,8 +427,8 @@ test_monitor_file_event_created (TrackerMonitorTestFixture *fixture,
        g_assert_cmpuint ((file_events & MONITOR_SIGNAL_ITEM_MOVED_TO), ==, 0);
        g_assert_cmpuint ((file_events & MONITOR_SIGNAL_ITEM_DELETED), ==, 0);
 
-       /* A single CREATED event should now never trigger an UPDATED event */
-       g_assert_cmpuint ((file_events & MONITOR_SIGNAL_ITEM_UPDATED), ==, 0);
+       /* We may get an UPDATE due to the way the file is created */
+       g_assert_cmpuint ((file_events & MONITOR_SIGNAL_ITEM_UPDATED), >, 0);
        g_assert_cmpuint ((file_events & MONITOR_SIGNAL_ITEM_ATTRIBUTE_UPDATED), ==, 0);
 
        /* Cleanup environment */


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