[tracker/wip/carlosg/sparql1.1: 96/113] tests: Use graph on TrackerMinerFS tests



commit b95279d6a1c5c2fc77c7ecdedf67eb029d6de684
Author: Carlos Garnacho <carlosg gnome org>
Date:   Wed Jul 17 02:15:52 2019 +0200

    tests: Use graph on TrackerMinerFS tests
    
    So it's more consistent with real usecases

 tests/libtracker-miner/tracker-miner-fs-test.c | 11 +++++++----
 1 file changed, 7 insertions(+), 4 deletions(-)
---
diff --git a/tests/libtracker-miner/tracker-miner-fs-test.c b/tests/libtracker-miner/tracker-miner-fs-test.c
index d2e48c322..39a48f959 100644
--- a/tests/libtracker-miner/tracker-miner-fs-test.c
+++ b/tests/libtracker-miner/tracker-miner-fs-test.c
@@ -78,7 +78,7 @@ test_miner_process_file (TrackerMinerFS *miner,
                g_free (urn);
        }
 
-       sparql = tracker_resource_print_sparql_update (resource, NULL, NULL);
+       sparql = tracker_resource_print_sparql_update (resource, NULL, TRACKER_OWN_GRAPH_URN);
        tracker_miner_fs_notify_finish (miner, task, sparql, NULL);
        g_object_unref (resource);
        g_free (sparql);
@@ -94,7 +94,8 @@ test_miner_remove_file (TrackerMinerFS *miner,
        gchar *sparql, *uri;
 
        uri = g_file_get_uri (file);
-       sparql = g_strdup_printf ("DELETE {"
+       sparql = g_strdup_printf ("WITH <" TRACKER_OWN_GRAPH_URN "> "
+                                 "DELETE {"
                                  "  ?u a rdfs:Resource . "
                                  "} WHERE {"
                                  "  ?u nie:url ?url ."
@@ -112,7 +113,8 @@ test_miner_remove_children (TrackerMinerFS *miner,
        gchar *sparql, *uri;
 
        uri = g_file_get_uri (file);
-       sparql = g_strdup_printf ("DELETE {"
+       sparql = g_strdup_printf ("WITH <" TRACKER_OWN_GRAPH_URN "> "
+                                 "DELETE {"
                                  "  ?u a rdfs:Resource . "
                                  "} WHERE {"
                                  "  ?u nie:url ?url ."
@@ -133,7 +135,8 @@ test_miner_move_file (TrackerMinerFS *miner,
 
        uri = g_file_get_uri (source);
        dest_uri = g_file_get_uri (dest);
-       sparql = g_strdup_printf ("DELETE {"
+       sparql = g_strdup_printf ("WITH <" TRACKER_OWN_GRAPH_URN "> "
+                                 "DELETE {"
                                  "  ?u nie:url ?url . "
                                  "} INSERT {"
                                  "  ?u nie:url '%s' . "


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