[nautilus] application: Don't migrate tracker data in self-check test



commit 0ab090ec713b89cb8effed0bf4bb24405fb6980b
Author: António Fernandes <antoniof gnome org>
Date:   Mon May 30 21:15:58 2022 +0100

    application: Don't migrate tracker data in self-check test
    
    It's not necessary and causes irrelevant CI failures.
    
    
    (cherry picked from commit 96bb917b50d53a96670b0ecf6dad2159efb33624)

 src/meson.build            | 3 ++-
 src/nautilus-application.c | 5 ++++-
 2 files changed, 6 insertions(+), 2 deletions(-)
---
diff --git a/src/meson.build b/src/meson.build
index fbd3c7735..35a0dce98 100644
--- a/src/meson.build
+++ b/src/meson.build
@@ -310,7 +310,8 @@ if get_option('tests') == 'all'
     ],
     env: [
       'G_DEBUG=fatal-warnings',
-      'GSETTINGS_SCHEMA_DIR=@0@'.format(join_paths(meson.project_build_root(), 'data'))
+      'GSETTINGS_SCHEMA_DIR=@0@'.format(join_paths(meson.project_build_root(), 'data')),
+      'RUNNING_TESTS=@0@'.format('TRUE')
     ]
   )
 endif
diff --git a/src/nautilus-application.c b/src/nautilus-application.c
index 9d4e2959d..77fd7d045 100644
--- a/src/nautilus-application.c
+++ b/src/nautilus-application.c
@@ -1260,7 +1260,10 @@ nautilus_application_startup_common (NautilusApplication *self)
 
     nautilus_init_application_actions (self);
 
-    nautilus_tag_manager_maybe_migrate_tracker2_data (priv->tag_manager);
+    if (g_strcmp0 (g_getenv ("RUNNING_TESTS"), "TRUE") != 0)
+    {
+        nautilus_tag_manager_maybe_migrate_tracker2_data (priv->tag_manager);
+    }
 
     nautilus_profile_end (NULL);
 


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