--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/test-suite/tests/fromRdf-0009-in.nq Mon May 06 11:29:27 2013 +0200
@@ -0,0 +1,7 @@
+<http://example.com> <http://example.com/property> <http://example.com/list> .
+<http://example.com/list> <http://www.w3.org/1999/02/22-rdf-syntax-ns#first> "a" .
+<http://example.com/list> <http://www.w3.org/1999/02/22-rdf-syntax-ns#rest> _:b .
+_:b <http://www.w3.org/1999/02/22-rdf-syntax-ns#first> "b" .
+_:b <http://www.w3.org/1999/02/22-rdf-syntax-ns#rest> _:c .
+_:c <http://www.w3.org/1999/02/22-rdf-syntax-ns#first> "c" .
+_:c <http://www.w3.org/1999/02/22-rdf-syntax-ns#rest> <http://www.w3.org/1999/02/22-rdf-syntax-ns#nil> .
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/test-suite/tests/fromRdf-0009-out.jsonld Mon May 06 11:29:27 2013 +0200
@@ -0,0 +1,21 @@
+[
+ {
+ "@id": "_:b",
+ "http://www.w3.org/1999/02/22-rdf-syntax-ns#first": [ { "@value": "b" } ],
+ "http://www.w3.org/1999/02/22-rdf-syntax-ns#rest": [ { "@id": "_:c" } ]
+ },
+ {
+ "@id": "_:c",
+ "http://www.w3.org/1999/02/22-rdf-syntax-ns#first": [ { "@value": "c" } ],
+ "http://www.w3.org/1999/02/22-rdf-syntax-ns#rest": [ { "@id": "http://www.w3.org/1999/02/22-rdf-syntax-ns#nil" } ]
+ },
+ {
+ "@id": "http://example.com",
+ "http://example.com/property": [ { "@id": "http://example.com/list" } ]
+ },
+ {
+ "@id": "http://example.com/list",
+ "http://www.w3.org/1999/02/22-rdf-syntax-ns#first": [ { "@value": "a" } ],
+ "http://www.w3.org/1999/02/22-rdf-syntax-ns#rest": [ { "@id": "_:b" } ]
+ }
+]
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/test-suite/tests/fromRdf-0010-in.nq Mon May 06 11:29:27 2013 +0200
@@ -0,0 +1,6 @@
+<http://example.com> <http://example.com/property> _:a .
+_:a <http://www.w3.org/1999/02/22-rdf-syntax-ns#first> "a" .
+_:a <http://www.w3.org/1999/02/22-rdf-syntax-ns#rest> _:b .
+_:b <http://www.w3.org/1999/02/22-rdf-syntax-ns#first> "b" .
+_:b <http://www.w3.org/1999/02/22-rdf-syntax-ns#rest> _:c .
+_:c <http://www.w3.org/1999/02/22-rdf-syntax-ns#first> "c" .
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/test-suite/tests/fromRdf-0010-out.jsonld Mon May 06 11:29:27 2013 +0200
@@ -0,0 +1,20 @@
+[
+ {
+ "@id": "_:a",
+ "http://www.w3.org/1999/02/22-rdf-syntax-ns#first": [ { "@value": "a" } ],
+ "http://www.w3.org/1999/02/22-rdf-syntax-ns#rest": [ { "@id": "_:b" } ]
+ },
+ {
+ "@id": "_:b",
+ "http://www.w3.org/1999/02/22-rdf-syntax-ns#first": [ { "@value": "b" } ],
+ "http://www.w3.org/1999/02/22-rdf-syntax-ns#rest": [ { "@id": "_:c" } ]
+ },
+ {
+ "@id": "_:c",
+ "http://www.w3.org/1999/02/22-rdf-syntax-ns#first": [ { "@value": "c" } ]
+ },
+ {
+ "@id": "http://example.com",
+ "http://example.com/property": [ { "@id": "_:a" } ]
+ }
+]
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/test-suite/tests/fromRdf-0011-in.nq Mon May 06 11:29:27 2013 +0200
@@ -0,0 +1,8 @@
+<http://example.com> <http://example.com/property> _:a .
+_:a <http://www.w3.org/1999/02/22-rdf-syntax-ns#first> "a" .
+_:a <http://www.w3.org/1999/02/22-rdf-syntax-ns#rest> _:b .
+_:b <http://www.w3.org/1999/02/22-rdf-syntax-ns#first> "b" .
+_:b <http://example.com/other-property> "This list node has also properties other than rdf:first and rdf:rest" .
+_:b <http://www.w3.org/1999/02/22-rdf-syntax-ns#rest> _:c .
+_:c <http://www.w3.org/1999/02/22-rdf-syntax-ns#first> "c" .
+_:c <http://www.w3.org/1999/02/22-rdf-syntax-ns#rest> <http://www.w3.org/1999/02/22-rdf-syntax-ns#nil> .
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/test-suite/tests/fromRdf-0011-out.jsonld Mon May 06 11:29:27 2013 +0200
@@ -0,0 +1,24 @@
+[
+ {
+ "@id": "_:a",
+ "http://www.w3.org/1999/02/22-rdf-syntax-ns#first": [ { "@value": "a" } ],
+ "http://www.w3.org/1999/02/22-rdf-syntax-ns#rest": [ { "@id": "_:b" } ]
+ },
+ {
+ "@id": "_:b",
+ "http://example.com/other-property": [
+ { "@value": "This list node has also properties other than rdf:first and rdf:rest" }
+ ],
+ "http://www.w3.org/1999/02/22-rdf-syntax-ns#first": [ { "@value": "b" } ],
+ "http://www.w3.org/1999/02/22-rdf-syntax-ns#rest": [ { "@id": "_:c" } ]
+ },
+ {
+ "@id": "_:c",
+ "http://www.w3.org/1999/02/22-rdf-syntax-ns#first": [ { "@value": "c" } ],
+ "http://www.w3.org/1999/02/22-rdf-syntax-ns#rest": [ { "@id": "http://www.w3.org/1999/02/22-rdf-syntax-ns#nil" } ]
+ },
+ {
+ "@id": "http://example.com",
+ "http://example.com/property": [ { "@id": "_:a" } ]
+ }
+]
--- a/test-suite/tests/fromRdf-manifest.jsonld Mon May 06 10:57:42 2013 +0200
+++ b/test-suite/tests/fromRdf-manifest.jsonld Mon May 06 11:29:27 2013 +0200
@@ -59,9 +59,30 @@
"@id": "#t0008",
"@type": ["jld:PositiveEvaluationTest", "jld:FromRDFTest"],
"name": "Conversion of lists of lists (the triples in the input are only partially ordered on purpose)",
- "purpose": "Testing @graph recursion.",
+ "purpose": "Testing list conversion.",
"input": "fromRdf-0008-in.nq",
"expect": "fromRdf-0008-out.jsonld"
+ }, {
+ "@id": "#t0009",
+ "@type": ["jld:PositiveEvaluationTest", "jld:FromRDFTest"],
+ "name": "Do not convert lists using IRIs as list nodes to @list",
+ "purpose": "Testing list conversion.",
+ "input": "fromRdf-0009-in.nq",
+ "expect": "fromRdf-0009-out.jsonld"
+ }, {
+ "@id": "#t0010",
+ "@type": ["jld:PositiveEvaluationTest", "jld:FromRDFTest"],
+ "name": "Do not convert lists that are not terminated by rdf:nil to @list",
+ "purpose": "Testing list conversion.",
+ "input": "fromRdf-0010-in.nq",
+ "expect": "fromRdf-0010-out.jsonld"
+ }, {
+ "@id": "#t0011",
+ "@type": ["jld:PositiveEvaluationTest", "jld:FromRDFTest"],
+ "name": "Do not convert lists whose nodes have other properties to @list",
+ "purpose": "Testing list conversion.",
+ "input": "fromRdf-0011-in.nq",
+ "expect": "fromRdf-0011-out.jsonld"
}
]
}