[tracker/wip/carlosg/fixes-for-music] tests: Add test for ORDER BY an undefined variable
- From: Carlos Garnacho <carlosg src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [tracker/wip/carlosg/fixes-for-music] tests: Add test for ORDER BY an undefined variable
- Date: Sat, 17 Nov 2018 14:31:07 +0000 (UTC)
commit 0d37152b1b24badde580ddfeb5f5e7e69f6cf502
Author: Carlos Garnacho <carlosg gnome org>
Date: Sat Nov 17 14:59:59 2018 +0100
tests: Add test for ORDER BY an undefined variable
tests/libtracker-data/sort/query-sort-9.out | 8 ++++++++
tests/libtracker-data/sort/query-sort-9.rq | 5 +++++
tests/libtracker-data/tracker-sparql-test.c | 1 +
3 files changed, 14 insertions(+)
---
diff --git a/tests/libtracker-data/sort/query-sort-9.out b/tests/libtracker-data/sort/query-sort-9.out
new file mode 100644
index 000000000..754fb7f82
--- /dev/null
+++ b/tests/libtracker-data/sort/query-sort-9.out
@@ -0,0 +1,8 @@
+"alice"
+"Alice"
+"bob"
+"Bob"
+"eve"
+"Eve"
+"fred"
+"Fred"
diff --git a/tests/libtracker-data/sort/query-sort-9.rq b/tests/libtracker-data/sort/query-sort-9.rq
new file mode 100644
index 000000000..53b5aab79
--- /dev/null
+++ b/tests/libtracker-data/sort/query-sort-9.rq
@@ -0,0 +1,5 @@
+# Order by an undefined value
+PREFIX foaf: <http://xmlns.com/foaf/0.1/>
+SELECT ?name
+WHERE { ?x foaf:name ?name }
+ORDER BY ?undefined foaf:name(?x)
diff --git a/tests/libtracker-data/tracker-sparql-test.c b/tests/libtracker-data/tracker-sparql-test.c
index 1bfb5a4a4..dc65eb0c4 100644
--- a/tests/libtracker-data/tracker-sparql-test.c
+++ b/tests/libtracker-data/tracker-sparql-test.c
@@ -127,6 +127,7 @@ const TestInfo tests[] = {
{ "sort/query-sort-6", "sort/data-sort-4", FALSE },
{ "sort/query-sort-7", "sort/data-sort-1", FALSE },
{ "sort/query-sort-8", "sort/data-sort-5", FALSE },
+ { "sort/query-sort-9", "sort/data-sort-5", FALSE },
{ "subqueries/subqueries-1", "subqueries/data-1", FALSE },
{ "subqueries/subqueries-union-1", "subqueries/data-1", FALSE },
{ "subqueries/subqueries-union-2", "subqueries/data-1", FALSE },
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]