summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSam Thursfield <sam@afuera.me.uk>2018-07-16 14:07:03 +0200
committerSam Thursfield <sam@afuera.me.uk>2018-07-16 16:26:32 +0200
commit369dc65484be10c0eda4936347dc90b86f94c494 (patch)
tree7a8b913f2ccdee64f05edfb41ec784b6922867b8
parent535b843d272d88c584fed026cd9754a7d68511f4 (diff)
downloadtracker-369dc65484be10c0eda4936347dc90b86f94c494.tar.gz
tests: Turn gb-737023 test into a functional-test
This is really testing the IPC methods, so it should go with the other IPC tests which talk to a real tracker-store instance. Now the test is isolated from the user's real data, as it runs through the functional test-runner.sh script. It does still use the tracker-store from the system rather than the one we just built though, more work is needed there. The test sometimes fails due to the tracker-store disconnecting from it and GDBus triggering a SIGTERM due to the exit-on-close option being enabled on the GDBusConnection. I'm not sure how to fix that, there is an open bug here: https://gitlab.gnome.org/GNOME/tracker/issues/18
-rw-r--r--tests/functional-tests/ipc/meson.build15
-rw-r--r--tests/functional-tests/ipc/test-bus-query-cancellation.c (renamed from tests/libtracker-sparql/tracker-gb-737023-test.c)0
-rw-r--r--tests/libtracker-sparql/Makefile.am3
-rw-r--r--tests/libtracker-sparql/meson.build1
4 files changed, 16 insertions, 3 deletions
diff --git a/tests/functional-tests/ipc/meson.build b/tests/functional-tests/ipc/meson.build
index 07d02f603..e0bbe4da6 100644
--- a/tests/functional-tests/ipc/meson.build
+++ b/tests/functional-tests/ipc/meson.build
@@ -1,3 +1,8 @@
+functional_ipc_test_c_args = [
+ '-DTEST_DOMAIN_ONTOLOGY_RULE="@0@/src/tracker-store/default.rule"'.format(source_root),
+ '-DTEST_ONTOLOGIES_DIR="@0@/src/ontologies/nepomuk"'.format(source_root),
+]
+
insert_or_replace_test = executable('test-insert-or-replace',
'test-insert-or-replace.vala',
dependencies: [tracker_common_dep, tracker_sparql_dep])
@@ -53,3 +58,13 @@ update_array_performance_test = executable('test-update-array-performance',
dependencies: [tracker_common_dep, tracker_sparql_dep])
test('functional-ipc-update-array-performance', update_array_performance_test,
env: test_env)
+
+bus_query_cancellation_test = executable('test-bus-query-cancellation',
+ 'test-bus-query-cancellation.c',
+ c_args: functional_ipc_test_c_args,
+ dependencies: [tracker_common_dep, tracker_sparql_dep])
+
+test('functional-ipc-bus-query-cancellation',
+ test_runner,
+ args: bus_query_cancellation_test,
+ env: test_env)
diff --git a/tests/libtracker-sparql/tracker-gb-737023-test.c b/tests/functional-tests/ipc/test-bus-query-cancellation.c
index 0955ffc25..0955ffc25 100644
--- a/tests/libtracker-sparql/tracker-gb-737023-test.c
+++ b/tests/functional-tests/ipc/test-bus-query-cancellation.c
diff --git a/tests/libtracker-sparql/Makefile.am b/tests/libtracker-sparql/Makefile.am
index 21ecca866..56f9349b5 100644
--- a/tests/libtracker-sparql/Makefile.am
+++ b/tests/libtracker-sparql/Makefile.am
@@ -4,8 +4,7 @@ noinst_PROGRAMS += $(test_programs)
test_programs = \
tracker-resource-test \
- tracker-sparql-test \
- tracker-gb-737023-test
+ tracker-sparql-test
AM_CPPFLAGS = \
$(BUILD_CFLAGS) \
diff --git a/tests/libtracker-sparql/meson.build b/tests/libtracker-sparql/meson.build
index 00a92dd25..49b28bc98 100644
--- a/tests/libtracker-sparql/meson.build
+++ b/tests/libtracker-sparql/meson.build
@@ -1,5 +1,4 @@
libtracker_sparql_tests = [
- 'gb-737023',
'resource',
'sparql',
]