From 5d5d728ac64966600017708e3bfc93b0f7f5decd Mon Sep 17 00:00:00 2001 From: Erich Bremer Date: Thu, 16 Jul 2026 18:42:52 -0400 Subject: [PATCH 1/5] RDF 1.2 and SPARQL-CDT inputs --- RDF_1.1-compliance.md | 34 + README.md | 12 + benchmarks/rdf12-baseline-commit.txt | 1 + benchmarks/rdf12-baseline.json | 2488 +++++++++++++++++ pom.xml | 2 +- .../ebremer/beakgraph/core/lib/CdtTerms.java | 95 + .../beakgraph/core/lib/NodeComparator.java | 21 + .../writers/MultiTypeDictionaryWriter.java | 10 + .../PositionalDictionaryWriterBuilder.java | 17 + .../hdf5/writers/ultra/UltraIngest.java | 17 +- .../beakgraph/huge/HugeBuildPipeline.java | 17 + .../com/ebremer/beakgraph/huge/NodeCodec.java | 11 +- .../huge/StreamingDictionaryWriter.java | 8 + .../beakgraph/CdtBlankNodeGuardTest.java | 190 ++ .../com/ebremer/beakgraph/CdtLockInTest.java | 213 ++ .../beakgraph/RDF12ContainmentTest.java | 209 ++ .../core/lib/NodeComparatorCdtTest.java | 193 ++ .../beakgraph/huge/DirLangSpillGuardTest.java | 106 + 18 files changed, 3641 insertions(+), 3 deletions(-) create mode 100644 benchmarks/rdf12-baseline-commit.txt create mode 100644 benchmarks/rdf12-baseline.json create mode 100644 src/main/java/com/ebremer/beakgraph/core/lib/CdtTerms.java create mode 100644 src/test/java/com/ebremer/beakgraph/CdtBlankNodeGuardTest.java create mode 100644 src/test/java/com/ebremer/beakgraph/CdtLockInTest.java create mode 100644 src/test/java/com/ebremer/beakgraph/RDF12ContainmentTest.java create mode 100644 src/test/java/com/ebremer/beakgraph/core/lib/NodeComparatorCdtTest.java create mode 100644 src/test/java/com/ebremer/beakgraph/huge/DirLangSpillGuardTest.java diff --git a/RDF_1.1-compliance.md b/RDF_1.1-compliance.md index 87b57e6e..3bcb8bff 100644 --- a/RDF_1.1-compliance.md +++ b/RDF_1.1-compliance.md @@ -48,6 +48,38 @@ RDF 1.1 abstract syntax requires absolute IRIs. BeakGraph deliberately stores do ### 3. Injected metadata graphs The stored dataset is a superset of the source: VoID/SD metadata (`urn:x-beakgraph:void`) always, spatial index graphs (`urn:x-beakgraph:Spatial`, grid-tile URN graphs) when spatial indexing is enabled. Valid RDF, but `GRAPH ?g` enumerates graphs the source never contained — a faithfulness caveat rather than a spec violation. Relatedly, the `numQuads` attribute counts source quads only, excluding injected metadata. +## RDF 1.2 and SPARQL-CDT inputs + +*Added 2026-07-16. Jena 6.x parses RDF 1.2 — and, with CDTs enabled (the default), SPARQL-CDT +composite literals — whether or not the store supports them, so these terms arrive at the writers +regardless. Policy: anything the format cannot represent fails the build loudly.* + +- **Triple terms** (`<<( s p o )>>`, and the reifier/annotation sugar that expands to them): + rejected with an exception at ingest, as before. Storage is planned (PLAN.md Phase 3). +- **Base-direction literals** (`"x"@en--ltr`, `rdf:dirLangString`): rejected with an exception at + ingest in every writer engine, in both dictionary encoders, and in the disk writers' spill codec + (`RDF12ContainmentTest`, `DirLangSpillGuardTest`). **Versions ≤ 0.17.0 silently stored these as + plain lang-tagged terms** — `"x"@en`, a different RDF term, with nothing recording the change. + `-verify` cannot detect it retroactively (the file is internally consistent; it is just not what + the source said). Rebuilding an affected source under the guarded version fails loudly — that + failure is the detection mechanism. Storage is planned (PLAN.md Phase 2). +- **Language tag case**: Jena 6 normalizes language tags case-insensitively per RDF 1.2 + (`"chat"@FR` ≡ `"chat"@fr`); BeakGraph inherits this on both the write and query paths. +- **Composite (cdt:) literals** (`cdt:List` / `cdt:Map`; SPARQL-CDT is an Unofficial Draft spec): + stored term-exactly via the strings path and queryable with Jena's 16 `cdt:` functions, the + `FOLD` aggregate, and the `UNFOLD` operator (locked in by `CdtLockInTest`). Three policies: + - The dictionary orders composite literals by **(datatype IRI, lexical form)**, never by value: + CDT has no canonical form, so term identity is lexical identity, and the value comparison mixed + with its error fallback was not a total order (a verified comparator cycle; + `NodeComparatorCdtTest`). **Stores built by ≤ 0.17.0 that contain composite literals used value + order and must be rebuilt** — dictionary ids are comparator ranks, and the readers cannot + version-gate a rank change. + - **Blank nodes inside composite literals are rejected at ingest** (`CdtBlankNodeGuardTest`): + BeakGraph regenerates blank-node labels from dictionary rank, so a label inside a literal's + lexical form would silently stop co-referring with the graph, which SPARQL-CDT §5.2 requires. + - Ill-formed composite lexical forms never reach BeakGraph from documents: RIOT's CDT-aware + default profile rejects them at parse. + ## Summary table | Aspect | Status | @@ -59,6 +91,8 @@ The stored dataset is a superset of the source: VoID/SD metadata (`urn:x-beakgra | Blank node semantics | Compliant (isomorphism) | | Datasets / named graphs | Compliant | | Generalized RDF / RDF-star | Rejected loudly (correct for 1.1) | +| RDF 1.2 base-direction literals | Rejected loudly at ingest (storage planned); ≤ 0.17.0 stored them silently corrupted | +| SPARQL-CDT composite literals | Stored term-exact; lexical dictionary order (≤ 0.17.0 stores need rebuild); embedded blank nodes rejected | | Numeric literal term identity | **Deviation** — canonicalized at ingest | | Absolute-IRI requirement | **Deviation** — relative IRIs stored, resolved at serving time | | Dataset faithfulness | **Caveat** — metadata graphs injected | diff --git a/README.md b/README.md index 01e5d395..9e909d80 100644 --- a/README.md +++ b/README.md @@ -87,6 +87,18 @@ Beakgraph's HDF5 design is heavily inspired by [RDF HDT](https://www.rdfhdt.org/ * Numeric literals typed `xsd:int`, `xsd:long`, `xsd:float` or `xsd:double` are stored by value and canonicalized at ingest: `"01"^^xsd:int` is stored - and matched - as `"1"^^xsd:int`. +* RDF 1.2 terms are rejected loudly rather than mis-stored: triple terms + (`<<( s p o )>>`, including the reifier/annotation sugar) and base-direction + literals (`"x"@en--ltr`) abort the build. Versions ≤ 0.17.0 silently stored + base-direction literals as plain `"x"@en` — rebuild affected stores under a + guarded version; the loud failure is the detector. +* SPARQL-CDT composite literals (`cdt:List`/`cdt:Map`) are stored term-exactly + and queryable with Jena's `cdt:` functions, `FOLD`, and `UNFOLD`. Caveats: + the dictionary orders them lexically, so stores built by ≤ 0.17.0 that + contain composite literals must be rebuilt; blank nodes inside composite + literals are rejected at ingest (labels regenerate from rank, which would + silently sever their co-reference); and composite elements are opaque to the + index — filtering or joining inside a list/map parses the whole value in RAM. ### Author's notes The first iteration of BeakGraph was backed by Apache Arrow instead of [HDF5](https://www.hdfgroup.org/solutions/hdf5/). An Apache Arrow version will return. Reasons for this are varied with some of these reasons being just experimentation. diff --git a/benchmarks/rdf12-baseline-commit.txt b/benchmarks/rdf12-baseline-commit.txt new file mode 100644 index 00000000..d9258049 --- /dev/null +++ b/benchmarks/rdf12-baseline-commit.txt @@ -0,0 +1 @@ +df27406e8f902fff41aa0864fd149e71a0301ac2 diff --git a/benchmarks/rdf12-baseline.json b/benchmarks/rdf12-baseline.json new file mode 100644 index 00000000..5b2593bd --- /dev/null +++ b/benchmarks/rdf12-baseline.json @@ -0,0 +1,2488 @@ +[ + { + "jmhVersion" : "1.37", + "benchmark" : "com.ebremer.beakgraph.benchmarks.BitPackedBufferBench.binarySearch", + "mode" : "avgt", + "threads" : 1, + "forks" : 2, + "jvm" : "C:\\bin\\graalvm\\bin\\java.exe", + "jvmArgs" : [ + "-XX:ThreadPriorityPolicy=1", + "-XX:+UnlockExperimentalVMOptions", + "-XX:+EnableJVMCIProduct", + "-XX:+EnableJVMCI", + "-XX:-UnlockExperimentalVMOptions", + "--enable-native-access=ALL-UNNAMED", + "--sun-misc-unsafe-memory-access=allow", + "-Xmx4g" + ], + "jdkVersion" : "25.0.2", + "vmName" : "OpenJDK 64-Bit Server VM", + "vmVersion" : "25.0.2+10-jvmci-b01", + "warmupIterations" : 5, + "warmupTime" : "1 s", + "warmupBatchSize" : 1, + "measurementIterations" : 5, + "measurementTime" : "1 s", + "measurementBatchSize" : 1, + "params" : { + "width" : "7" + }, + "primaryMetric" : { + "score" : 4.931543011548851, + "scoreError" : 0.8067272590955847, + "scoreConfidence" : [ + 4.124815752453267, + 5.738270270644436 + ], + "scorePercentiles" : { + "0.0" : 4.479187236092818, + "50.0" : 4.669830007772015, + "90.0" : 5.916507962810303, + "95.0" : 5.953544246039137, + "99.0" : 5.953544246039137, + "99.9" : 5.953544246039137, + "99.99" : 5.953544246039137, + "99.999" : 5.953544246039137, + "99.9999" : 5.953544246039137, + "100.0" : 5.953544246039137 + }, + "scoreUnit" : "ns/op", + "rawData" : [ + [ + 5.583181413750797, + 4.5930546529870595, + 4.579197732820571, + 4.815243987007779, + 5.953544246039137 + ], + [ + 4.746605362556971, + 4.581298008279929, + 4.479187236092818, + 4.506068921006951, + 5.478048554946496 + ] + ] + }, + "secondaryMetrics" : { + } + }, + { + "jmhVersion" : "1.37", + "benchmark" : "com.ebremer.beakgraph.benchmarks.BitPackedBufferBench.binarySearch", + "mode" : "avgt", + "threads" : 1, + "forks" : 2, + "jvm" : "C:\\bin\\graalvm\\bin\\java.exe", + "jvmArgs" : [ + "-XX:ThreadPriorityPolicy=1", + "-XX:+UnlockExperimentalVMOptions", + "-XX:+EnableJVMCIProduct", + "-XX:+EnableJVMCI", + "-XX:-UnlockExperimentalVMOptions", + "--enable-native-access=ALL-UNNAMED", + "--sun-misc-unsafe-memory-access=allow", + "-Xmx4g" + ], + "jdkVersion" : "25.0.2", + "vmName" : "OpenJDK 64-Bit Server VM", + "vmVersion" : "25.0.2+10-jvmci-b01", + "warmupIterations" : 5, + "warmupTime" : "1 s", + "warmupBatchSize" : 1, + "measurementIterations" : 5, + "measurementTime" : "1 s", + "measurementBatchSize" : 1, + "params" : { + "width" : "13" + }, + "primaryMetric" : { + "score" : 5.650432676284349, + "scoreError" : 0.39902566831980796, + "scoreConfidence" : [ + 5.2514070079645405, + 6.049458344604157 + ], + "scorePercentiles" : { + "0.0" : 5.415637942438096, + "50.0" : 5.54825776234298, + "90.0" : 6.218766330356822, + "95.0" : 6.246952416503264, + "99.0" : 6.246952416503264, + "99.9" : 6.246952416503264, + "99.99" : 6.246952416503264, + "99.999" : 6.246952416503264, + "99.9999" : 6.246952416503264, + "100.0" : 6.246952416503264 + }, + "scoreUnit" : "ns/op", + "rawData" : [ + [ + 5.603591884456759, + 5.728265076892885, + 5.526401178110638, + 5.415637942438096, + 5.46400403824703 + ], + [ + 5.5308193005626825, + 5.565696224123278, + 5.457867146470015, + 5.965091555038843, + 6.246952416503264 + ] + ] + }, + "secondaryMetrics" : { + } + }, + { + "jmhVersion" : "1.37", + "benchmark" : "com.ebremer.beakgraph.benchmarks.BitPackedBufferBench.binarySearch", + "mode" : "avgt", + "threads" : 1, + "forks" : 2, + "jvm" : "C:\\bin\\graalvm\\bin\\java.exe", + "jvmArgs" : [ + "-XX:ThreadPriorityPolicy=1", + "-XX:+UnlockExperimentalVMOptions", + "-XX:+EnableJVMCIProduct", + "-XX:+EnableJVMCI", + "-XX:-UnlockExperimentalVMOptions", + "--enable-native-access=ALL-UNNAMED", + "--sun-misc-unsafe-memory-access=allow", + "-Xmx4g" + ], + "jdkVersion" : "25.0.2", + "vmName" : "OpenJDK 64-Bit Server VM", + "vmVersion" : "25.0.2+10-jvmci-b01", + "warmupIterations" : 5, + "warmupTime" : "1 s", + "warmupBatchSize" : 1, + "measurementIterations" : 5, + "measurementTime" : "1 s", + "measurementBatchSize" : 1, + "params" : { + "width" : "29" + }, + "primaryMetric" : { + "score" : 146.34082023340585, + "scoreError" : 1.5880397346086936, + "scoreConfidence" : [ + 144.75278049879716, + 147.92885996801454 + ], + "scorePercentiles" : { + "0.0" : 145.50198781508385, + "50.0" : 146.11904421022874, + "90.0" : 148.85863918283007, + "95.0" : 149.10419233229877, + "99.0" : 149.10419233229877, + "99.9" : 149.10419233229877, + "99.99" : 149.10419233229877, + "99.999" : 149.10419233229877, + "99.9999" : 149.10419233229877, + "100.0" : 149.10419233229877 + }, + "scoreUnit" : "ns/op", + "rawData" : [ + [ + 146.1013722062062, + 146.64866083761183, + 145.50198781508385, + 145.519953316269, + 146.50943791098823 + ], + [ + 146.0869801874766, + 145.55308133433272, + 146.24582017954017, + 146.13671621425127, + 149.10419233229877 + ] + ] + }, + "secondaryMetrics" : { + } + }, + { + "jmhVersion" : "1.37", + "benchmark" : "com.ebremer.beakgraph.benchmarks.BitPackedBufferBench.binarySearch", + "mode" : "avgt", + "threads" : 1, + "forks" : 2, + "jvm" : "C:\\bin\\graalvm\\bin\\java.exe", + "jvmArgs" : [ + "-XX:ThreadPriorityPolicy=1", + "-XX:+UnlockExperimentalVMOptions", + "-XX:+EnableJVMCIProduct", + "-XX:+EnableJVMCI", + "-XX:-UnlockExperimentalVMOptions", + "--enable-native-access=ALL-UNNAMED", + "--sun-misc-unsafe-memory-access=allow", + "-Xmx4g" + ], + "jdkVersion" : "25.0.2", + "vmName" : "OpenJDK 64-Bit Server VM", + "vmVersion" : "25.0.2+10-jvmci-b01", + "warmupIterations" : 5, + "warmupTime" : "1 s", + "warmupBatchSize" : 1, + "measurementIterations" : 5, + "measurementTime" : "1 s", + "measurementBatchSize" : 1, + "params" : { + "width" : "41" + }, + "primaryMetric" : { + "score" : 152.04132389859998, + "scoreError" : 3.287659024849761, + "scoreConfidence" : [ + 148.7536648737502, + 155.32898292344976 + ], + "scorePercentiles" : { + "0.0" : 149.71501482691633, + "50.0" : 151.76291066792317, + "90.0" : 156.65263568746013, + "95.0" : 157.000829903364, + "99.0" : 157.000829903364, + "99.9" : 157.000829903364, + "99.99" : 157.000829903364, + "99.999" : 157.000829903364, + "99.9999" : 157.000829903364, + "100.0" : 157.000829903364 + }, + "scoreUnit" : "ns/op", + "rawData" : [ + [ + 152.34206653061622, + 152.56742822703947, + 157.000829903364, + 150.46103671126207, + 152.8554094643248 + ], + [ + 149.83022560321407, + 153.5188877443253, + 150.9385851697075, + 151.18375480523014, + 149.71501482691633 + ] + ] + }, + "secondaryMetrics" : { + } + }, + { + "jmhVersion" : "1.37", + "benchmark" : "com.ebremer.beakgraph.benchmarks.BitPackedBufferBench.randomGet", + "mode" : "avgt", + "threads" : 1, + "forks" : 2, + "jvm" : "C:\\bin\\graalvm\\bin\\java.exe", + "jvmArgs" : [ + "-XX:ThreadPriorityPolicy=1", + "-XX:+UnlockExperimentalVMOptions", + "-XX:+EnableJVMCIProduct", + "-XX:+EnableJVMCI", + "-XX:-UnlockExperimentalVMOptions", + "--enable-native-access=ALL-UNNAMED", + "--sun-misc-unsafe-memory-access=allow", + "-Xmx4g" + ], + "jdkVersion" : "25.0.2", + "vmName" : "OpenJDK 64-Bit Server VM", + "vmVersion" : "25.0.2+10-jvmci-b01", + "warmupIterations" : 5, + "warmupTime" : "1 s", + "warmupBatchSize" : 1, + "measurementIterations" : 5, + "measurementTime" : "1 s", + "measurementBatchSize" : 1, + "params" : { + "width" : "7" + }, + "primaryMetric" : { + "score" : 4.74277586331917, + "scoreError" : 0.8112748988697254, + "scoreConfidence" : [ + 3.9315009644494445, + 5.554050762188895 + ], + "scorePercentiles" : { + "0.0" : 4.479469042919341, + "50.0" : 4.591876824192557, + "90.0" : 6.1016024975285506, + "95.0" : 6.254129806675068, + "99.0" : 6.254129806675068, + "99.9" : 6.254129806675068, + "99.99" : 6.254129806675068, + "99.999" : 6.254129806675068, + "99.9999" : 6.254129806675068, + "100.0" : 6.254129806675068 + }, + "scoreUnit" : "ns/op", + "rawData" : [ + [ + 4.479469042919341, + 4.528106448436557, + 4.483100816230686, + 4.601204813258694, + 4.517417564595311 + ], + [ + 4.728856715209888, + 6.254129806675068, + 4.5825488351264205, + 4.645778690099771, + 4.60714590063996 + ] + ] + }, + "secondaryMetrics" : { + } + }, + { + "jmhVersion" : "1.37", + "benchmark" : "com.ebremer.beakgraph.benchmarks.BitPackedBufferBench.randomGet", + "mode" : "avgt", + "threads" : 1, + "forks" : 2, + "jvm" : "C:\\bin\\graalvm\\bin\\java.exe", + "jvmArgs" : [ + "-XX:ThreadPriorityPolicy=1", + "-XX:+UnlockExperimentalVMOptions", + "-XX:+EnableJVMCIProduct", + "-XX:+EnableJVMCI", + "-XX:-UnlockExperimentalVMOptions", + "--enable-native-access=ALL-UNNAMED", + "--sun-misc-unsafe-memory-access=allow", + "-Xmx4g" + ], + "jdkVersion" : "25.0.2", + "vmName" : "OpenJDK 64-Bit Server VM", + "vmVersion" : "25.0.2+10-jvmci-b01", + "warmupIterations" : 5, + "warmupTime" : "1 s", + "warmupBatchSize" : 1, + "measurementIterations" : 5, + "measurementTime" : "1 s", + "measurementBatchSize" : 1, + "params" : { + "width" : "13" + }, + "primaryMetric" : { + "score" : 5.135278500892655, + "scoreError" : 0.40776243186584943, + "scoreConfidence" : [ + 4.727516069026805, + 5.543040932758505 + ], + "scorePercentiles" : { + "0.0" : 4.842117059171336, + "50.0" : 5.120364761373173, + "90.0" : 5.44433753295888, + "95.0" : 5.446545233925745, + "99.0" : 5.446545233925745, + "99.9" : 5.446545233925745, + "99.99" : 5.446545233925745, + "99.999" : 5.446545233925745, + "99.9999" : 5.446545233925745, + "100.0" : 5.446545233925745 + }, + "scoreUnit" : "ns/op", + "rawData" : [ + [ + 5.321950427513797, + 5.379452377657007, + 5.424468224257089, + 5.446545233925745, + 5.3690770919254245 + ], + [ + 4.895059346331449, + 4.842117059171336, + 4.918779095232549, + 4.8477051920341445, + 4.907630960877997 + ] + ] + }, + "secondaryMetrics" : { + } + }, + { + "jmhVersion" : "1.37", + "benchmark" : "com.ebremer.beakgraph.benchmarks.BitPackedBufferBench.randomGet", + "mode" : "avgt", + "threads" : 1, + "forks" : 2, + "jvm" : "C:\\bin\\graalvm\\bin\\java.exe", + "jvmArgs" : [ + "-XX:ThreadPriorityPolicy=1", + "-XX:+UnlockExperimentalVMOptions", + "-XX:+EnableJVMCIProduct", + "-XX:+EnableJVMCI", + "-XX:-UnlockExperimentalVMOptions", + "--enable-native-access=ALL-UNNAMED", + "--sun-misc-unsafe-memory-access=allow", + "-Xmx4g" + ], + "jdkVersion" : "25.0.2", + "vmName" : "OpenJDK 64-Bit Server VM", + "vmVersion" : "25.0.2+10-jvmci-b01", + "warmupIterations" : 5, + "warmupTime" : "1 s", + "warmupBatchSize" : 1, + "measurementIterations" : 5, + "measurementTime" : "1 s", + "measurementBatchSize" : 1, + "params" : { + "width" : "29" + }, + "primaryMetric" : { + "score" : 5.185144997774445, + "scoreError" : 0.10843605497444382, + "scoreConfidence" : [ + 5.076708942800001, + 5.2935810527488885 + ], + "scorePercentiles" : { + "0.0" : 5.082154481836256, + "50.0" : 5.18394463978478, + "90.0" : 5.32562724940285, + "95.0" : 5.336524112916544, + "99.0" : 5.336524112916544, + "99.9" : 5.336524112916544, + "99.99" : 5.336524112916544, + "99.999" : 5.336524112916544, + "99.9999" : 5.336524112916544, + "100.0" : 5.336524112916544 + }, + "scoreUnit" : "ns/op", + "rawData" : [ + [ + 5.220321225420143, + 5.210001678913161, + 5.209300380787385, + 5.140285709378365, + 5.082154481836256 + ], + [ + 5.1182352918780785, + 5.227555477779602, + 5.336524112916544, + 5.158588898782176, + 5.148482720052733 + ] + ] + }, + "secondaryMetrics" : { + } + }, + { + "jmhVersion" : "1.37", + "benchmark" : "com.ebremer.beakgraph.benchmarks.BitPackedBufferBench.randomGet", + "mode" : "avgt", + "threads" : 1, + "forks" : 2, + "jvm" : "C:\\bin\\graalvm\\bin\\java.exe", + "jvmArgs" : [ + "-XX:ThreadPriorityPolicy=1", + "-XX:+UnlockExperimentalVMOptions", + "-XX:+EnableJVMCIProduct", + "-XX:+EnableJVMCI", + "-XX:-UnlockExperimentalVMOptions", + "--enable-native-access=ALL-UNNAMED", + "--sun-misc-unsafe-memory-access=allow", + "-Xmx4g" + ], + "jdkVersion" : "25.0.2", + "vmName" : "OpenJDK 64-Bit Server VM", + "vmVersion" : "25.0.2+10-jvmci-b01", + "warmupIterations" : 5, + "warmupTime" : "1 s", + "warmupBatchSize" : 1, + "measurementIterations" : 5, + "measurementTime" : "1 s", + "measurementBatchSize" : 1, + "params" : { + "width" : "41" + }, + "primaryMetric" : { + "score" : 5.2437424406382185, + "scoreError" : 0.20055962545256867, + "scoreConfidence" : [ + 5.0431828151856495, + 5.4443020660907875 + ], + "scorePercentiles" : { + "0.0" : 5.142837931551755, + "50.0" : 5.216148113713453, + "90.0" : 5.559908261920209, + "95.0" : 5.588205348973433, + "99.0" : 5.588205348973433, + "99.9" : 5.588205348973433, + "99.99" : 5.588205348973433, + "99.999" : 5.588205348973433, + "99.9999" : 5.588205348973433, + "100.0" : 5.588205348973433 + }, + "scoreUnit" : "ns/op", + "rawData" : [ + [ + 5.240141888181142, + 5.305234478441196, + 5.142837931551755, + 5.151928054696875, + 5.17626581627851 + ], + [ + 5.192154339245764, + 5.250420609392748, + 5.588205348973433, + 5.24676354691729, + 5.1434723927034645 + ] + ] + }, + "secondaryMetrics" : { + } + }, + { + "jmhVersion" : "1.37", + "benchmark" : "com.ebremer.beakgraph.benchmarks.BitPackedBufferBench.sequentialSumViaGet", + "mode" : "avgt", + "threads" : 1, + "forks" : 2, + "jvm" : "C:\\bin\\graalvm\\bin\\java.exe", + "jvmArgs" : [ + "-XX:ThreadPriorityPolicy=1", + "-XX:+UnlockExperimentalVMOptions", + "-XX:+EnableJVMCIProduct", + "-XX:+EnableJVMCI", + "-XX:-UnlockExperimentalVMOptions", + "--enable-native-access=ALL-UNNAMED", + "--sun-misc-unsafe-memory-access=allow", + "-Xmx4g" + ], + "jdkVersion" : "25.0.2", + "vmName" : "OpenJDK 64-Bit Server VM", + "vmVersion" : "25.0.2+10-jvmci-b01", + "warmupIterations" : 5, + "warmupTime" : "1 s", + "warmupBatchSize" : 1, + "measurementIterations" : 5, + "measurementTime" : "1 s", + "measurementBatchSize" : 1, + "params" : { + "width" : "7" + }, + "primaryMetric" : { + "score" : 2.776310257701158, + "scoreError" : 0.07464921467705923, + "scoreConfidence" : [ + 2.7016610430240986, + 2.850959472378217 + ], + "scorePercentiles" : { + "0.0" : 2.6905218312438106, + "50.0" : 2.7893306202971178, + "90.0" : 2.8269247015899928, + "95.0" : 2.827508148909314, + "99.0" : 2.827508148909314, + "99.9" : 2.827508148909314, + "99.99" : 2.827508148909314, + "99.999" : 2.827508148909314, + "99.9999" : 2.827508148909314, + "100.0" : 2.827508148909314 + }, + "scoreUnit" : "ns/op", + "rawData" : [ + [ + 2.8178919193356537, + 2.827508148909314, + 2.8094005306677636, + 2.8216736757160983, + 2.791850415268385 + ], + [ + 2.7868108253258503, + 2.7743452873782837, + 2.6905218312438106, + 2.70249688253862, + 2.740603060627794 + ] + ] + }, + "secondaryMetrics" : { + } + }, + { + "jmhVersion" : "1.37", + "benchmark" : "com.ebremer.beakgraph.benchmarks.BitPackedBufferBench.sequentialSumViaGet", + "mode" : "avgt", + "threads" : 1, + "forks" : 2, + "jvm" : "C:\\bin\\graalvm\\bin\\java.exe", + "jvmArgs" : [ + "-XX:ThreadPriorityPolicy=1", + "-XX:+UnlockExperimentalVMOptions", + "-XX:+EnableJVMCIProduct", + "-XX:+EnableJVMCI", + "-XX:-UnlockExperimentalVMOptions", + "--enable-native-access=ALL-UNNAMED", + "--sun-misc-unsafe-memory-access=allow", + "-Xmx4g" + ], + "jdkVersion" : "25.0.2", + "vmName" : "OpenJDK 64-Bit Server VM", + "vmVersion" : "25.0.2+10-jvmci-b01", + "warmupIterations" : 5, + "warmupTime" : "1 s", + "warmupBatchSize" : 1, + "measurementIterations" : 5, + "measurementTime" : "1 s", + "measurementBatchSize" : 1, + "params" : { + "width" : "13" + }, + "primaryMetric" : { + "score" : 2.7878018589971885, + "scoreError" : 0.038800153426031096, + "scoreConfidence" : [ + 2.7490017055711573, + 2.8266020124232196 + ], + "scorePercentiles" : { + "0.0" : 2.746622670780529, + "50.0" : 2.784558781624358, + "90.0" : 2.83158340168871, + "95.0" : 2.8331711844614875, + "99.0" : 2.8331711844614875, + "99.9" : 2.8331711844614875, + "99.99" : 2.8331711844614875, + "99.999" : 2.8331711844614875, + "99.9999" : 2.8331711844614875, + "100.0" : 2.8331711844614875 + }, + "scoreUnit" : "ns/op", + "rawData" : [ + [ + 2.8331711844614875, + 2.7813238094450763, + 2.762290878077291, + 2.7939220384366252, + 2.80439299206401 + ], + [ + 2.746622670780529, + 2.78779375380364, + 2.774972943132824, + 2.776234963036686, + 2.8172933567337126 + ] + ] + }, + "secondaryMetrics" : { + } + }, + { + "jmhVersion" : "1.37", + "benchmark" : "com.ebremer.beakgraph.benchmarks.BitPackedBufferBench.sequentialSumViaGet", + "mode" : "avgt", + "threads" : 1, + "forks" : 2, + "jvm" : "C:\\bin\\graalvm\\bin\\java.exe", + "jvmArgs" : [ + "-XX:ThreadPriorityPolicy=1", + "-XX:+UnlockExperimentalVMOptions", + "-XX:+EnableJVMCIProduct", + "-XX:+EnableJVMCI", + "-XX:-UnlockExperimentalVMOptions", + "--enable-native-access=ALL-UNNAMED", + "--sun-misc-unsafe-memory-access=allow", + "-Xmx4g" + ], + "jdkVersion" : "25.0.2", + "vmName" : "OpenJDK 64-Bit Server VM", + "vmVersion" : "25.0.2+10-jvmci-b01", + "warmupIterations" : 5, + "warmupTime" : "1 s", + "warmupBatchSize" : 1, + "measurementIterations" : 5, + "measurementTime" : "1 s", + "measurementBatchSize" : 1, + "params" : { + "width" : "29" + }, + "primaryMetric" : { + "score" : 2.808765482154736, + "scoreError" : 0.05595024286158045, + "scoreConfidence" : [ + 2.7528152392931555, + 2.864715725016316 + ], + "scorePercentiles" : { + "0.0" : 2.772566093795601, + "50.0" : 2.8092326395498333, + "90.0" : 2.8856577315242493, + "95.0" : 2.891846841840602, + "99.0" : 2.891846841840602, + "99.9" : 2.891846841840602, + "99.99" : 2.891846841840602, + "99.999" : 2.891846841840602, + "99.9999" : 2.891846841840602, + "100.0" : 2.891846841840602 + }, + "scoreUnit" : "ns/op", + "rawData" : [ + [ + 2.808978945709938, + 2.774233379583249, + 2.8299557386770755, + 2.7785669486186, + 2.891846841840602 + ], + [ + 2.7758159856686646, + 2.772566093795601, + 2.8175164937277923, + 2.8094863333897284, + 2.828688060536104 + ] + ] + }, + "secondaryMetrics" : { + } + }, + { + "jmhVersion" : "1.37", + "benchmark" : "com.ebremer.beakgraph.benchmarks.BitPackedBufferBench.sequentialSumViaGet", + "mode" : "avgt", + "threads" : 1, + "forks" : 2, + "jvm" : "C:\\bin\\graalvm\\bin\\java.exe", + "jvmArgs" : [ + "-XX:ThreadPriorityPolicy=1", + "-XX:+UnlockExperimentalVMOptions", + "-XX:+EnableJVMCIProduct", + "-XX:+EnableJVMCI", + "-XX:-UnlockExperimentalVMOptions", + "--enable-native-access=ALL-UNNAMED", + "--sun-misc-unsafe-memory-access=allow", + "-Xmx4g" + ], + "jdkVersion" : "25.0.2", + "vmName" : "OpenJDK 64-Bit Server VM", + "vmVersion" : "25.0.2+10-jvmci-b01", + "warmupIterations" : 5, + "warmupTime" : "1 s", + "warmupBatchSize" : 1, + "measurementIterations" : 5, + "measurementTime" : "1 s", + "measurementBatchSize" : 1, + "params" : { + "width" : "41" + }, + "primaryMetric" : { + "score" : 2.788332791111629, + "scoreError" : 0.056151958575257115, + "scoreConfidence" : [ + 2.732180832536372, + 2.8444847496868864 + ], + "scorePercentiles" : { + "0.0" : 2.7297461373465404, + "50.0" : 2.7840190762385864, + "90.0" : 2.852487109956287, + "95.0" : 2.853806813557943, + "99.0" : 2.853806813557943, + "99.9" : 2.853806813557943, + "99.99" : 2.853806813557943, + "99.999" : 2.853806813557943, + "99.9999" : 2.853806813557943, + "100.0" : 2.853806813557943 + }, + "scoreUnit" : "ns/op", + "rawData" : [ + [ + 2.7841458059525284, + 2.8041289082073955, + 2.7674568110498887, + 2.7838923465246443, + 2.853806813557943 + ], + [ + 2.759765016387331, + 2.791755609540133, + 2.7680206850084956, + 2.7297461373465404, + 2.8406097775413874 + ] + ] + }, + "secondaryMetrics" : { + } + }, + { + "jmhVersion" : "1.37", + "benchmark" : "com.ebremer.beakgraph.benchmarks.BitPackedBufferBench.sequentialSumViaStream", + "mode" : "avgt", + "threads" : 1, + "forks" : 2, + "jvm" : "C:\\bin\\graalvm\\bin\\java.exe", + "jvmArgs" : [ + "-XX:ThreadPriorityPolicy=1", + "-XX:+UnlockExperimentalVMOptions", + "-XX:+EnableJVMCIProduct", + "-XX:+EnableJVMCI", + "-XX:-UnlockExperimentalVMOptions", + "--enable-native-access=ALL-UNNAMED", + "--sun-misc-unsafe-memory-access=allow", + "-Xmx4g" + ], + "jdkVersion" : "25.0.2", + "vmName" : "OpenJDK 64-Bit Server VM", + "vmVersion" : "25.0.2+10-jvmci-b01", + "warmupIterations" : 5, + "warmupTime" : "1 s", + "warmupBatchSize" : 1, + "measurementIterations" : 5, + "measurementTime" : "1 s", + "measurementBatchSize" : 1, + "params" : { + "width" : "7" + }, + "primaryMetric" : { + "score" : 2.0987236996890455, + "scoreError" : 0.045004821953549934, + "scoreConfidence" : [ + 2.0537188777354958, + 2.143728521642595 + ], + "scorePercentiles" : { + "0.0" : 2.0519530824325627, + "50.0" : 2.1007528648769282, + "90.0" : 2.152577532495975, + "95.0" : 2.1556860662896535, + "99.0" : 2.1556860662896535, + "99.9" : 2.1556860662896535, + "99.99" : 2.1556860662896535, + "99.999" : 2.1556860662896535, + "99.9999" : 2.1556860662896535, + "100.0" : 2.1556860662896535 + }, + "scoreUnit" : "ns/op", + "rawData" : [ + [ + 2.0519530824325627, + 2.1556860662896535, + 2.0963857484900434, + 2.106251509293266, + 2.0701269782804874 + ], + [ + 2.105119981263813, + 2.071134453145867, + 2.0941870848682593, + 2.111791364473639, + 2.1246007283528647 + ] + ] + }, + "secondaryMetrics" : { + } + }, + { + "jmhVersion" : "1.37", + "benchmark" : "com.ebremer.beakgraph.benchmarks.BitPackedBufferBench.sequentialSumViaStream", + "mode" : "avgt", + "threads" : 1, + "forks" : 2, + "jvm" : "C:\\bin\\graalvm\\bin\\java.exe", + "jvmArgs" : [ + "-XX:ThreadPriorityPolicy=1", + "-XX:+UnlockExperimentalVMOptions", + "-XX:+EnableJVMCIProduct", + "-XX:+EnableJVMCI", + "-XX:-UnlockExperimentalVMOptions", + "--enable-native-access=ALL-UNNAMED", + "--sun-misc-unsafe-memory-access=allow", + "-Xmx4g" + ], + "jdkVersion" : "25.0.2", + "vmName" : "OpenJDK 64-Bit Server VM", + "vmVersion" : "25.0.2+10-jvmci-b01", + "warmupIterations" : 5, + "warmupTime" : "1 s", + "warmupBatchSize" : 1, + "measurementIterations" : 5, + "measurementTime" : "1 s", + "measurementBatchSize" : 1, + "params" : { + "width" : "13" + }, + "primaryMetric" : { + "score" : 2.907712034536061, + "scoreError" : 0.35443547802149855, + "scoreConfidence" : [ + 2.5532765565145628, + 3.2621475125575596 + ], + "scorePercentiles" : { + "0.0" : 2.771047193204776, + "50.0" : 2.8218428575469288, + "90.0" : 3.4857126013632933, + "95.0" : 3.545376459757487, + "99.0" : 3.545376459757487, + "99.9" : 3.545376459757487, + "99.99" : 3.545376459757487, + "99.999" : 3.545376459757487, + "99.9999" : 3.545376459757487, + "100.0" : 3.545376459757487 + }, + "scoreUnit" : "ns/op", + "rawData" : [ + [ + 2.774232301466103, + 2.8039635613907214, + 2.9056457427886873, + 2.932990865504488, + 3.545376459757487 + ], + [ + 2.780776188291352, + 2.774628003438314, + 2.8397221537031365, + 2.771047193204776, + 2.9487378758155494 + ] + ] + }, + "secondaryMetrics" : { + } + }, + { + "jmhVersion" : "1.37", + "benchmark" : "com.ebremer.beakgraph.benchmarks.BitPackedBufferBench.sequentialSumViaStream", + "mode" : "avgt", + "threads" : 1, + "forks" : 2, + "jvm" : "C:\\bin\\graalvm\\bin\\java.exe", + "jvmArgs" : [ + "-XX:ThreadPriorityPolicy=1", + "-XX:+UnlockExperimentalVMOptions", + "-XX:+EnableJVMCIProduct", + "-XX:+EnableJVMCI", + "-XX:-UnlockExperimentalVMOptions", + "--enable-native-access=ALL-UNNAMED", + "--sun-misc-unsafe-memory-access=allow", + "-Xmx4g" + ], + "jdkVersion" : "25.0.2", + "vmName" : "OpenJDK 64-Bit Server VM", + "vmVersion" : "25.0.2+10-jvmci-b01", + "warmupIterations" : 5, + "warmupTime" : "1 s", + "warmupBatchSize" : 1, + "measurementIterations" : 5, + "measurementTime" : "1 s", + "measurementBatchSize" : 1, + "params" : { + "width" : "29" + }, + "primaryMetric" : { + "score" : 4.84665898300103, + "scoreError" : 0.4181284699949852, + "scoreConfidence" : [ + 4.428530513006044, + 5.264787452996015 + ], + "scorePercentiles" : { + "0.0" : 4.665674283666518, + "50.0" : 4.777575637699211, + "90.0" : 5.5283827073323994, + "95.0" : 5.597257059673931, + "99.0" : 5.597257059673931, + "99.9" : 5.597257059673931, + "99.99" : 5.597257059673931, + "99.999" : 5.597257059673931, + "99.9999" : 5.597257059673931, + "100.0" : 5.597257059673931 + }, + "scoreUnit" : "ns/op", + "rawData" : [ + [ + 4.676684780397277, + 4.665674283666518, + 4.88309282245058, + 4.680382626727947, + 4.716221958983178 + ], + [ + 4.780739281565098, + 4.774411993833324, + 4.90851353625862, + 5.597257059673931, + 4.783611486453821 + ] + ] + }, + "secondaryMetrics" : { + } + }, + { + "jmhVersion" : "1.37", + "benchmark" : "com.ebremer.beakgraph.benchmarks.BitPackedBufferBench.sequentialSumViaStream", + "mode" : "avgt", + "threads" : 1, + "forks" : 2, + "jvm" : "C:\\bin\\graalvm\\bin\\java.exe", + "jvmArgs" : [ + "-XX:ThreadPriorityPolicy=1", + "-XX:+UnlockExperimentalVMOptions", + "-XX:+EnableJVMCIProduct", + "-XX:+EnableJVMCI", + "-XX:-UnlockExperimentalVMOptions", + "--enable-native-access=ALL-UNNAMED", + "--sun-misc-unsafe-memory-access=allow", + "-Xmx4g" + ], + "jdkVersion" : "25.0.2", + "vmName" : "OpenJDK 64-Bit Server VM", + "vmVersion" : "25.0.2+10-jvmci-b01", + "warmupIterations" : 5, + "warmupTime" : "1 s", + "warmupBatchSize" : 1, + "measurementIterations" : 5, + "measurementTime" : "1 s", + "measurementBatchSize" : 1, + "params" : { + "width" : "41" + }, + "primaryMetric" : { + "score" : 6.200591953028527, + "scoreError" : 0.16601464742971284, + "scoreConfidence" : [ + 6.034577305598814, + 6.3666066004582405 + ], + "scorePercentiles" : { + "0.0" : 6.112278564066827, + "50.0" : 6.166913706785555, + "90.0" : 6.456897589448211, + "95.0" : 6.476793924967448, + "99.0" : 6.476793924967448, + "99.9" : 6.476793924967448, + "99.99" : 6.476793924967448, + "99.999" : 6.476793924967448, + "99.9999" : 6.476793924967448, + "100.0" : 6.476793924967448 + }, + "scoreUnit" : "ns/op", + "rawData" : [ + [ + 6.161980112646796, + 6.277830569775073, + 6.227258583167931, + 6.116537835187973, + 6.141652271246454 + ], + [ + 6.131721909638423, + 6.188018458664038, + 6.1718473009243136, + 6.476793924967448, + 6.112278564066827 + ] + ] + }, + "secondaryMetrics" : { + } + }, + { + "jmhVersion" : "1.37", + "benchmark" : "com.ebremer.beakgraph.benchmarks.DictionaryBench.entityLocateHit", + "mode" : "avgt", + "threads" : 1, + "forks" : 2, + "jvm" : "C:\\bin\\graalvm\\bin\\java.exe", + "jvmArgs" : [ + "-XX:ThreadPriorityPolicy=1", + "-XX:+UnlockExperimentalVMOptions", + "-XX:+EnableJVMCIProduct", + "-XX:+EnableJVMCI", + "-XX:-UnlockExperimentalVMOptions", + "--enable-native-access=ALL-UNNAMED", + "--sun-misc-unsafe-memory-access=allow", + "-Xmx4g" + ], + "jdkVersion" : "25.0.2", + "vmName" : "OpenJDK 64-Bit Server VM", + "vmVersion" : "25.0.2+10-jvmci-b01", + "warmupIterations" : 5, + "warmupTime" : "1 s", + "warmupBatchSize" : 1, + "measurementIterations" : 5, + "measurementTime" : "1 s", + "measurementBatchSize" : 1, + "params" : { + "subjects" : "50000" + }, + "primaryMetric" : { + "score" : 17.921916312125173, + "scoreError" : 1.5779246864067542, + "scoreConfidence" : [ + 16.34399162571842, + 19.499840998531926 + ], + "scorePercentiles" : { + "0.0" : 16.896621038382424, + "50.0" : 17.77399778945945, + "90.0" : 20.243661721619247, + "95.0" : 20.44327276539097, + "99.0" : 20.44327276539097, + "99.9" : 20.44327276539097, + "99.99" : 20.44327276539097, + "99.999" : 20.44327276539097, + "99.9999" : 20.44327276539097, + "100.0" : 20.44327276539097 + }, + "scoreUnit" : "ns/op", + "rawData" : [ + [ + 17.27913592696815, + 17.738288285492928, + 17.01635322177992, + 17.809707293425973, + 18.447162327673762 + ], + [ + 20.44327276539097, + 18.414957703196258, + 17.155409261338676, + 18.018255297602675, + 16.896621038382424 + ] + ] + }, + "secondaryMetrics" : { + } + }, + { + "jmhVersion" : "1.37", + "benchmark" : "com.ebremer.beakgraph.benchmarks.DictionaryBench.extractEntity", + "mode" : "avgt", + "threads" : 1, + "forks" : 2, + "jvm" : "C:\\bin\\graalvm\\bin\\java.exe", + "jvmArgs" : [ + "-XX:ThreadPriorityPolicy=1", + "-XX:+UnlockExperimentalVMOptions", + "-XX:+EnableJVMCIProduct", + "-XX:+EnableJVMCI", + "-XX:-UnlockExperimentalVMOptions", + "--enable-native-access=ALL-UNNAMED", + "--sun-misc-unsafe-memory-access=allow", + "-Xmx4g" + ], + "jdkVersion" : "25.0.2", + "vmName" : "OpenJDK 64-Bit Server VM", + "vmVersion" : "25.0.2+10-jvmci-b01", + "warmupIterations" : 5, + "warmupTime" : "1 s", + "warmupBatchSize" : 1, + "measurementIterations" : 5, + "measurementTime" : "1 s", + "measurementBatchSize" : 1, + "params" : { + "subjects" : "50000" + }, + "primaryMetric" : { + "score" : 79.21575971216619, + "scoreError" : 12.188607997253742, + "scoreConfidence" : [ + 67.02715171491245, + 91.40436770941993 + ], + "scorePercentiles" : { + "0.0" : 70.23469425798106, + "50.0" : 77.26564782770282, + "90.0" : 93.59421321807831, + "95.0" : 93.75863957228142, + "99.0" : 93.75863957228142, + "99.9" : 93.75863957228142, + "99.99" : 93.75863957228142, + "99.999" : 93.75863957228142, + "99.9999" : 93.75863957228142, + "100.0" : 93.75863957228142 + }, + "scoreUnit" : "ns/op", + "rawData" : [ + [ + 74.92573312345766, + 73.6152425738888, + 70.23469425798106, + 92.11437603025023, + 93.75863957228142 + ], + [ + 77.66727918539559, + 77.5612998928319, + 72.10470499696221, + 83.20563172603916, + 76.96999576257375 + ] + ] + }, + "secondaryMetrics" : { + } + }, + { + "jmhVersion" : "1.37", + "benchmark" : "com.ebremer.beakgraph.benchmarks.DictionaryBench.extractObject", + "mode" : "avgt", + "threads" : 1, + "forks" : 2, + "jvm" : "C:\\bin\\graalvm\\bin\\java.exe", + "jvmArgs" : [ + "-XX:ThreadPriorityPolicy=1", + "-XX:+UnlockExperimentalVMOptions", + "-XX:+EnableJVMCIProduct", + "-XX:+EnableJVMCI", + "-XX:-UnlockExperimentalVMOptions", + "--enable-native-access=ALL-UNNAMED", + "--sun-misc-unsafe-memory-access=allow", + "-Xmx4g" + ], + "jdkVersion" : "25.0.2", + "vmName" : "OpenJDK 64-Bit Server VM", + "vmVersion" : "25.0.2+10-jvmci-b01", + "warmupIterations" : 5, + "warmupTime" : "1 s", + "warmupBatchSize" : 1, + "measurementIterations" : 5, + "measurementTime" : "1 s", + "measurementBatchSize" : 1, + "params" : { + "subjects" : "50000" + }, + "primaryMetric" : { + "score" : 106.40917838425312, + "scoreError" : 16.835973554881537, + "scoreConfidence" : [ + 89.57320482937159, + 123.24515193913466 + ], + "scorePercentiles" : { + "0.0" : 94.74848754160172, + "50.0" : 103.27490832768734, + "90.0" : 126.86464181050465, + "95.0" : 126.94133520712305, + "99.0" : 126.94133520712305, + "99.9" : 126.94133520712305, + "99.99" : 126.94133520712305, + "99.999" : 126.94133520712305, + "99.9999" : 126.94133520712305, + "100.0" : 126.94133520712305 + }, + "scoreUnit" : "ns/op", + "rawData" : [ + [ + 99.60208124069436, + 97.38908033137929, + 104.76770210506992, + 126.17440124093913, + 102.26067589666614 + ], + [ + 103.09389232595201, + 94.74848754160172, + 105.65820362368304, + 126.94133520712305, + 103.45592432942267 + ] + ] + }, + "secondaryMetrics" : { + } + }, + { + "jmhVersion" : "1.37", + "benchmark" : "com.ebremer.beakgraph.benchmarks.DictionaryBench.locateMiss", + "mode" : "avgt", + "threads" : 1, + "forks" : 2, + "jvm" : "C:\\bin\\graalvm\\bin\\java.exe", + "jvmArgs" : [ + "-XX:ThreadPriorityPolicy=1", + "-XX:+UnlockExperimentalVMOptions", + "-XX:+EnableJVMCIProduct", + "-XX:+EnableJVMCI", + "-XX:-UnlockExperimentalVMOptions", + "--enable-native-access=ALL-UNNAMED", + "--sun-misc-unsafe-memory-access=allow", + "-Xmx4g" + ], + "jdkVersion" : "25.0.2", + "vmName" : "OpenJDK 64-Bit Server VM", + "vmVersion" : "25.0.2+10-jvmci-b01", + "warmupIterations" : 5, + "warmupTime" : "1 s", + "warmupBatchSize" : 1, + "measurementIterations" : 5, + "measurementTime" : "1 s", + "measurementBatchSize" : 1, + "params" : { + "subjects" : "50000" + }, + "primaryMetric" : { + "score" : 13.797895584875826, + "scoreError" : 1.1625057309675348, + "scoreConfidence" : [ + 12.635389853908292, + 14.960401315843361 + ], + "scorePercentiles" : { + "0.0" : 12.9430671388601, + "50.0" : 13.683286971531661, + "90.0" : 15.363847459747918, + "95.0" : 15.439098923943153, + "99.0" : 15.439098923943153, + "99.9" : 15.439098923943153, + "99.99" : 15.439098923943153, + "99.999" : 15.439098923943153, + "99.9999" : 15.439098923943153, + "100.0" : 15.439098923943153 + }, + "scoreUnit" : "ns/op", + "rawData" : [ + [ + 13.726921416438538, + 13.662487048592268, + 13.41199088150074, + 15.439098923943153, + 14.037970917270268 + ], + [ + 12.9430671388601, + 12.94550192598075, + 13.421246419710565, + 13.704086894471056, + 14.686584281990804 + ] + ] + }, + "secondaryMetrics" : { + } + }, + { + "jmhVersion" : "1.37", + "benchmark" : "com.ebremer.beakgraph.benchmarks.DictionaryBench.nodeTableLookup", + "mode" : "avgt", + "threads" : 1, + "forks" : 2, + "jvm" : "C:\\bin\\graalvm\\bin\\java.exe", + "jvmArgs" : [ + "-XX:ThreadPriorityPolicy=1", + "-XX:+UnlockExperimentalVMOptions", + "-XX:+EnableJVMCIProduct", + "-XX:+EnableJVMCI", + "-XX:-UnlockExperimentalVMOptions", + "--enable-native-access=ALL-UNNAMED", + "--sun-misc-unsafe-memory-access=allow", + "-Xmx4g" + ], + "jdkVersion" : "25.0.2", + "vmName" : "OpenJDK 64-Bit Server VM", + "vmVersion" : "25.0.2+10-jvmci-b01", + "warmupIterations" : 5, + "warmupTime" : "1 s", + "warmupBatchSize" : 1, + "measurementIterations" : 5, + "measurementTime" : "1 s", + "measurementBatchSize" : 1, + "params" : { + "subjects" : "50000" + }, + "primaryMetric" : { + "score" : 19.82243760658204, + "scoreError" : 0.9852317160688718, + "scoreConfidence" : [ + 18.837205890513168, + 20.80766932265091 + ], + "scorePercentiles" : { + "0.0" : 18.941984306947706, + "50.0" : 19.56688740977952, + "90.0" : 20.766453849119873, + "95.0" : 20.77512648983576, + "99.0" : 20.77512648983576, + "99.9" : 20.77512648983576, + "99.99" : 20.77512648983576, + "99.999" : 20.77512648983576, + "99.9999" : 20.77512648983576, + "100.0" : 20.77512648983576 + }, + "scoreUnit" : "ns/op", + "rawData" : [ + [ + 19.481584884744123, + 20.77512648983576, + 19.548660883039457, + 19.275015292822165, + 19.585113936519576 + ], + [ + 20.654471731174365, + 19.435539338774674, + 18.941984306947706, + 19.838479119285694, + 20.68840008267689 + ] + ] + }, + "secondaryMetrics" : { + } + }, + { + "jmhVersion" : "1.37", + "benchmark" : "com.ebremer.beakgraph.benchmarks.DictionaryBench.objectLocateHit", + "mode" : "avgt", + "threads" : 1, + "forks" : 2, + "jvm" : "C:\\bin\\graalvm\\bin\\java.exe", + "jvmArgs" : [ + "-XX:ThreadPriorityPolicy=1", + "-XX:+UnlockExperimentalVMOptions", + "-XX:+EnableJVMCIProduct", + "-XX:+EnableJVMCI", + "-XX:-UnlockExperimentalVMOptions", + "--enable-native-access=ALL-UNNAMED", + "--sun-misc-unsafe-memory-access=allow", + "-Xmx4g" + ], + "jdkVersion" : "25.0.2", + "vmName" : "OpenJDK 64-Bit Server VM", + "vmVersion" : "25.0.2+10-jvmci-b01", + "warmupIterations" : 5, + "warmupTime" : "1 s", + "warmupBatchSize" : 1, + "measurementIterations" : 5, + "measurementTime" : "1 s", + "measurementBatchSize" : 1, + "params" : { + "subjects" : "50000" + }, + "primaryMetric" : { + "score" : 21.368402885514556, + "scoreError" : 1.9842580244734431, + "scoreConfidence" : [ + 19.38414486104111, + 23.352660909988 + ], + "scorePercentiles" : { + "0.0" : 20.00035048016582, + "50.0" : 21.071528604358328, + "90.0" : 23.299263011082562, + "95.0" : 23.309090270401878, + "99.0" : 23.309090270401878, + "99.9" : 23.309090270401878, + "99.99" : 23.309090270401878, + "99.999" : 23.309090270401878, + "99.9999" : 23.309090270401878, + "100.0" : 23.309090270401878 + }, + "scoreUnit" : "ns/op", + "rawData" : [ + [ + 20.194093270552305, + 20.00035048016582, + 20.132554021435265, + 20.162383507199376, + 20.927122082467136 + ], + [ + 21.215935126249523, + 22.640774527471997, + 23.210817677208727, + 23.309090270401878, + 21.890907891993546 + ] + ] + }, + "secondaryMetrics" : { + } + }, + { + "jmhVersion" : "1.37", + "benchmark" : "com.ebremer.beakgraph.benchmarks.DictionaryBench.predicateLocateHit", + "mode" : "avgt", + "threads" : 1, + "forks" : 2, + "jvm" : "C:\\bin\\graalvm\\bin\\java.exe", + "jvmArgs" : [ + "-XX:ThreadPriorityPolicy=1", + "-XX:+UnlockExperimentalVMOptions", + "-XX:+EnableJVMCIProduct", + "-XX:+EnableJVMCI", + "-XX:-UnlockExperimentalVMOptions", + "--enable-native-access=ALL-UNNAMED", + "--sun-misc-unsafe-memory-access=allow", + "-Xmx4g" + ], + "jdkVersion" : "25.0.2", + "vmName" : "OpenJDK 64-Bit Server VM", + "vmVersion" : "25.0.2+10-jvmci-b01", + "warmupIterations" : 5, + "warmupTime" : "1 s", + "warmupBatchSize" : 1, + "measurementIterations" : 5, + "measurementTime" : "1 s", + "measurementBatchSize" : 1, + "params" : { + "subjects" : "50000" + }, + "primaryMetric" : { + "score" : 12.463046969728516, + "scoreError" : 0.9423879387640717, + "scoreConfidence" : [ + 11.520659030964445, + 13.405434908492587 + ], + "scorePercentiles" : { + "0.0" : 11.533335703283198, + "50.0" : 12.519111308649999, + "90.0" : 13.24314559136114, + "95.0" : 13.254658656902164, + "99.0" : 13.254658656902164, + "99.9" : 13.254658656902164, + "99.99" : 13.254658656902164, + "99.999" : 13.254658656902164, + "99.9999" : 13.254658656902164, + "100.0" : 13.254658656902164 + }, + "scoreUnit" : "ns/op", + "rawData" : [ + [ + 11.533335703283198, + 11.901752213699464, + 11.751773012820548, + 13.254658656902164, + 12.072336569726172 + ], + [ + 13.01007452016016, + 12.357586566397192, + 12.928788401901555, + 13.139528001491916, + 12.680636050902805 + ] + ] + }, + "secondaryMetrics" : { + } + }, + { + "jmhVersion" : "1.37", + "benchmark" : "com.ebremer.beakgraph.benchmarks.QueryBench.chainJoin", + "mode" : "avgt", + "threads" : 1, + "forks" : 2, + "jvm" : "C:\\bin\\graalvm\\bin\\java.exe", + "jvmArgs" : [ + "-XX:ThreadPriorityPolicy=1", + "-XX:+UnlockExperimentalVMOptions", + "-XX:+EnableJVMCIProduct", + "-XX:+EnableJVMCI", + "-XX:-UnlockExperimentalVMOptions", + "--enable-native-access=ALL-UNNAMED", + "--sun-misc-unsafe-memory-access=allow", + "-Xmx4g" + ], + "jdkVersion" : "25.0.2", + "vmName" : "OpenJDK 64-Bit Server VM", + "vmVersion" : "25.0.2+10-jvmci-b01", + "warmupIterations" : 5, + "warmupTime" : "2 s", + "warmupBatchSize" : 1, + "measurementIterations" : 5, + "measurementTime" : "2 s", + "measurementBatchSize" : 1, + "params" : { + "subjects" : "50000" + }, + "primaryMetric" : { + "score" : 91.89564111831905, + "scoreError" : 6.83512200380986, + "scoreConfidence" : [ + 85.06051911450919, + 98.7307631221289 + ], + "scorePercentiles" : { + "0.0" : 85.49374225261808, + "50.0" : 91.62846047768325, + "90.0" : 101.71966479656214, + "95.0" : 102.47445730083965, + "99.0" : 102.47445730083965, + "99.9" : 102.47445730083965, + "99.99" : 102.47445730083965, + "99.999" : 102.47445730083965, + "99.9999" : 102.47445730083965, + "100.0" : 102.47445730083965 + }, + "scoreUnit" : "us/op", + "rawData" : [ + [ + 91.97993470964182, + 87.88310582451828, + 90.0801665916254, + 85.49374225261808, + 90.47218153873972 + ], + [ + 102.47445730083965, + 91.79809554403194, + 91.45882541133456, + 92.38936975177633, + 94.92653225806451 + ] + ] + }, + "secondaryMetrics" : { + } + }, + { + "jmhVersion" : "1.37", + "benchmark" : "com.ebremer.beakgraph.benchmarks.QueryBench.distinctObjects", + "mode" : "avgt", + "threads" : 1, + "forks" : 2, + "jvm" : "C:\\bin\\graalvm\\bin\\java.exe", + "jvmArgs" : [ + "-XX:ThreadPriorityPolicy=1", + "-XX:+UnlockExperimentalVMOptions", + "-XX:+EnableJVMCIProduct", + "-XX:+EnableJVMCI", + "-XX:-UnlockExperimentalVMOptions", + "--enable-native-access=ALL-UNNAMED", + "--sun-misc-unsafe-memory-access=allow", + "-Xmx4g" + ], + "jdkVersion" : "25.0.2", + "vmName" : "OpenJDK 64-Bit Server VM", + "vmVersion" : "25.0.2+10-jvmci-b01", + "warmupIterations" : 5, + "warmupTime" : "2 s", + "warmupBatchSize" : 1, + "measurementIterations" : 5, + "measurementTime" : "2 s", + "measurementBatchSize" : 1, + "params" : { + "subjects" : "50000" + }, + "primaryMetric" : { + "score" : 134109.12840196077, + "scoreError" : 9374.387593988975, + "scoreConfidence" : [ + 124734.7408079718, + 143483.51599594974 + ], + "scorePercentiles" : { + "0.0" : 123683.08235294117, + "50.0" : 134843.02333333332, + "90.0" : 143061.76, + "95.0" : 143263.02666666667, + "99.0" : 143263.02666666667, + "99.9" : 143263.02666666667, + "99.99" : 143263.02666666667, + "99.999" : 143263.02666666667, + "99.9999" : 143263.02666666667, + "100.0" : 143263.02666666667 + }, + "scoreUnit" : "us/op", + "rawData" : [ + [ + 129082.29375, + 134810.04666666666, + 133859.82, + 143263.02666666667, + 138122.24666666667 + ], + [ + 126513.18125, + 134876.0, + 123683.08235294117, + 135631.22666666665, + 141250.36 + ] + ] + }, + "secondaryMetrics" : { + } + }, + { + "jmhVersion" : "1.37", + "benchmark" : "com.ebremer.beakgraph.benchmarks.QueryBench.distinctSubjects", + "mode" : "avgt", + "threads" : 1, + "forks" : 2, + "jvm" : "C:\\bin\\graalvm\\bin\\java.exe", + "jvmArgs" : [ + "-XX:ThreadPriorityPolicy=1", + "-XX:+UnlockExperimentalVMOptions", + "-XX:+EnableJVMCIProduct", + "-XX:+EnableJVMCI", + "-XX:-UnlockExperimentalVMOptions", + "--enable-native-access=ALL-UNNAMED", + "--sun-misc-unsafe-memory-access=allow", + "-Xmx4g" + ], + "jdkVersion" : "25.0.2", + "vmName" : "OpenJDK 64-Bit Server VM", + "vmVersion" : "25.0.2+10-jvmci-b01", + "warmupIterations" : 5, + "warmupTime" : "2 s", + "warmupBatchSize" : 1, + "measurementIterations" : 5, + "measurementTime" : "2 s", + "measurementBatchSize" : 1, + "params" : { + "subjects" : "50000" + }, + "primaryMetric" : { + "score" : 4439.162201041304, + "scoreError" : 713.7382122470412, + "scoreConfidence" : [ + 3725.4239887942626, + 5152.900413288346 + ], + "scorePercentiles" : { + "0.0" : 3906.723781676413, + "50.0" : 4352.216020535276, + "90.0" : 5216.959007432239, + "95.0" : 5227.43498694517, + "99.0" : 5227.43498694517, + "99.9" : 5227.43498694517, + "99.99" : 5227.43498694517, + "99.999" : 5227.43498694517, + "99.9999" : 5227.43498694517, + "100.0" : 5227.43498694517 + }, + "scoreUnit" : "us/op", + "rawData" : [ + [ + 4472.952678571429, + 4242.94406779661, + 3962.505928853755, + 3906.723781676413, + 3999.239121756487 + ], + [ + 4785.959330143541, + 5227.43498694517, + 5122.675191815857, + 4209.698949579832, + 4461.487973273942 + ] + ] + }, + "secondaryMetrics" : { + } + }, + { + "jmhVersion" : "1.37", + "benchmark" : "com.ebremer.beakgraph.benchmarks.QueryBench.fullScanFind", + "mode" : "avgt", + "threads" : 1, + "forks" : 2, + "jvm" : "C:\\bin\\graalvm\\bin\\java.exe", + "jvmArgs" : [ + "-XX:ThreadPriorityPolicy=1", + "-XX:+UnlockExperimentalVMOptions", + "-XX:+EnableJVMCIProduct", + "-XX:+EnableJVMCI", + "-XX:-UnlockExperimentalVMOptions", + "--enable-native-access=ALL-UNNAMED", + "--sun-misc-unsafe-memory-access=allow", + "-Xmx4g" + ], + "jdkVersion" : "25.0.2", + "vmName" : "OpenJDK 64-Bit Server VM", + "vmVersion" : "25.0.2+10-jvmci-b01", + "warmupIterations" : 5, + "warmupTime" : "2 s", + "warmupBatchSize" : 1, + "measurementIterations" : 5, + "measurementTime" : "2 s", + "measurementBatchSize" : 1, + "params" : { + "subjects" : "50000" + }, + "primaryMetric" : { + "score" : 33666.88445516849, + "scoreError" : 2260.117005749393, + "scoreConfidence" : [ + 31406.767449419094, + 35927.00146091788 + ], + "scorePercentiles" : { + "0.0" : 31853.280952380952, + "50.0" : 33552.05666666667, + "90.0" : 37017.07824858757, + "95.0" : 37332.21481481481, + "99.0" : 37332.21481481481, + "99.9" : 37332.21481481481, + "99.99" : 37332.21481481481, + "99.999" : 37332.21481481481, + "99.9999" : 37332.21481481481, + "100.0" : 37332.21481481481 + }, + "scoreUnit" : "us/op", + "rawData" : [ + [ + 33625.64333333333, + 33478.47, + 34180.849152542374, + 34006.41016949152, + 33999.903389830506 + ], + [ + 32999.95573770492, + 32844.85409836066, + 31853.280952380952, + 32347.26290322581, + 37332.21481481481 + ] + ] + }, + "secondaryMetrics" : { + } + }, + { + "jmhVersion" : "1.37", + "benchmark" : "com.ebremer.beakgraph.benchmarks.QueryBench.fullScanSparql", + "mode" : "avgt", + "threads" : 1, + "forks" : 2, + "jvm" : "C:\\bin\\graalvm\\bin\\java.exe", + "jvmArgs" : [ + "-XX:ThreadPriorityPolicy=1", + "-XX:+UnlockExperimentalVMOptions", + "-XX:+EnableJVMCIProduct", + "-XX:+EnableJVMCI", + "-XX:-UnlockExperimentalVMOptions", + "--enable-native-access=ALL-UNNAMED", + "--sun-misc-unsafe-memory-access=allow", + "-Xmx4g" + ], + "jdkVersion" : "25.0.2", + "vmName" : "OpenJDK 64-Bit Server VM", + "vmVersion" : "25.0.2+10-jvmci-b01", + "warmupIterations" : 5, + "warmupTime" : "2 s", + "warmupBatchSize" : 1, + "measurementIterations" : 5, + "measurementTime" : "2 s", + "measurementBatchSize" : 1, + "params" : { + "subjects" : "50000" + }, + "primaryMetric" : { + "score" : 95489.2032232112, + "scoreError" : 10127.079120001821, + "scoreConfidence" : [ + 85362.12410320938, + 105616.28234321301 + ], + "scorePercentiles" : { + "0.0" : 85669.86666666667, + "50.0" : 94495.37954545455, + "90.0" : 105443.55431578947, + "95.0" : 105618.27368421052, + "99.0" : 105618.27368421052, + "99.9" : 105618.27368421052, + "99.99" : 105618.27368421052, + "99.999" : 105618.27368421052, + "99.9999" : 105618.27368421052, + "100.0" : 105618.27368421052 + }, + "scoreUnit" : "us/op", + "rawData" : [ + [ + 103871.08, + 88905.70434782609, + 85669.86666666667, + 89758.1652173913, + 102756.725 + ], + [ + 94160.46363636364, + 93667.87727272727, + 95653.58095238096, + 94830.29545454546, + 105618.27368421052 + ] + ] + }, + "secondaryMetrics" : { + } + }, + { + "jmhVersion" : "1.37", + "benchmark" : "com.ebremer.beakgraph.benchmarks.QueryBench.graphVarScan", + "mode" : "avgt", + "threads" : 1, + "forks" : 2, + "jvm" : "C:\\bin\\graalvm\\bin\\java.exe", + "jvmArgs" : [ + "-XX:ThreadPriorityPolicy=1", + "-XX:+UnlockExperimentalVMOptions", + "-XX:+EnableJVMCIProduct", + "-XX:+EnableJVMCI", + "-XX:-UnlockExperimentalVMOptions", + "--enable-native-access=ALL-UNNAMED", + "--sun-misc-unsafe-memory-access=allow", + "-Xmx4g" + ], + "jdkVersion" : "25.0.2", + "vmName" : "OpenJDK 64-Bit Server VM", + "vmVersion" : "25.0.2+10-jvmci-b01", + "warmupIterations" : 5, + "warmupTime" : "2 s", + "warmupBatchSize" : 1, + "measurementIterations" : 5, + "measurementTime" : "2 s", + "measurementBatchSize" : 1, + "params" : { + "subjects" : "50000" + }, + "primaryMetric" : { + "score" : 3612.7778672198074, + "scoreError" : 328.8271546733496, + "scoreConfidence" : [ + 3283.950712546458, + 3941.605021893157 + ], + "scorePercentiles" : { + "0.0" : 3325.1033222591363, + "50.0" : 3556.870784029279, + "90.0" : 3916.4578378594892, + "95.0" : 3917.7671232876714, + "99.0" : 3917.7671232876714, + "99.9" : 3917.7671232876714, + "99.99" : 3917.7671232876714, + "99.999" : 3917.7671232876714, + "99.9999" : 3917.7671232876714, + "100.0" : 3917.7671232876714 + }, + "scoreUnit" : "us/op", + "rawData" : [ + [ + 3904.674269005848, + 3788.481818181818, + 3390.680879864636, + 3517.2026362038664, + 3768.764406779661 + ], + [ + 3547.9267730496454, + 3917.7671232876714, + 3401.362648556876, + 3325.1033222591363, + 3565.814795008913 + ] + ] + }, + "secondaryMetrics" : { + } + }, + { + "jmhVersion" : "1.37", + "benchmark" : "com.ebremer.beakgraph.benchmarks.QueryBench.pointLookup", + "mode" : "avgt", + "threads" : 1, + "forks" : 2, + "jvm" : "C:\\bin\\graalvm\\bin\\java.exe", + "jvmArgs" : [ + "-XX:ThreadPriorityPolicy=1", + "-XX:+UnlockExperimentalVMOptions", + "-XX:+EnableJVMCIProduct", + "-XX:+EnableJVMCI", + "-XX:-UnlockExperimentalVMOptions", + "--enable-native-access=ALL-UNNAMED", + "--sun-misc-unsafe-memory-access=allow", + "-Xmx4g" + ], + "jdkVersion" : "25.0.2", + "vmName" : "OpenJDK 64-Bit Server VM", + "vmVersion" : "25.0.2+10-jvmci-b01", + "warmupIterations" : 5, + "warmupTime" : "2 s", + "warmupBatchSize" : 1, + "measurementIterations" : 5, + "measurementTime" : "2 s", + "measurementBatchSize" : 1, + "params" : { + "subjects" : "50000" + }, + "primaryMetric" : { + "score" : 4.435139747359097, + "scoreError" : 0.32296191612749, + "scoreConfidence" : [ + 4.112177831231607, + 4.7581016634865865 + ], + "scorePercentiles" : { + "0.0" : 4.178093965337231, + "50.0" : 4.359770245798307, + "90.0" : 4.78769684282766, + "95.0" : 4.789925032742805, + "99.0" : 4.789925032742805, + "99.9" : 4.789925032742805, + "99.99" : 4.789925032742805, + "99.999" : 4.789925032742805, + "99.9999" : 4.789925032742805, + "100.0" : 4.789925032742805 + }, + "scoreUnit" : "us/op", + "rawData" : [ + [ + 4.367107009105115, + 4.291802097098042, + 4.334301925051668, + 4.178093965337231, + 4.237542374496323 + ], + [ + 4.599347080932557, + 4.3524334824915, + 4.767643133591352, + 4.4332013727443815, + 4.789925032742805 + ] + ] + }, + "secondaryMetrics" : { + } + }, + { + "jmhVersion" : "1.37", + "benchmark" : "com.ebremer.beakgraph.benchmarks.QueryBench.predicateScan", + "mode" : "avgt", + "threads" : 1, + "forks" : 2, + "jvm" : "C:\\bin\\graalvm\\bin\\java.exe", + "jvmArgs" : [ + "-XX:ThreadPriorityPolicy=1", + "-XX:+UnlockExperimentalVMOptions", + "-XX:+EnableJVMCIProduct", + "-XX:+EnableJVMCI", + "-XX:-UnlockExperimentalVMOptions", + "--enable-native-access=ALL-UNNAMED", + "--sun-misc-unsafe-memory-access=allow", + "-Xmx4g" + ], + "jdkVersion" : "25.0.2", + "vmName" : "OpenJDK 64-Bit Server VM", + "vmVersion" : "25.0.2+10-jvmci-b01", + "warmupIterations" : 5, + "warmupTime" : "2 s", + "warmupBatchSize" : 1, + "measurementIterations" : 5, + "measurementTime" : "2 s", + "measurementBatchSize" : 1, + "params" : { + "subjects" : "50000" + }, + "primaryMetric" : { + "score" : 19638.390444917626, + "scoreError" : 1644.4027374099828, + "scoreConfidence" : [ + 17993.987707507644, + 21282.79318232761 + ], + "scorePercentiles" : { + "0.0" : 18101.537837837837, + "50.0" : 19575.212575414782, + "90.0" : 20977.893854166665, + "95.0" : 20992.597916666666, + "99.0" : 20992.597916666666, + "99.9" : 20992.597916666666, + "99.99" : 20992.597916666666, + "99.999" : 20992.597916666666, + "99.9999" : 20992.597916666666, + "100.0" : 20992.597916666666 + }, + "scoreUnit" : "us/op", + "rawData" : [ + [ + 19762.657843137255, + 19073.637142857144, + 18565.008333333335, + 18101.537837837837, + 18422.41376146789 + ], + [ + 20779.74742268041, + 20992.597916666666, + 19387.76730769231, + 20452.979591836734, + 20845.557291666668 + ] + ] + }, + "secondaryMetrics" : { + } + }, + { + "jmhVersion" : "1.37", + "benchmark" : "com.ebremer.beakgraph.benchmarks.QueryBench.rangeFilter", + "mode" : "avgt", + "threads" : 1, + "forks" : 2, + "jvm" : "C:\\bin\\graalvm\\bin\\java.exe", + "jvmArgs" : [ + "-XX:ThreadPriorityPolicy=1", + "-XX:+UnlockExperimentalVMOptions", + "-XX:+EnableJVMCIProduct", + "-XX:+EnableJVMCI", + "-XX:-UnlockExperimentalVMOptions", + "--enable-native-access=ALL-UNNAMED", + "--sun-misc-unsafe-memory-access=allow", + "-Xmx4g" + ], + "jdkVersion" : "25.0.2", + "vmName" : "OpenJDK 64-Bit Server VM", + "vmVersion" : "25.0.2+10-jvmci-b01", + "warmupIterations" : 5, + "warmupTime" : "2 s", + "warmupBatchSize" : 1, + "measurementIterations" : 5, + "measurementTime" : "2 s", + "measurementBatchSize" : 1, + "params" : { + "subjects" : "50000" + }, + "primaryMetric" : { + "score" : 79.07903990521085, + "scoreError" : 8.599493223792095, + "scoreConfidence" : [ + 70.47954668141875, + 87.67853312900294 + ], + "scorePercentiles" : { + "0.0" : 70.83335457603116, + "50.0" : 81.00787184552635, + "90.0" : 88.67680413456469, + "95.0" : 89.33075961237887, + "99.0" : 89.33075961237887, + "99.9" : 89.33075961237887, + "99.99" : 89.33075961237887, + "99.999" : 89.33075961237887, + "99.9999" : 89.33075961237887, + "100.0" : 89.33075961237887 + }, + "scoreUnit" : "us/op", + "rawData" : [ + [ + 81.81261191284085, + 81.75154883530854, + 73.77214027583155, + 72.70573681150995, + 70.83335457603116 + ], + [ + 89.33075961237887, + 75.65679609815116, + 82.79120483423699, + 80.26419485574415, + 81.87205124007531 + ] + ] + }, + "secondaryMetrics" : { + } + }, + { + "jmhVersion" : "1.37", + "benchmark" : "com.ebremer.beakgraph.benchmarks.QueryBench.starJoin", + "mode" : "avgt", + "threads" : 1, + "forks" : 2, + "jvm" : "C:\\bin\\graalvm\\bin\\java.exe", + "jvmArgs" : [ + "-XX:ThreadPriorityPolicy=1", + "-XX:+UnlockExperimentalVMOptions", + "-XX:+EnableJVMCIProduct", + "-XX:+EnableJVMCI", + "-XX:-UnlockExperimentalVMOptions", + "--enable-native-access=ALL-UNNAMED", + "--sun-misc-unsafe-memory-access=allow", + "-Xmx4g" + ], + "jdkVersion" : "25.0.2", + "vmName" : "OpenJDK 64-Bit Server VM", + "vmVersion" : "25.0.2+10-jvmci-b01", + "warmupIterations" : 5, + "warmupTime" : "2 s", + "warmupBatchSize" : 1, + "measurementIterations" : 5, + "measurementTime" : "2 s", + "measurementBatchSize" : 1, + "params" : { + "subjects" : "50000" + }, + "primaryMetric" : { + "score" : 7.396477974578936, + "scoreError" : 0.922616601008638, + "scoreConfidence" : [ + 6.473861373570298, + 8.319094575587574 + ], + "scorePercentiles" : { + "0.0" : 6.3993426248325385, + "50.0" : 7.482400146708385, + "90.0" : 8.242093847946961, + "95.0" : 8.269762225398425, + "99.0" : 8.269762225398425, + "99.9" : 8.269762225398425, + "99.99" : 8.269762225398425, + "99.999" : 8.269762225398425, + "99.9999" : 8.269762225398425, + "100.0" : 8.269762225398425 + }, + "scoreUnit" : "us/op", + "rawData" : [ + [ + 7.3870174648469655, + 6.927303137336381, + 6.591509129366183, + 7.254587949447879, + 6.3993426248325385 + ], + [ + 7.681955796481072, + 7.577782828569805, + 7.882440138626339, + 7.993078450883776, + 8.269762225398425 + ] + ] + }, + "secondaryMetrics" : { + } + }, + { + "jmhVersion" : "1.37", + "benchmark" : "com.ebremer.beakgraph.benchmarks.SelectBench.adjacentPair", + "mode" : "avgt", + "threads" : 1, + "forks" : 2, + "jvm" : "C:\\bin\\graalvm\\bin\\java.exe", + "jvmArgs" : [ + "-XX:ThreadPriorityPolicy=1", + "-XX:+UnlockExperimentalVMOptions", + "-XX:+EnableJVMCIProduct", + "-XX:+EnableJVMCI", + "-XX:-UnlockExperimentalVMOptions", + "--enable-native-access=ALL-UNNAMED", + "--sun-misc-unsafe-memory-access=allow", + "-Xmx4g" + ], + "jdkVersion" : "25.0.2", + "vmName" : "OpenJDK 64-Bit Server VM", + "vmVersion" : "25.0.2+10-jvmci-b01", + "warmupIterations" : 5, + "warmupTime" : "1 s", + "warmupBatchSize" : 1, + "measurementIterations" : 5, + "measurementTime" : "1 s", + "measurementBatchSize" : 1, + "params" : { + "subjects" : "50000" + }, + "primaryMetric" : { + "score" : 118.28220397388654, + "scoreError" : 5.759701008316358, + "scoreConfidence" : [ + 112.52250296557018, + 124.0419049822029 + ], + "scorePercentiles" : { + "0.0" : 112.70912641021646, + "50.0" : 117.73825872608174, + "90.0" : 124.1071714407903, + "95.0" : 124.16785638116455, + "99.0" : 124.16785638116455, + "99.9" : 124.16785638116455, + "99.99" : 124.16785638116455, + "99.999" : 124.16785638116455, + "99.9999" : 124.16785638116455, + "100.0" : 124.16785638116455 + }, + "scoreUnit" : "ns/op", + "rawData" : [ + [ + 120.17445389880707, + 120.1116096850967, + 115.65822130962975, + 113.6535373828846, + 123.5610069774219 + ], + [ + 117.36222087932694, + 112.70912641021646, + 117.30971024148087, + 124.16785638116455, + 118.11429657283654 + ] + ] + }, + "secondaryMetrics" : { + } + }, + { + "jmhVersion" : "1.37", + "benchmark" : "com.ebremer.beakgraph.benchmarks.SelectBench.directorySelect1", + "mode" : "avgt", + "threads" : 1, + "forks" : 2, + "jvm" : "C:\\bin\\graalvm\\bin\\java.exe", + "jvmArgs" : [ + "-XX:ThreadPriorityPolicy=1", + "-XX:+UnlockExperimentalVMOptions", + "-XX:+EnableJVMCIProduct", + "-XX:+EnableJVMCI", + "-XX:-UnlockExperimentalVMOptions", + "--enable-native-access=ALL-UNNAMED", + "--sun-misc-unsafe-memory-access=allow", + "-Xmx4g" + ], + "jdkVersion" : "25.0.2", + "vmName" : "OpenJDK 64-Bit Server VM", + "vmVersion" : "25.0.2+10-jvmci-b01", + "warmupIterations" : 5, + "warmupTime" : "1 s", + "warmupBatchSize" : 1, + "measurementIterations" : 5, + "measurementTime" : "1 s", + "measurementBatchSize" : 1, + "params" : { + "subjects" : "50000" + }, + "primaryMetric" : { + "score" : 65.82313156429895, + "scoreError" : 3.1089705242914634, + "scoreConfidence" : [ + 62.71416104000748, + 68.93210208859041 + ], + "scorePercentiles" : { + "0.0" : 62.65678791106091, + "50.0" : 65.0247754525, + "90.0" : 69.27867662118504, + "95.0" : 69.45016223550103, + "99.0" : 69.45016223550103, + "99.9" : 69.45016223550103, + "99.99" : 69.45016223550103, + "99.999" : 69.45016223550103, + "99.9999" : 69.45016223550103, + "100.0" : 69.45016223550103 + }, + "scoreUnit" : "ns/op", + "rawData" : [ + [ + 64.36545006122384, + 64.96574582480602, + 69.45016223550103, + 64.95920513231344, + 62.65678791106091 + ], + [ + 65.08380508019398, + 67.7353060923412, + 67.6495501349639, + 64.32378680879037, + 67.04151636179476 + ] + ] + }, + "secondaryMetrics" : { + } + }, + { + "jmhVersion" : "1.37", + "benchmark" : "com.ebremer.beakgraph.benchmarks.SelectBench.linearSelect1", + "mode" : "avgt", + "threads" : 1, + "forks" : 2, + "jvm" : "C:\\bin\\graalvm\\bin\\java.exe", + "jvmArgs" : [ + "-XX:ThreadPriorityPolicy=1", + "-XX:+UnlockExperimentalVMOptions", + "-XX:+EnableJVMCIProduct", + "-XX:+EnableJVMCI", + "-XX:-UnlockExperimentalVMOptions", + "--enable-native-access=ALL-UNNAMED", + "--sun-misc-unsafe-memory-access=allow", + "-Xmx4g" + ], + "jdkVersion" : "25.0.2", + "vmName" : "OpenJDK 64-Bit Server VM", + "vmVersion" : "25.0.2+10-jvmci-b01", + "warmupIterations" : 5, + "warmupTime" : "1 s", + "warmupBatchSize" : 1, + "measurementIterations" : 5, + "measurementTime" : "1 s", + "measurementBatchSize" : 1, + "params" : { + "subjects" : "50000" + }, + "primaryMetric" : { + "score" : 1850.644006819831, + "scoreError" : 104.87647048694178, + "scoreConfidence" : [ + 1745.7675363328892, + 1955.5204773067728 + ], + "scorePercentiles" : { + "0.0" : 1755.5673687941023, + "50.0" : 1830.1829416967503, + "90.0" : 1954.8036080377403, + "95.0" : 1956.649996772938, + "99.0" : 1956.649996772938, + "99.9" : 1956.649996772938, + "99.99" : 1956.649996772938, + "99.999" : 1956.649996772938, + "99.9999" : 1956.649996772938, + "100.0" : 1956.649996772938 + }, + "scoreUnit" : "ns/op", + "rawData" : [ + [ + 1938.186109420961, + 1896.0087502298452, + 1906.1104052331905, + 1782.2105250028064, + 1755.5673687941023 + ], + [ + 1956.649996772938, + 1811.9987343488676, + 1807.5329110836037, + 1848.3671490446332, + 1803.808118267363 + ] + ] + }, + "secondaryMetrics" : { + } + } +] + + diff --git a/pom.xml b/pom.xml index f681189c..c60b877c 100644 --- a/pom.xml +++ b/pom.xml @@ -4,7 +4,7 @@ com.ebremer BeakGraph BeakGraph - 0.17.0 + 0.18.0 jar Library for creating indexed binary storages for Apache Jena Graphs and Datasets diff --git a/src/main/java/com/ebremer/beakgraph/core/lib/CdtTerms.java b/src/main/java/com/ebremer/beakgraph/core/lib/CdtTerms.java new file mode 100644 index 00000000..fb71a033 --- /dev/null +++ b/src/main/java/com/ebremer/beakgraph/core/lib/CdtTerms.java @@ -0,0 +1,95 @@ +package com.ebremer.beakgraph.core.lib; + +import java.util.List; +import java.util.Map; +import org.apache.jena.cdt.CDTKey; +import org.apache.jena.cdt.CDTValue; +import org.apache.jena.cdt.CompositeDatatypeBase; +import org.apache.jena.graph.Node; + +/** + * Term-kind helpers for SPARQL-CDT composite literals (cdt:List / cdt:Map). + * + *

Composite literals ride the term-exact strings path with no storage + * changes, but two of their properties need special handling elsewhere: + * they have no canonical form (so term identity IS lexical identity - see + * {@link NodeComparator}), and their lexical forms may embed blank node + * labels whose co-reference BeakGraph's rank-derived relabeling would + * silently sever (so ingest rejects those - see the writer guards). + */ +public final class CdtTerms { + + private CdtTerms() {} + + /** True when {@code n} is a literal whose datatype is cdt:List or cdt:Map. */ + public static boolean isComposite(Node n) { + return n.isLiteral() && n.getLiteralDatatype() instanceof CompositeDatatypeBase; + } + + /** + * True when a well-formed composite literal's value contains a blank node + * at any nesting depth. The SPARQL-CDT spec (section 5.2) requires a blank + * node label inside a composite literal to co-refer with the same label + * outside it, but BeakGraph regenerates blank-node labels from dictionary + * rank - the label in the literal's text would keep naming a blank node + * that no longer exists in the graph. Callers reject such literals at + * ingest rather than storing that silent severing. + * + *

An ILL-FORMED composite literal returns {@code false}: it has no + * parseable value, so there is no co-reference to break. (Unreachable from + * parsed sources - RIOT's CDT-aware default profile rejects ill-formed + * composite lexical forms at parse - but possible from programmatically + * built nodes.) Note the check parses the composite value (cost O(size), + * composite literals only). + */ + public static boolean containsBlankNode(Node n) { + if (!isComposite(n)) { + return false; + } + Object value; + try { + value = n.getLiteralValue(); + } catch (RuntimeException ex) { + return false; // ill-formed: opaque, nothing co-refers + } + return valueContainsBlankNode(value); + } + + private static boolean valueContainsBlankNode(Object value) { + if (value instanceof List list) { + for (Object e : list) { + if (e instanceof CDTValue v && cdtValueContainsBlankNode(v)) { + return true; + } + } + return false; + } + if (value instanceof Map map) { + for (Map.Entry e : map.entrySet()) { + // The grammar forbids blank nodes as map KEYS; checked anyway so a + // parser relaxation cannot reopen the co-reference hole. + if (e.getKey() instanceof CDTKey k && k.asNode() != null && k.asNode().isBlank()) { + return true; + } + if (e.getValue() instanceof CDTValue v && cdtValueContainsBlankNode(v)) { + return true; + } + } + return false; + } + return false; + } + + private static boolean cdtValueContainsBlankNode(CDTValue v) { + if (v.isNull() || !v.isNode()) { + // null elements carry no node; parsed CDT values otherwise always + // wrap nodes (nested lists/maps surface as cdt-typed literal nodes). + return false; + } + Node node = v.asNode(); + if (node.isBlank()) { + return true; + } + return containsBlankNode(node); // recurse into nested cdt literals + } +} diff --git a/src/main/java/com/ebremer/beakgraph/core/lib/NodeComparator.java b/src/main/java/com/ebremer/beakgraph/core/lib/NodeComparator.java index fa06d0bd..c58302b3 100644 --- a/src/main/java/com/ebremer/beakgraph/core/lib/NodeComparator.java +++ b/src/main/java/com/ebremer/beakgraph/core/lib/NodeComparator.java @@ -69,6 +69,27 @@ public int compare(Node n1, Node n2) { // 3. Both nodes are the SAME RDF Term Type. // If they are both Literals, we must sort by actual Value (e.g. 2 < 10), not String ("10" < "2") if (n1.isLiteral() && n2.isLiteral()) { + // Composite (cdt:List / cdt:Map) literals never go through compareAlways: + // there, same-datatype pairs compare by VALUE while any pair touching an + // ill-formed literal fell back to TERM order, and mixing the two orders + // is cyclic ("[9]" < "[10]" < "[5" < "[9]") - the same non-transitivity + // hazard as the temporal spaces below, i.e. a build-order-dependent + // dictionary. CDT has no canonical form, so term identity IS lexical + // identity: (datatype IRI, lexical form) is a self-consistent total + // order, and it skips a value parse that costs O(list length) inside + // every dictionary binary-search probe. The cross-datatype direction + // (List before Map) matches compareAlways' value-space rank, and MIXED + // pairs (one composite, one not) stay on compareAlways, whose + // classification is uniform by datatype - verified: ill-formed and + // well-formed composites rank identically against every other value + // space, without throwing. + if (CdtTerms.isComposite(n1) && CdtTerms.isComposite(n2)) { + int byDatatype = n1.getLiteralDatatypeURI().compareTo(n2.getLiteralDatatypeURI()); + if (byDatatype != 0) { + return byDatatype; + } + return n1.getLiteralLexicalForm().compareTo(n2.getLiteralLexicalForm()); + } try { NodeValue nv1 = nodeValue(n1); NodeValue nv2 = nodeValue(n2); diff --git a/src/main/java/com/ebremer/beakgraph/hdf5/writers/MultiTypeDictionaryWriter.java b/src/main/java/com/ebremer/beakgraph/hdf5/writers/MultiTypeDictionaryWriter.java index fb8b8901..20151e02 100644 --- a/src/main/java/com/ebremer/beakgraph/hdf5/writers/MultiTypeDictionaryWriter.java +++ b/src/main/java/com/ebremer/beakgraph/hdf5/writers/MultiTypeDictionaryWriter.java @@ -218,6 +218,16 @@ else if (node.isURI()) { } } else if (node.isLiteral()) { + // Defence in depth behind the ingest guards: a base-direction literal + // ("x"@en--ltr, rdf:dirLangString) has no direction storage here and + // would silently encode as its plain lang-tagged counterpart - a + // different RDF term. Throw before any buffer write so no partial + // entry desynchronizes the parallel arrays. + if (node.getLiteralBaseDirection() != null) { + throw new IllegalStateException( + "Unsupported literal in dictionary '" + name + + "' (rdf:dirLangString base direction cannot be stored): " + node); + } String dt = node.getLiteralDatatypeURI(); long dtId = dataTypesLookUp.getOrDefault(dt, 0L); if (literalsPresent) typedLiterals.writeLong(dtId); diff --git a/src/main/java/com/ebremer/beakgraph/hdf5/writers/PositionalDictionaryWriterBuilder.java b/src/main/java/com/ebremer/beakgraph/hdf5/writers/PositionalDictionaryWriterBuilder.java index 4edb3eb8..aeecc5b9 100644 --- a/src/main/java/com/ebremer/beakgraph/hdf5/writers/PositionalDictionaryWriterBuilder.java +++ b/src/main/java/com/ebremer/beakgraph/hdf5/writers/PositionalDictionaryWriterBuilder.java @@ -2,6 +2,7 @@ import com.ebremer.beakgraph.Params; import com.ebremer.beakgraph.core.fuseki.BGVoIDSD; +import com.ebremer.beakgraph.core.lib.CdtTerms; import com.ebremer.beakgraph.core.lib.Stats; import com.ebremer.beakgraph.utils.ImageTools; import com.ebremer.beakgraph.utils.RdfSources; @@ -611,7 +612,23 @@ private void ProcessQuad(Quad quad) { predicates.add(p); } if (o.isLiteral()) { + // An RDF 1.2 base-direction literal ("x"@en--ltr, rdf:dirLangString): + // the format has nowhere to store the direction, so the term would be + // silently rewritten to "x"@en on read-back - a different RDF term. + // Fail the build loudly instead, same stance as the node-kind guards. + if (o.getLiteralBaseDirection() != null) { + throw new IllegalStateException( + "Unsupported object literal (rdf:dirLangString base direction cannot be stored): " + o); + } if (!literals.contains(o)) { + // Blank nodes inside a composite (cdt:) literal: labels regenerate + // from dictionary rank, so the label in the literal's text would + // silently stop co-referring with the graph. Reject at ingest + // (checked once per distinct literal; parses composite values only). + if (CdtTerms.containsBlankNode(o)) { + throw new IllegalStateException( + "Unsupported object literal (blank node inside cdt: composite literal cannot be stored; its co-reference with the graph would silently break): " + o); + } dataTypes.add(o.getLiteralDatatypeURI()); countLiteralStats(o, stats); literals.add(o); diff --git a/src/main/java/com/ebremer/beakgraph/hdf5/writers/ultra/UltraIngest.java b/src/main/java/com/ebremer/beakgraph/hdf5/writers/ultra/UltraIngest.java index 59e9bf2b..829df8d7 100644 --- a/src/main/java/com/ebremer/beakgraph/hdf5/writers/ultra/UltraIngest.java +++ b/src/main/java/com/ebremer/beakgraph/hdf5/writers/ultra/UltraIngest.java @@ -1,6 +1,7 @@ package com.ebremer.beakgraph.hdf5.writers.ultra; import com.ebremer.beakgraph.core.fuseki.BGVoIDSD; +import com.ebremer.beakgraph.core.lib.CdtTerms; import com.ebremer.beakgraph.core.lib.Stats; import com.ebremer.beakgraph.hdf5.writers.PositionalDictionaryWriterBuilder; import com.ebremer.beakgraph.sniff.SD; @@ -359,7 +360,21 @@ private void buildSets(ForkJoinPool pool) throws IOException { entities.add(s); predicates.add(p); if (o.isLiteral()) { - literals.add(o); + // Same guard as the sequential ProcessQuad: a base-direction + // literal ("x"@en--ltr, rdf:dirLangString) has nowhere to + // store its direction and would silently collapse onto the + // plain lang-tagged term. Abort the build loudly instead. + if (o.getLiteralBaseDirection() != null) { + throw new IllegalStateException( + "Unsupported object literal (rdf:dirLangString base direction cannot be stored): " + o); + } + // Same guard as the sequential ProcessQuad: blank nodes inside a + // composite (cdt:) literal would silently stop co-referring after + // rank relabeling. add() gates the parse to once per distinct. + if (literals.add(o) && CdtTerms.containsBlankNode(o)) { + throw new IllegalStateException( + "Unsupported object literal (blank node inside cdt: composite literal cannot be stored; its co-reference with the graph would silently break): " + o); + } dataTypes.add(o.getLiteralDatatypeURI()); } else { if (!o.isBlank() && !o.isURI()) { diff --git a/src/main/java/com/ebremer/beakgraph/huge/HugeBuildPipeline.java b/src/main/java/com/ebremer/beakgraph/huge/HugeBuildPipeline.java index 35069145..c1990aee 100644 --- a/src/main/java/com/ebremer/beakgraph/huge/HugeBuildPipeline.java +++ b/src/main/java/com/ebremer/beakgraph/huge/HugeBuildPipeline.java @@ -2,6 +2,7 @@ import com.ebremer.beakgraph.Params; import com.ebremer.beakgraph.core.fuseki.BGVoIDSD; +import com.ebremer.beakgraph.core.lib.CdtTerms; import com.ebremer.beakgraph.core.lib.NodeComparator; import com.ebremer.beakgraph.core.lib.Stats; import com.ebremer.beakgraph.hdf5.Index; @@ -583,6 +584,22 @@ private void countEntityKind(Node n, String position) { * and buffer-allocation gates consume. */ private void collectLiteralStats(Node o) { + // Same guard as ProcessQuad: a base-direction literal ("x"@en--ltr, + // rdf:dirLangString) has nowhere to store its direction here, and the + // spill codec (NodeCodec) would silently collapse it onto the plain + // lang-tagged term mid-build. Abort the build loudly instead. + if (o.getLiteralBaseDirection() != null) { + throw new IllegalStateException( + "Unsupported object literal (rdf:dirLangString base direction cannot be stored): " + o); + } + // Same guard as ProcessQuad: blank nodes inside a composite (cdt:) literal + // would silently stop co-referring after rank relabeling. This pipeline + // has no distinct-literal set, so the check runs per occurrence - it + // parses composite values only, everything else is one instanceof. + if (CdtTerms.containsBlankNode(o)) { + throw new IllegalStateException( + "Unsupported object literal (blank node inside cdt: composite literal cannot be stored; its co-reference with the graph would silently break): " + o); + } String dt = o.getLiteralDatatypeURI(); dataTypes.add(dt); String lang = o.getLiteralLanguage(); diff --git a/src/main/java/com/ebremer/beakgraph/huge/NodeCodec.java b/src/main/java/com/ebremer/beakgraph/huge/NodeCodec.java index a5d096f0..e8ab0ea2 100644 --- a/src/main/java/com/ebremer/beakgraph/huge/NodeCodec.java +++ b/src/main/java/com/ebremer/beakgraph/huge/NodeCodec.java @@ -17,7 +17,8 @@ * parsed original. * *

Node kinds the BeakGraph format cannot store (RDF-star triple terms, - * variables) fail loudly here, matching the RAM writer's ProcessQuad guards. + * variables, base-direction literals) fail loudly here, matching the RAM + * writer's ProcessQuad guards. * * @author Erich Bremer */ @@ -51,6 +52,14 @@ public static void writeNode(DataOutput out, Node n) throws IOException { out.writeByte(T_BNODE); writeString(out, n.getBlankNodeLabel()); } else if (n.isLiteral()) { + // A base-direction literal ("x"@en--ltr, rdf:dirLangString) would be + // serialized as its plain lang-tagged counterpart and deserialize to + // a DIFFERENT term - breaking this codec's round-trip contract and + // collapsing the two terms mid-build. Fail loudly before the tag byte. + if (n.getLiteralBaseDirection() != null) { + throw new IllegalStateException( + "Unsupported literal in huge writer spill (rdf:dirLangString base direction cannot be stored): " + n); + } String lang = n.getLiteralLanguage(); if (lang != null && !lang.isEmpty()) { out.writeByte(T_LITERAL_LANG); diff --git a/src/main/java/com/ebremer/beakgraph/huge/StreamingDictionaryWriter.java b/src/main/java/com/ebremer/beakgraph/huge/StreamingDictionaryWriter.java index 3cd26e1e..aa4016f7 100644 --- a/src/main/java/com/ebremer/beakgraph/huge/StreamingDictionaryWriter.java +++ b/src/main/java/com/ebremer/beakgraph/huge/StreamingDictionaryWriter.java @@ -164,6 +164,14 @@ private void addNodeInternal(Node node) { throw new UncheckedIOException("Failed to add IRI to dictionary: " + node, ex); } } else if (node.isLiteral()) { + // Mirror of MultiTypeDictionaryWriter: base-direction literals have no + // direction storage - throw before any buffer write (see that class + // for the full rationale). + if (node.getLiteralBaseDirection() != null) { + throw new IllegalStateException( + "Unsupported literal in dictionary '" + name + + "' (rdf:dirLangString base direction cannot be stored): " + node); + } String dt = node.getLiteralDatatypeURI(); long dtId = dataTypesLookUp.getOrDefault(dt, 0L); if (literalsPresent) typedLiterals.writeLong(dtId); diff --git a/src/test/java/com/ebremer/beakgraph/CdtBlankNodeGuardTest.java b/src/test/java/com/ebremer/beakgraph/CdtBlankNodeGuardTest.java new file mode 100644 index 00000000..37b8c886 --- /dev/null +++ b/src/test/java/com/ebremer/beakgraph/CdtBlankNodeGuardTest.java @@ -0,0 +1,190 @@ +package com.ebremer.beakgraph; + +import static org.junit.jupiter.api.Assertions.assertEquals; +import static org.junit.jupiter.api.Assertions.assertThrows; +import static org.junit.jupiter.api.Assertions.assertTrue; + +import com.ebremer.beakgraph.core.BeakGraph; +import com.ebremer.beakgraph.hdf5.writers.HDF5Writer; +import com.ebremer.beakgraph.hdf5.writers.ultra.UltraHDF5Writer; +import com.ebremer.beakgraph.huge.HugeHDF5Writer; +import com.ebremer.beakgraph.huge.NativeHdf5File; +import java.io.File; +import java.nio.file.Files; +import java.nio.file.Path; +import org.apache.jena.graph.Node; +import org.junit.jupiter.api.Assumptions; +import org.junit.jupiter.api.Test; +import org.junit.jupiter.api.io.TempDir; + +/** + * Blank nodes inside composite (cdt:) literals are rejected at ingest: the + * SPARQL-CDT spec (section 5.2) requires a blank node label inside a composite + * literal to co-refer with the same label outside it, but BeakGraph + * regenerates blank-node labels from dictionary rank, so the label in the + * literal's text would silently stop naming anything in the graph (verified + * pre-guard: the outside bnode read back as _:b00000000000000000002 while the + * literal still said _:b1). + * + *

One rejection test per ingest hierarchy - ProcessQuad (method 0), + * HugeBuildPipeline.collectLiteralStats (method 1), UltraIngest.buildSets + * (method 3). Controls pin the boundaries: composite literals without blank + * nodes build; "_:x" inside a quoted string element is a string, not a blank + * node (the detector parses, it does not substring-match); ill-formed + * composite literals stay allowed and round-trip as opaque terms. + */ +class CdtBlankNodeGuardTest { + + private static final String GUARD_MESSAGE = "blank node inside cdt: composite literal"; + + private static final String BAD_TTL = """ + @prefix : . + @prefix cdt: . + :s :list "[_:b1]"^^cdt:List . + _:b1 :label "co-referenced outside" . + """; + + @TempDir + static Path dir; + + private static Path ttl(String name, String content) throws Exception { + Path p = dir.resolve(name); + Files.writeString(p, content); + return p; + } + + private static void assertGuardFires(Executable build) { + Exception ex = assertThrows(Exception.class, build::run); + boolean found = false; + for (Throwable c = ex; c != null; c = c.getCause()) { + if (c.getMessage() != null && c.getMessage().contains(GUARD_MESSAGE)) { + found = true; + break; + } + } + assertTrue(found, "build failed, but not on the blank-node-in-composite guard: " + ex); + } + + @FunctionalInterface + interface Executable { + void run() throws Exception; + } + + @Test + void method0RejectsBlankNodeInsideList() throws Exception { + Path src = ttl("m0-bad.ttl", BAD_TTL); + File dest = dir.resolve("m0-bad.h5").toFile(); + assertGuardFires(() -> + HDF5Writer.Builder().setSource(src.toFile()).setDestination(dest).build().write()); + } + + @Test + void method1RejectsBlankNodeInsideList() throws Exception { + Assumptions.assumeTrue(NativeHdf5File.isAvailable(), "native HDF5 library unavailable"); + Path src = ttl("m1-bad.ttl", BAD_TTL); + File dest = dir.resolve("m1-bad.h5").toFile(); + assertGuardFires(() -> { + HugeHDF5Writer.Builder b = HugeHDF5Writer.Builder().setDestination(dest); + b.setSource(src.toFile()); + b.build().write(); + }); + } + + @Test + void method3RejectsBlankNodeInsideList() throws Exception { + Path src = ttl("m3-bad.ttl", BAD_TTL); + File dest = dir.resolve("m3-bad.h5").toFile(); + assertGuardFires(() -> { + UltraHDF5Writer.Builder b = UltraHDF5Writer.Builder().setDestination(dest).setCores(2); + b.setSource(src.toFile()); + b.build().write(); + }); + } + + @Test + void nestedAndMapBlankNodesAreAlsoRejected() throws Exception { + Path nested = ttl("nested-bad.ttl", """ + @prefix : . + @prefix cdt: . + :s :list "[[_:b1]]"^^cdt:List . + """); + assertGuardFires(() -> HDF5Writer.Builder() + .setSource(nested.toFile()) + .setDestination(dir.resolve("nested-bad.h5").toFile()).build().write()); + + Path mapValue = ttl("map-bad.ttl", """ + @prefix : . + @prefix cdt: . + :s :map "{\\"k\\": _:b1}"^^cdt:Map . + """); + assertGuardFires(() -> HDF5Writer.Builder() + .setSource(mapValue.toFile()) + .setDestination(dir.resolve("map-bad.h5").toFile()).build().write()); + + Path deep = ttl("deep-bad.ttl", """ + @prefix : . + @prefix cdt: . + :s :list "[{\\"k\\": [_:deep]}]"^^cdt:List . + """); + assertGuardFires(() -> HDF5Writer.Builder() + .setSource(deep.toFile()) + .setDestination(dir.resolve("deep-bad.h5").toFile()).build().write()); + } + + @Test + void boundariesStayOpen() throws Exception { + // No blank node; and "_:x" inside a QUOTED STRING element (a string, not + // a bnode - rejecting it would mean the detector substring-matches + // instead of parsing). Both must build and round-trip. + Path src = ttl("good.ttl", """ + @prefix : . + @prefix cdt: . + :s :plain "[1, 2]"^^cdt:List . + :s :quoted "[\\"_:x\\"]"^^cdt:List . + """); + File dest = dir.resolve("good.h5").toFile(); + HDF5Writer.Builder().setSource(src.toFile()).setDestination(dest).build().write(); + + try (BeakGraph bg = BG.getBeakGraph(dest)) { + java.util.Set stored = new java.util.TreeSet<>(); + bg.getDataset().getDefaultModel().listStatements().forEachRemaining(st -> { + Node n = st.getObject().asNode(); + if (n.isLiteral()) { + stored.add(n.getLiteralLexicalForm()); + } + }); + assertEquals(new java.util.TreeSet<>(java.util.Set.of( + "[1, 2]", "[\"_:x\"]")), stored); + } + } + + /** + * Not a BeakGraph guard, but a boundary this suite depends on: RIOT's + * CDT-aware parser profile validates composite lexical forms, so an + * ILL-FORMED composite literal never reaches BeakGraph's ingest from a + * parsed source - the parse itself fails. (Programmatically-built + * ill-formed nodes are still possible; NodeComparatorCdtTest covers their + * ordering.) If a Jena upgrade relaxes this, the blank-node detector's + * ill-formed branch becomes reachable from documents and this suite should + * grow a corresponding ingest test. + */ + @Test + void illFormedCompositeIsRejectedByTheParser() throws Exception { + Path src = ttl("illformed.ttl", """ + @prefix : . + @prefix cdt: . + :s :illformed "[_:b1"^^cdt:List . + """); + File dest = dir.resolve("illformed.h5").toFile(); + Exception ex = assertThrows(Exception.class, () -> + HDF5Writer.Builder().setSource(src.toFile()).setDestination(dest).build().write()); + boolean parserRejected = false; + for (Throwable c = ex; c != null; c = c.getCause()) { + if (c instanceof org.apache.jena.datatypes.DatatypeFormatException) { + parserRejected = true; + break; + } + } + assertTrue(parserRejected, "expected RIOT's CDT validation to reject the parse: " + ex); + } +} diff --git a/src/test/java/com/ebremer/beakgraph/CdtLockInTest.java b/src/test/java/com/ebremer/beakgraph/CdtLockInTest.java new file mode 100644 index 00000000..ceb7b870 --- /dev/null +++ b/src/test/java/com/ebremer/beakgraph/CdtLockInTest.java @@ -0,0 +1,213 @@ +package com.ebremer.beakgraph; + +import static org.junit.jupiter.api.Assertions.assertEquals; +import static org.junit.jupiter.api.Assertions.assertTrue; + +import com.ebremer.beakgraph.core.BeakGraph; +import com.ebremer.beakgraph.hdf5.writers.HDF5Writer; +import java.io.File; +import java.nio.file.Files; +import java.nio.file.Path; +import java.util.ArrayList; +import java.util.List; +import java.util.Set; +import java.util.TreeSet; +import org.apache.jena.query.Dataset; +import org.apache.jena.query.QueryExecution; +import org.apache.jena.query.QueryFactory; +import org.apache.jena.query.QuerySolution; +import org.apache.jena.query.ResultSet; +import org.junit.jupiter.api.AfterAll; +import org.junit.jupiter.api.BeforeAll; +import org.junit.jupiter.api.Test; +import org.junit.jupiter.api.io.TempDir; + +/** + * SPARQL-CDT lock-in: composite datatype literals (cdt:List / cdt:Map) already + * work over a BeakGraph store with zero BeakGraph code - they ride the + * term-exact strings path, and Jena 6.x registers the datatypes, all 16 cdt: + * functions, the FOLD aggregate, and the UNFOLD operator by default. This test + * converts that accidental behavior into defended behavior: if a Jena upgrade, + * a parser-profile change, or a storage change breaks any of it, this is what + * notices. + * + *

The 16 functions exercised (namespace http://w3id.org/awslabs/neptune/SPARQL-CDTs/): + * List, Map, concat, contains, containsKey, containsTerm, get, head, keys, + * merge, put, remove, reverse, size, subseq, tail. + */ +class CdtLockInTest { + + private static final String TTL = """ + @prefix : . + @prefix cdt: . + :s :list "[1, 2, 3]"^^cdt:List . + :s :map "{\\"k1\\": 5, \\"k2\\": 7}"^^cdt:Map . + :s :nested "[[1, 2], [3]]"^^cdt:List . + :s :mixed "[, \\"tag\\"@en, null]"^^cdt:List . + :g :v 1 . + :g :v 2 . + :g :v 3 . + """; + + private static final String PRE = + "PREFIX cdt: PREFIX : "; + + @TempDir + static Path dir; + static BeakGraph bg; + static Dataset ds; + + @BeforeAll + static void build() throws Exception { + Path src = dir.resolve("cdt.ttl"); + Files.writeString(src, TTL); + File dest = dir.resolve("cdt.h5").toFile(); + HDF5Writer.Builder().setSource(src.toFile()).setDestination(dest).build().write(); + bg = BG.getBeakGraph(dest); + ds = bg.getDataset(); + } + + @AfterAll + static void close() throws Exception { + if (bg != null) { + bg.close(); + } + } + + private static QuerySolution one(String query) { + try (QueryExecution qe = QueryExecution.dataset(ds).query(QueryFactory.create(PRE + query)).build()) { + ResultSet rs = qe.execSelect(); + assertTrue(rs.hasNext(), "no solution for: " + query); + QuerySolution qs = rs.nextSolution(); + assertTrue(!rs.hasNext(), "more than one solution for: " + query); + return qs; + } + } + + private static List all(String query) { + try (QueryExecution qe = QueryExecution.dataset(ds).query(QueryFactory.create(PRE + query)).build()) { + List out = new ArrayList<>(); + qe.execSelect().forEachRemaining(out::add); + return out; + } + } + + @Test + void compositeLiteralsRoundTripTermExactly() { + Set stored = new TreeSet<>(); + ds.getDefaultModel().listStatements().forEachRemaining(st -> { + if (st.getObject().isLiteral() + && st.getObject().asNode().getLiteralDatatypeURI() + .startsWith("http://w3id.org/awslabs/neptune/SPARQL-CDTs/")) { + stored.add(st.getObject().asNode().getLiteralLexicalForm() + + " ^^ " + st.getObject().asNode().getLiteralDatatypeURI()); + } + }); + Set expected = new TreeSet<>(Set.of( + "[1, 2, 3] ^^ http://w3id.org/awslabs/neptune/SPARQL-CDTs/List", + "{\"k1\": 5, \"k2\": 7} ^^ http://w3id.org/awslabs/neptune/SPARQL-CDTs/Map", + "[[1, 2], [3]] ^^ http://w3id.org/awslabs/neptune/SPARQL-CDTs/List", + "[, \"tag\"@en, null] ^^ http://w3id.org/awslabs/neptune/SPARQL-CDTs/List")); + assertEquals(expected, stored, "CDT literals must round-trip lexical-form- and datatype-exact"); + } + + @Test + void listFunctionsOverTheStore() { + QuerySolution s = one(""" + SELECT * WHERE { + :s :list ?l . + :s :nested ?nl . + BIND(cdt:size(?l) AS ?sz) + BIND(cdt:get(?l, 1) AS ?first) + BIND(cdt:head(?l) AS ?hd) + BIND(cdt:contains(?l, 2) AS ?has2) + BIND(cdt:containsTerm(?l, 3) AS ?hasT3) + BIND(cdt:size(cdt:tail(?l)) AS ?tsz) + BIND(cdt:get(cdt:reverse(?l), 1) AS ?rfirst) + BIND(cdt:get(cdt:subseq(?l, 2, 2), 1) AS ?sub1) + BIND(cdt:size(cdt:concat(?l, ?l)) AS ?csz) + BIND(cdt:size(cdt:List(9, 8)) AS ?nlsz) + BIND(cdt:get(cdt:get(?nl, 1), 2) AS ?nested12) + }"""); + assertEquals(3, s.getLiteral("sz").getInt()); + assertEquals(1, s.getLiteral("first").getInt()); + assertEquals(1, s.getLiteral("hd").getInt()); + assertTrue(s.getLiteral("has2").getBoolean()); + assertTrue(s.getLiteral("hasT3").getBoolean()); + assertEquals(2, s.getLiteral("tsz").getInt()); + assertEquals(3, s.getLiteral("rfirst").getInt()); + assertEquals(2, s.getLiteral("sub1").getInt()); + assertEquals(6, s.getLiteral("csz").getInt()); + assertEquals(2, s.getLiteral("nlsz").getInt()); + assertEquals(2, s.getLiteral("nested12").getInt()); + } + + @Test + void mapFunctionsOverTheStore() { + QuerySolution s = one(""" + SELECT * WHERE { + :s :map ?m . + BIND(cdt:get(?m, "k1") AS ?g) + BIND(cdt:size(?m) AS ?sz) + BIND(cdt:containsKey(?m, "k1") AS ?ck) + BIND(cdt:size(cdt:keys(?m)) AS ?ksz) + BIND(cdt:size(cdt:merge(?m, ?m)) AS ?msz) + BIND(cdt:size(cdt:put(?m, "k3", 9)) AS ?psz) + BIND(cdt:size(cdt:remove(?m, "k1")) AS ?rsz) + BIND(cdt:containsKey(cdt:Map("a", 1), "a") AS ?cm) + }"""); + assertEquals(5, s.getLiteral("g").getInt()); + assertEquals(2, s.getLiteral("sz").getInt()); + assertTrue(s.getLiteral("ck").getBoolean()); + assertEquals(2, s.getLiteral("ksz").getInt()); + assertEquals(2, s.getLiteral("msz").getInt()); + assertEquals(3, s.getLiteral("psz").getInt()); + assertEquals(1, s.getLiteral("rsz").getInt()); + assertTrue(s.getLiteral("cm").getBoolean()); + } + + @Test + void foldAggregatesOverTheStore() { + QuerySolution list = one(""" + SELECT (cdt:size(?l) AS ?n) (cdt:get(?l, 1) AS ?first) (DATATYPE(?l) AS ?dt) WHERE { + { SELECT (FOLD(?v ORDER BY ?v) AS ?l) WHERE { :g :v ?v } } + }"""); + assertEquals(3, list.getLiteral("n").getInt()); + assertEquals(1, list.getLiteral("first").getInt()); + assertEquals("http://w3id.org/awslabs/neptune/SPARQL-CDTs/List", + list.getResource("dt").getURI()); + + QuerySolution map = one(""" + SELECT (cdt:containsKey(?mp, "a") AS ?ca) (cdt:get(?mp, "b") AS ?gb) WHERE { + { SELECT (FOLD(?k, ?v) AS ?mp) WHERE { VALUES (?k ?v) { ("a" 1) ("b" 2) } } } + }"""); + assertTrue(map.getLiteral("ca").getBoolean()); + assertEquals(2, map.getLiteral("gb").getInt()); + } + + @Test + void unfoldOverTheStore() { + List rows = all( + "SELECT ?e WHERE { :s :list ?l . UNFOLD(?l AS ?e) } ORDER BY ?e"); + assertEquals(3, rows.size()); + for (int i = 0; i < 3; i++) { + assertEquals(i + 1, rows.get(i).getLiteral("e").getInt()); + } + + List indexed = all( + "SELECT ?e ?i WHERE { :s :list ?l . UNFOLD(?l AS ?e, ?i) } ORDER BY ?i"); + assertEquals(3, indexed.size()); + for (int i = 0; i < 3; i++) { + assertEquals(i + 1, indexed.get(i).getLiteral("i").getInt(), "1-based position"); + assertEquals(i + 1, indexed.get(i).getLiteral("e").getInt(), "element at that position"); + } + + List entries = all( + "SELECT ?k ?v WHERE { :s :map ?m . UNFOLD(?m AS ?k, ?v) } ORDER BY ?k"); + assertEquals(2, entries.size()); + assertEquals("k1", entries.get(0).getLiteral("k").getString()); + assertEquals(5, entries.get(0).getLiteral("v").getInt()); + assertEquals("k2", entries.get(1).getLiteral("k").getString()); + assertEquals(7, entries.get(1).getLiteral("v").getInt()); + } +} diff --git a/src/test/java/com/ebremer/beakgraph/RDF12ContainmentTest.java b/src/test/java/com/ebremer/beakgraph/RDF12ContainmentTest.java new file mode 100644 index 00000000..d4807d04 --- /dev/null +++ b/src/test/java/com/ebremer/beakgraph/RDF12ContainmentTest.java @@ -0,0 +1,209 @@ +package com.ebremer.beakgraph; + +import static org.junit.jupiter.api.Assertions.assertEquals; +import static org.junit.jupiter.api.Assertions.assertNull; +import static org.junit.jupiter.api.Assertions.assertThrows; +import static org.junit.jupiter.api.Assertions.assertTrue; + +import com.ebremer.beakgraph.core.BeakGraph; +import com.ebremer.beakgraph.core.BeakGraphWriter; +import com.ebremer.beakgraph.core.lib.Stats; +import com.ebremer.beakgraph.hdf5.Types; +import com.ebremer.beakgraph.hdf5.writers.HDF5Writer; +import com.ebremer.beakgraph.hdf5.writers.MultiTypeDictionaryWriter; +import com.ebremer.beakgraph.hdf5.writers.hugeUltra.HugeUltraHDF5Writer; +import com.ebremer.beakgraph.hdf5.writers.parallel.ParallelHDF5Writer; +import com.ebremer.beakgraph.hdf5.writers.plaid.PlaidHDF5Writer; +import com.ebremer.beakgraph.hdf5.writers.ultra.UltraHDF5Writer; +import com.ebremer.beakgraph.huge.HugeHDF5Writer; +import com.ebremer.beakgraph.huge.NativeHdf5File; +import java.io.File; +import java.nio.file.Files; +import java.nio.file.Path; +import java.util.HashSet; +import java.util.List; +import java.util.Set; +import java.util.stream.Stream; +import org.apache.jena.graph.Node; +import org.apache.jena.graph.NodeFactory; +import org.apache.jena.query.Dataset; +import org.apache.jena.vocabulary.RDF; +import org.junit.jupiter.api.Assumptions; +import org.junit.jupiter.api.Test; +import org.junit.jupiter.api.io.TempDir; +import org.junit.jupiter.params.ParameterizedTest; +import org.junit.jupiter.params.provider.Arguments; +import org.junit.jupiter.params.provider.MethodSource; + +/** + * RDF 1.2 containment: Jena 6.x parses base-direction literals ("x"@en--ltr, + * rdf:dirLangString) by default, but the BeakGraph format has nowhere to store + * the direction - before the ingest guards, such a term was silently rewritten + * to "x"@en (a DIFFERENT RDF term; three distinct source terms collapsed onto + * one). These tests pin the containment stance: a source containing a + * base-direction literal must fail the build loudly, in every writer engine, + * and must not publish a store. + * + *

When real rdf:dirLangString storage lands (a langDirs column beside + * langs/langTags), the rejection guards are removed and these tests are + * REPLACED by term-exact round-trip tests - do not delete them without that + * replacement. + */ +class RDF12ContainmentTest { + + private static final String BAD_TTL = """ + @prefix : . + :s :p "x"@en--ltr . + :s :q "plain"@en . + """; + + private static final String GOOD_TTL = """ + @prefix : . + :s :q "plain"@en . + :s :r "untagged" . + """; + + private static final String GUARD_MESSAGE = "base direction cannot be stored"; + + @TempDir + static Path dir; + + @FunctionalInterface + interface Engine { + BeakGraphWriter create(File src, File dest) throws Exception; + } + + static Stream engines() { + return Stream.of( + Arguments.of("method0-HDF5Writer", false, (Engine) (src, dest) -> + HDF5Writer.Builder().setSource(src).setDestination(dest).build()), + Arguments.of("method1-Huge", true, (Engine) (src, dest) -> { + HugeHDF5Writer.Builder b = HugeHDF5Writer.Builder().setDestination(dest); + b.setSource(src); + return b.build(); + }), + Arguments.of("method2-Parallel", false, (Engine) (src, dest) -> { + ParallelHDF5Writer.Builder b = ParallelHDF5Writer.Builder() + .setDestination(dest).setCores(2); + b.setSource(src); + return b.build(); + }), + Arguments.of("method3-Ultra", false, (Engine) (src, dest) -> { + UltraHDF5Writer.Builder b = UltraHDF5Writer.Builder() + .setDestination(dest).setCores(2); + b.setSource(src); + return b.build(); + }), + Arguments.of("method4-HugeUltra", true, (Engine) (src, dest) -> { + HugeUltraHDF5Writer.Builder b = HugeUltraHDF5Writer.Builder() + .setDestination(dest).setCores(2); + b.setSource(src); + return b.build(); + }), + Arguments.of("method5-Plaid", true, (Engine) (src, dest) -> { + PlaidHDF5Writer.Builder b = PlaidHDF5Writer.Builder() + .setDestination(dest).setCores(2); + b.setSource(src); + return b.build(); + }) + ); + } + + @ParameterizedTest(name = "{0}") + @MethodSource("engines") + void baseDirectionLiteralAbortsTheBuild(String name, boolean needsNative, Engine engine) throws Exception { + Assumptions.assumeTrue(!needsNative || NativeHdf5File.isAvailable(), + "native HDF5 library unavailable"); + Path src = dir.resolve(name + "-bad.ttl"); + Files.writeString(src, BAD_TTL); + File dest = dir.resolve(name + "-bad.h5").toFile(); + + Exception ex = assertThrows(Exception.class, + () -> engine.create(src.toFile(), dest).write()); + assertTrue(chainMentionsGuard(ex), + "build failed, but not on the base-direction guard: " + ex); + assertNoUsableStore(dest); + } + + @Test + void plainLanguageTagsStillBuildAndRoundTrip() throws Exception { + Path src = dir.resolve("good.ttl"); + Files.writeString(src, GOOD_TTL); + File dest = dir.resolve("good.h5").toFile(); + HDF5Writer.Builder().setSource(src.toFile()).setDestination(dest).build().write(); + assertControlRoundTrips(dest); + } + + @Test + void plainLanguageTagsStillBuildAndRoundTripUltra() throws Exception { + Path src = dir.resolve("good-ultra.ttl"); + Files.writeString(src, GOOD_TTL); + File dest = dir.resolve("good-ultra.h5").toFile(); + UltraHDF5Writer.Builder b = UltraHDF5Writer.Builder().setDestination(dest).setCores(2); + b.setSource(src.toFile()); + b.build().write(); + assertControlRoundTrips(dest); + } + + /** The dictionary encoder's own guard, driven directly (bypasses the ingest guards). */ + @Test + void multiTypeDictionaryWriterRejectsBaseDirectionLiteral() { + Stats stats = new Stats(); + stats.numStrings = 1; + stats.longestStringLength = 5; + stats.shortestStringLength = 5; + Node bad = NodeFactory.createLiteralDirLang("hello", "en", "ltr"); + IllegalStateException ex = assertThrows(IllegalStateException.class, () -> + new MultiTypeDictionaryWriter.Builder() + .enable(Types.STRING, Types.INTEGER, Types.LONG, Types.FLOAT, Types.DOUBLE) + .setStats(stats) + .setNodes(new HashSet<>(Set.of(bad))) + .setDataTypes(Set.of(RDF.dirLangString.getURI())) + .setName("literals") + .build()); + assertTrue(ex.getMessage().contains(GUARD_MESSAGE), ex.getMessage()); + } + + // ---- helpers ---- + + private static boolean chainMentionsGuard(Throwable t) { + for (Throwable c = t; c != null; c = c.getCause()) { + if (c.getMessage() != null && c.getMessage().contains(GUARD_MESSAGE)) { + return true; + } + } + return false; + } + + /** + * "Not silently store": the aborted build must not publish a readable store. + * Writers build into a sibling *.tmp and publish by atomic rename, so the + * destination normally does not exist; if some engine left a file behind, + * it must at least not open as a BeakGraph. + */ + private static void assertNoUsableStore(File dest) { + if (!dest.exists()) { + return; + } + assertThrows(Exception.class, () -> { + try (BeakGraph bg = BG.getBeakGraph(dest)) { + bg.getDataset(); + } + }, "a store was published from a build that should have aborted"); + } + + private static void assertControlRoundTrips(File dest) throws Exception { + Node expected = NodeFactory.createLiteralLang("plain", "en"); + try (BeakGraph bg = BG.getBeakGraph(dest)) { + Dataset ds = bg.getDataset(); + List objects = ds.getDefaultModel() + .listObjectsOfProperty(ds.getDefaultModel() + .createProperty("http://ex.org/q")) + .mapWith(o -> o.asNode()).toList(); + assertEquals(1, objects.size()); + assertEquals(expected, objects.get(0)); + assertNull(objects.get(0).getLiteralBaseDirection(), + "a plain lang tag must carry no base direction"); + } + } +} diff --git a/src/test/java/com/ebremer/beakgraph/core/lib/NodeComparatorCdtTest.java b/src/test/java/com/ebremer/beakgraph/core/lib/NodeComparatorCdtTest.java new file mode 100644 index 00000000..6fddbc7a --- /dev/null +++ b/src/test/java/com/ebremer/beakgraph/core/lib/NodeComparatorCdtTest.java @@ -0,0 +1,193 @@ +package com.ebremer.beakgraph.core.lib; + +import static org.junit.jupiter.api.Assertions.assertEquals; +import static org.junit.jupiter.api.Assertions.assertTrue; + +import com.ebremer.beakgraph.BG; +import com.ebremer.beakgraph.core.BeakGraph; +import com.ebremer.beakgraph.hdf5.writers.HDF5Writer; +import java.io.File; +import java.nio.file.Files; +import java.nio.file.Path; +import java.util.ArrayList; +import java.util.Collections; +import java.util.List; +import java.util.Random; +import java.util.Set; +import java.util.TreeSet; +import org.apache.jena.datatypes.TypeMapper; +import org.apache.jena.graph.Node; +import org.apache.jena.graph.NodeFactory; +import org.junit.jupiter.api.Test; +import org.junit.jupiter.api.io.TempDir; + +/** + * Pins the composite-literal (cdt:List / cdt:Map) ordering fix in + * {@link NodeComparator}: composite pairs compare on (datatype IRI, lexical + * form), never by value. + * + *

The pre-fix behavior this guards against: well-formed numeric lists + * compared by VALUE while any pair touching an ill-formed literal fell back to + * TERM order, and mixing the two is cyclic - verified as + * {@code [9] < [10] < "[5" < [9]} - so dictionary ids (which ARE comparator + * ranks) became input-order-dependent: 11 of 12 shuffled sorts of the same + * literals produced different orders, and lookups could miss stored terms. + */ +class NodeComparatorCdtTest { + + private static final String LIST = "http://w3id.org/awslabs/neptune/SPARQL-CDTs/List"; + private static final String MAP = "http://w3id.org/awslabs/neptune/SPARQL-CDTs/Map"; + private static final String STRING = "http://www.w3.org/2001/XMLSchema#string"; + private static final String INTEGER = "http://www.w3.org/2001/XMLSchema#integer"; + + @TempDir + static Path dir; + + private static Node lit(String lex, String dt) { + return NodeFactory.createLiteralDT(lex, TypeMapper.getInstance().getSafeTypeByName(dt)); + } + + private static int sign(Node a, Node b) { + return Integer.signum(NodeComparator.INSTANCE.compare(a, b)); + } + + /** The exact trio that used to form a cycle. */ + @Test + void formerCycleIsNowTransitive() { + Node nine = lit("[9]", LIST); + Node ten = lit("[10]", LIST); + Node illFormed = lit("[5", LIST); + // One scheme now - lexical: "[10]" < "[5" < "[9]". A consistent chain, + // where the old value/term mix gave [9] < [10] < "[5" < [9]. + assertEquals(1, sign(nine, ten)); + assertEquals(-1, sign(ten, illFormed)); + assertEquals(-1, sign(illFormed, nine)); + } + + /** + * Full asymmetry + transitivity sweep over composites (well-formed, + * ill-formed, nested, blank-node-bearing, List and Map) MIXED with + * ordinary literals - the mixed pairs stay on the compareAlways path, so + * the sweep also proves the two schemes cannot disagree into a cycle. + */ + @Test + void orderingIsATotalOrderIncludingIllFormed() { + List cand = new ArrayList<>(); + for (String lex : new String[]{ + "[1]", "[2]", "[9]", "[10]", "[100]", "[99]", "[5]", + "[", "[5", "[12,", "[9,", + "[_:b1]", "[null]", "[\"a\"]", "[]", "[1, 2]", "[true]"}) { + cand.add(lit(lex, LIST)); + } + cand.add(lit("{\"k\": 1}", MAP)); + cand.add(lit("{", MAP)); + cand.add(lit("!!!", STRING)); + cand.add(lit("zzz", STRING)); + cand.add(lit("5", INTEGER)); + cand.add(lit("50", INTEGER)); + + int asymmetry = 0; + int intransitive = 0; + for (Node a : cand) { + for (Node b : cand) { + if (sign(a, b) != -sign(b, a)) { + asymmetry++; + } + } + } + for (Node a : cand) { + for (Node b : cand) { + for (Node c : cand) { + if (sign(a, b) < 0 && sign(b, c) < 0 && sign(a, c) >= 0) { + intransitive++; + } + } + } + } + assertEquals(0, asymmetry, "compare(a,b) must be the negation of compare(b,a)"); + assertEquals(0, intransitive, "a < b < c must imply a < c"); + } + + /** Input order must not leak into the "sorted" order (it did pre-fix: 11/12 seeds disagreed). */ + @Test + void shuffledSortsAgree() { + List pool = new ArrayList<>(); + for (int k = 1; k <= 60; k++) { + pool.add(lit("[" + k + "]", LIST)); + } + pool.add(lit("[5", LIST)); + pool.add(lit("[", LIST)); + pool.add(lit("[12,", LIST)); + pool.add(lit("{\"k\": 1}", MAP)); + + List reference = null; + for (int seed = 0; seed < 12; seed++) { + List shuffled = new ArrayList<>(pool); + Collections.shuffle(shuffled, new Random(seed)); + shuffled.sort(NodeComparator.INSTANCE); + if (reference == null) { + reference = shuffled; + } else { + assertEquals(reference, shuffled, "sort order depended on input order (seed " + seed + ")"); + } + } + } + + @Test + void compareIsZeroExactlyForIdenticalCompositeTerms() { + Node a = lit("[1, 2]", LIST); + Node sameTerm = lit("[1, 2]", LIST); + Node sameValueDifferentLex = lit("[1,2]", LIST); + assertEquals(0, sign(a, sameTerm)); + assertTrue(sign(a, sameValueDifferentLex) != 0, + "CDT has no canonical form: value-equal but lexically distinct literals are distinct terms"); + } + + @Test + void listsSortBeforeMaps() { + // Datatype-IRI order (.../List < .../Map), matching compareAlways' value-space rank. + assertEquals(-1, sign(lit("[1]", LIST), lit("{\"k\": 1}", MAP))); + assertEquals(-1, sign(lit("[5", LIST), lit("{", MAP))); + } + + /** + * End to end: a store containing lists whose VALUE order and LEXICAL order + * disagree ([9] vs [10] - their dictionary ranks swap under the fix) must + * round-trip its term set exactly, i.e. the dictionary binary search finds + * every stored term under the new order. (No ill-formed literal here: + * RIOT's CDT-aware parser profile rejects those at parse, so they cannot + * enter a store from a source document at all - pinned by + * CdtBlankNodeGuardTest#illFormedCompositeIsRejectedByTheParser.) + */ + @Test + void storeWithValueLexDisagreeingListsRoundTrips() throws Exception { + String ttl = """ + @prefix : . + @prefix cdt: . + :s :a "[9]"^^cdt:List . + :s :b "[10]"^^cdt:List . + :s :d "{\\"k\\": 1}"^^cdt:Map . + :s :e "plain" . + """; + Path src = dir.resolve("cycle.ttl"); + Files.writeString(src, ttl); + File dest = dir.resolve("cycle.h5").toFile(); + HDF5Writer.Builder().setSource(src.toFile()).setDestination(dest).build().write(); + + Set stored = new TreeSet<>(); + try (BeakGraph bg = BG.getBeakGraph(dest)) { + bg.getDataset().getDefaultModel().listStatements().forEachRemaining(st -> { + if (st.getObject().isLiteral()) { + Node n = st.getObject().asNode(); + stored.add(n.getLiteralLexicalForm() + " ^^ " + n.getLiteralDatatypeURI()); + } + }); + } + Set expected = new TreeSet<>(Set.of( + "[9] ^^ " + LIST, + "[10] ^^ " + LIST, + "{\"k\": 1} ^^ " + MAP, + "plain ^^ " + STRING)); + assertEquals(expected, stored); + } +} diff --git a/src/test/java/com/ebremer/beakgraph/huge/DirLangSpillGuardTest.java b/src/test/java/com/ebremer/beakgraph/huge/DirLangSpillGuardTest.java new file mode 100644 index 00000000..0e4ba356 --- /dev/null +++ b/src/test/java/com/ebremer/beakgraph/huge/DirLangSpillGuardTest.java @@ -0,0 +1,106 @@ +package com.ebremer.beakgraph.huge; + +import static org.junit.jupiter.api.Assertions.assertEquals; +import static org.junit.jupiter.api.Assertions.assertThrows; +import static org.junit.jupiter.api.Assertions.assertTrue; + +import com.ebremer.beakgraph.core.lib.Stats; +import com.ebremer.beakgraph.hdf5.Types; +import java.io.ByteArrayInputStream; +import java.io.ByteArrayOutputStream; +import java.io.DataInputStream; +import java.io.DataOutputStream; +import java.io.IOException; +import java.nio.file.Path; +import java.util.List; +import java.util.Set; +import java.util.TreeSet; +import org.apache.jena.datatypes.TypeMapper; +import org.apache.jena.graph.Node; +import org.apache.jena.graph.NodeFactory; +import org.apache.jena.vocabulary.RDF; +import org.junit.jupiter.api.Test; +import org.junit.jupiter.api.io.TempDir; + +/** + * The disk pipeline's guards against RDF 1.2 base-direction literals + * (rdf:dirLangString), driven directly - the ingest guards normally fire + * first, so these layers are unreachable end-to-end by design: + *

+ */ +class DirLangSpillGuardTest { + + private static final String GUARD_MESSAGE = "base direction cannot be stored"; + + @TempDir + static Path dir; + + private static Node roundTrip(Node n) throws IOException { + ByteArrayOutputStream bos = new ByteArrayOutputStream(); + NodeCodec.writeNode(new DataOutputStream(bos), n); + return NodeCodec.readNode(new DataInputStream(new ByteArrayInputStream(bos.toByteArray()))); + } + + private static Stats stringStats() { + Stats s = new Stats(); + s.numStrings = 1; + s.longestStringLength = 5; + s.shortestStringLength = 5; + return s; + } + + @Test + void nodeCodecRejectsBaseDirectionLiteral() { + Node bad = NodeFactory.createLiteralDirLang("hello", "en", "ltr"); + IllegalStateException ex = assertThrows(IllegalStateException.class, () -> + NodeCodec.writeNode(new DataOutputStream(new ByteArrayOutputStream()), bad)); + assertTrue(ex.getMessage().contains(GUARD_MESSAGE), ex.getMessage()); + } + + @Test + void nodeCodecRoundTripsOrdinaryTermsExactly() throws IOException { + Node lang = NodeFactory.createLiteralLang("hello", "en"); + Node typed = NodeFactory.createLiteralDT("42", + TypeMapper.getInstance().getSafeTypeByName("http://www.w3.org/2001/XMLSchema#integer")); + Node uri = NodeFactory.createURI("http://ex.org/a"); + Node bnode = NodeFactory.createBlankNode("b1"); + assertEquals(lang, roundTrip(lang)); + assertEquals(typed, roundTrip(typed)); + assertEquals(uri, roundTrip(uri)); + assertEquals(bnode, roundTrip(bnode)); + } + + @Test + void streamingDictionaryWriterRejectsBaseDirectionLiteral() { + Node bad = NodeFactory.createLiteralDirLang("hello", "en", "ltr"); + IllegalStateException ex = assertThrows(IllegalStateException.class, () -> { + try (StreamingDictionaryWriter w = new StreamingDictionaryWriter( + dir.resolve("reject"), "literals", 1, stringStats(), + Set.of(Types.STRING, Types.INTEGER, Types.LONG, Types.FLOAT, Types.DOUBLE), + new TreeSet<>(Set.of(RDF.dirLangString.getURI())), + new TreeSet<>(Set.of("en")))) { + w.encode(List.of(bad).iterator()); + } + }); + assertTrue(ex.getMessage().contains(GUARD_MESSAGE), ex.getMessage()); + } + + @Test + void streamingDictionaryWriterEncodesPlainLangTag() throws Exception { + Node good = NodeFactory.createLiteralLang("hello", "en"); + try (StreamingDictionaryWriter w = new StreamingDictionaryWriter( + dir.resolve("control"), "literals", 1, stringStats(), + Set.of(Types.STRING, Types.INTEGER, Types.LONG, Types.FLOAT, Types.DOUBLE), + new TreeSet<>(Set.of(RDF.langString.getURI())), + new TreeSet<>(Set.of("en")))) { + w.encode(List.of(good).iterator()); + } + } +} From cafa6d574f2d6d0751009d7e840860cc2d054fab Mon Sep 17 00:00:00 2001 From: Erich Bremer Date: Thu, 16 Jul 2026 19:24:56 -0400 Subject: [PATCH 2/5] phase 4 --- .../beakgraph/core/lib/NodeComparator.java | 72 ++- .../ebremer/beakgraph/TermFidelityTest.java | 161 ++++++ .../com/ebremer/beakgraph/WriterEngines.java | 80 +++ .../core/lib/NodeComparatorCdtTest.java | 7 + .../core/lib/NodeComparatorDirLangTest.java | 131 +++++ .../beakgraph/w3c/W3CRdf12SuiteTest.java | 255 +++++++++ src/test/resources/w3c/rdf12/LICENSE.md | 2 + src/test/resources/w3c/rdf12/README.md | 28 + .../resources/w3c/rdf12/rdf-n-quads/README.md | 18 + .../c14n/comment_following_triple-c14n.nq | 1 + .../c14n/comment_following_triple.nq | 2 + .../c14n/dirlangtagged_string-c14n.nq | 1 + .../rdf-n-quads/c14n/dirlangtagged_string.nq | 1 + .../c14n/extra_whitespace-01-c14n.nq | 1 + .../rdf-n-quads/c14n/extra_whitespace-01.nq | 1 + .../c14n/extra_whitespace-02-c14n.nq | 1 + .../rdf-n-quads/c14n/extra_whitespace-02.nq | 1 + .../c14n/extra_whitespace-03-c14n.nq | 1 + .../rdf-n-quads/c14n/extra_whitespace-03.nq | 1 + .../c14n/extra_whitespace-04-c14n.nq | 1 + .../rdf-n-quads/c14n/extra_whitespace-04.nq | 1 + .../c14n/langtagged_string-c14n.nq | 1 + .../rdf-n-quads/c14n/langtagged_string.nq | 1 + .../c14n/literal_all_controls-c14n.nq | 1 + .../rdf-n-quads/c14n/literal_all_controls.nq | 1 + .../c14n/literal_all_punctuation-c14n.nq | 1 + .../c14n/literal_all_punctuation.nq | 1 + .../c14n/literal_ascii_boundaries-c14n.nq | 1 + .../c14n/literal_ascii_boundaries.nq | Bin 0 -> 76 bytes .../literal_needing_uchar_escaping-01-c14n.nq | 1 + .../c14n/literal_needing_uchar_escaping-01.nq | Bin 0 -> 103 bytes .../c14n/literal_needing_uchar_escaping-02.nq | 2 + .../c14n/literal_with_2_dquotes-c14n.nq | 1 + .../c14n/literal_with_2_dquotes.nq | 1 + .../c14n/literal_with_2_squotes-c14n.nq | 1 + .../c14n/literal_with_2_squotes.nq | 1 + .../c14n/literal_with_BACKSPACE-c14n.nq | 1 + .../c14n/literal_with_BACKSPACE.nq | 1 + .../c14n/literal_with_CARRIAGE_RETURN-c14n.nq | 1 + .../c14n/literal_with_CARRIAGE_RETURN.nq | 1 + .../literal_with_CHARACTER_TABULATION-c14n.nq | 1 + .../c14n/literal_with_CHARACTER_TABULATION.nq | 1 + .../c14n/literal_with_FORM_FEED-c14n.nq | 1 + .../c14n/literal_with_FORM_FEED.nq | 1 + .../c14n/literal_with_LINE_FEED-c14n.nq | 1 + .../c14n/literal_with_LINE_FEED.nq | 1 + .../c14n/literal_with_REVERSE_SOLIDUS-c14n.nq | 1 + .../c14n/literal_with_REVERSE_SOLIDUS.nq | 1 + .../literal_with_REVERSE_SOLIDUS2-c14n.nq | 1 + .../c14n/literal_with_REVERSE_SOLIDUS2.nq | 1 + .../c14n/literal_with_UTF8_boundaries-c14n.nq | 1 + .../c14n/literal_with_UTF8_boundaries.nq | 1 + .../c14n/literal_with_dquote-c14n.nq | 1 + .../rdf-n-quads/c14n/literal_with_dquote.nq | 1 + .../literal_with_extra_whitespace-c14n.nq | 1 + .../c14n/literal_with_extra_whitespace.nq | 1 + .../c14n/literal_with_numeric_escape4-c14n.nq | 1 + .../c14n/literal_with_numeric_escape4.nq | 1 + .../c14n/literal_with_numeric_escape8-c14n.nq | 1 + .../c14n/literal_with_numeric_escape8.nq | 1 + .../c14n/literal_with_squote-c14n.nq | 1 + .../rdf-n-quads/c14n/literal_with_squote.nq | 1 + .../c14n/literal_with_string_dt-c14n.nq | 1 + .../c14n/literal_with_string_dt.nq | 1 + .../w3c/rdf12/rdf-n-quads/c14n/manifest.ttl | 395 +++++++++++++ .../c14n/minimal_whitespace-01-c14n.nq | 1 + .../rdf-n-quads/c14n/minimal_whitespace-01.nq | 1 + .../c14n/minimal_whitespace-02-c14n.nq | 1 + .../rdf-n-quads/c14n/minimal_whitespace-02.nq | 1 + .../c14n/nq-syntax-str-esc-01-c14n.nq | 1 + .../rdf-n-quads/c14n/nq-syntax-str-esc-01.nq | 1 + .../c14n/nq-syntax-str-esc-02-c14n.nq | 1 + .../rdf-n-quads/c14n/nq-syntax-str-esc-02.nq | 1 + .../c14n/nq-syntax-str-esc-03-c14n.nq | 1 + .../rdf-n-quads/c14n/nq-syntax-str-esc-03.nq | 1 + .../rdf-n-quads/c14n/nq-syntax-uri-01-c14n.nq | 1 + .../rdf-n-quads/c14n/nq-syntax-uri-01.nq | 1 + .../rdf-n-quads/c14n/nq-syntax-uri-02-c14n.nq | 1 + .../rdf-n-quads/c14n/nq-syntax-uri-02.nq | 2 + .../rdf-n-quads/c14n/nq-syntax-uri-03-c14n.nq | 1 + .../rdf-n-quads/c14n/nq-syntax-uri-03.nq | 2 + .../rdf-n-quads/c14n/nq-syntax-uri-04-c14n.nq | 1 + .../rdf-n-quads/c14n/nq-syntax-uri-04.nq | 2 + .../rdf-n-quads/c14n/triple-term-01-c14n.nq | 1 + .../rdf12/rdf-n-quads/c14n/triple-term-01.nq | 1 + .../rdf-n-quads/c14n/triple-term-02-c14n.nq | 1 + .../rdf12/rdf-n-quads/c14n/triple-term-02.nq | 1 + .../rdf-n-quads/c14n/triple-term-03-c14n.nq | 1 + .../rdf12/rdf-n-quads/c14n/triple-term-03.nq | 1 + .../rdf-n-quads/c14n/triple-term-04-c14n.nq | 1 + .../rdf12/rdf-n-quads/c14n/triple-term-04.nq | 1 + .../w3c/rdf12/rdf-n-quads/manifest.ttl | 36 ++ .../w3c/rdf12/rdf-n-quads/syntax/manifest.ttl | 207 +++++++ .../rdf-n-quads/syntax/nquads-langdir-1.nq | 1 + .../rdf-n-quads/syntax/nquads-langdir-2.nq | 1 + .../syntax/nquads-langdir-bad-1.nq | 1 + .../syntax/nquads-langdir-bad-2.nq | 1 + .../syntax/nquads12-bad-reified-syntax-1.nq | 1 + .../syntax/nquads12-bad-reified-syntax-2.nq | 1 + .../syntax/nquads12-bad-reified-syntax-3.nq | 1 + .../syntax/nquads12-bad-reified-syntax-4.nq | 1 + .../syntax/nquads12-bad-syntax-01.nq | 1 + .../syntax/nquads12-bad-syntax-02.nq | 1 + .../syntax/nquads12-bad-syntax-03.nq | 1 + .../syntax/nquads12-bad-syntax-04.nq | 1 + .../syntax/nquads12-bad-syntax-05.nq | 1 + .../syntax/nquads12-bad-syntax-06.nq | 1 + .../syntax/nquads12-bad-syntax-07.nq | 1 + .../syntax/nquads12-bad-syntax-08.nq | 1 + .../syntax/nquads12-bad-syntax-09.nq | 1 + .../syntax/nquads12-bad-syntax-10.nq | 1 + .../rdf-n-quads/syntax/nquads12-bnode-1.nq | 2 + .../nquads12-bnode-bad-annotated-syntax-1.nq | 1 + .../nquads12-bnode-bad-annotated-syntax-2.nq | 1 + .../rdf-n-quads/syntax/nquads12-nested-1.nq | 3 + .../nquads12-nested-bad-annotated-syntax-1.nq | 1 + .../nquads12-nested-bad-annotated-syntax-2.nq | 2 + .../rdf-n-quads/syntax/nquads12-syntax-01.nq | 1 + .../rdf-n-quads/syntax/nquads12-syntax-02.nq | 1 + .../rdf-n-quads/syntax/nquads12-syntax-03.nq | 1 + .../w3c/rdf12/rdf-n-triples/README.md | 18 + .../c14n/comment_following_triple-c14n.nt | 1 + .../c14n/comment_following_triple.nt | 2 + .../c14n/dirlangtagged_string-c14n.nt | 1 + .../c14n/dirlangtagged_string.nt | 1 + .../c14n/extra_whitespace-01-c14n.nt | 1 + .../rdf-n-triples/c14n/extra_whitespace-01.nt | 1 + .../c14n/extra_whitespace-02-c14n.nt | 1 + .../rdf-n-triples/c14n/extra_whitespace-02.nt | 1 + .../c14n/extra_whitespace-03-c14n.nt | 1 + .../rdf-n-triples/c14n/extra_whitespace-03.nt | 1 + .../c14n/extra_whitespace-04-c14n.nt | 1 + .../rdf-n-triples/c14n/extra_whitespace-04.nt | 1 + .../c14n/langtagged_string-c14n.nt | 1 + .../rdf-n-triples/c14n/langtagged_string.nt | 1 + .../c14n/literal_all_controls-c14n.nt | 1 + .../c14n/literal_all_controls.nt | 1 + .../c14n/literal_all_punctuation-c14n.nt | 1 + .../c14n/literal_all_punctuation.nt | 1 + .../c14n/literal_ascii_boundaries-c14n.nt | 1 + .../c14n/literal_ascii_boundaries.nt | Bin 0 -> 57 bytes .../literal_needing_uchar_escaping-01-c14n.nt | 1 + .../c14n/literal_needing_uchar_escaping-01.nt | Bin 0 -> 81 bytes .../c14n/literal_needing_uchar_escaping-02.nt | 2 + .../c14n/literal_with_2_dquotes-c14n.nt | 1 + .../c14n/literal_with_2_dquotes.nt | 1 + .../c14n/literal_with_2_squotes-c14n.nt | 1 + .../c14n/literal_with_2_squotes.nt | 1 + .../c14n/literal_with_BACKSPACE-c14n.nt | 1 + .../c14n/literal_with_BACKSPACE.nt | 1 + .../c14n/literal_with_CARRIAGE_RETURN-c14n.nt | 1 + .../c14n/literal_with_CARRIAGE_RETURN.nt | 1 + .../literal_with_CHARACTER_TABULATION-c14n.nt | 1 + .../c14n/literal_with_CHARACTER_TABULATION.nt | 1 + .../c14n/literal_with_FORM_FEED-c14n.nt | 1 + .../c14n/literal_with_FORM_FEED.nt | 1 + .../c14n/literal_with_LINE_FEED-c14n.nt | 1 + .../c14n/literal_with_LINE_FEED.nt | 1 + .../c14n/literal_with_REVERSE_SOLIDUS-c14n.nt | 1 + .../c14n/literal_with_REVERSE_SOLIDUS.nt | 1 + .../literal_with_REVERSE_SOLIDUS2-c14n.nt | 1 + .../c14n/literal_with_REVERSE_SOLIDUS2.nt | 1 + .../c14n/literal_with_UTF8_boundaries-c14n.nt | 1 + .../c14n/literal_with_UTF8_boundaries.nt | 1 + .../c14n/literal_with_dquote-c14n.nt | 1 + .../rdf-n-triples/c14n/literal_with_dquote.nt | 1 + .../literal_with_extra_whitespace-c14n.nt | 1 + .../c14n/literal_with_extra_whitespace.nt | 1 + .../c14n/literal_with_numeric_escape4-c14n.nt | 2 + .../c14n/literal_with_numeric_escape4.nt | 2 + .../c14n/literal_with_numeric_escape8-c14n.nt | 2 + .../c14n/literal_with_numeric_escape8.nt | 2 + .../c14n/literal_with_squote-c14n.nt | 1 + .../rdf-n-triples/c14n/literal_with_squote.nt | 1 + .../c14n/literal_with_string_dt-c14n.nt | 1 + .../c14n/literal_with_string_dt.nt | 1 + .../w3c/rdf12/rdf-n-triples/c14n/manifest.ttl | 395 +++++++++++++ .../c14n/minimal_whitespace-01-c14n.nt | 1 + .../c14n/minimal_whitespace-01.nt | 1 + .../c14n/minimal_whitespace-02-c14n.nt | 1 + .../c14n/minimal_whitespace-02.nt | 1 + .../c14n/nt-syntax-str-esc-01-c14n.nt | 1 + .../c14n/nt-syntax-str-esc-01.nt | 1 + .../c14n/nt-syntax-str-esc-02-c14n.nt | 1 + .../c14n/nt-syntax-str-esc-02.nt | 1 + .../c14n/nt-syntax-str-esc-03-c14n.nt | 1 + .../c14n/nt-syntax-str-esc-03.nt | 1 + .../c14n/nt-syntax-uri-01-c14n.nt | 1 + .../rdf-n-triples/c14n/nt-syntax-uri-01.nt | 1 + .../c14n/nt-syntax-uri-02-c14n.nt | 1 + .../rdf-n-triples/c14n/nt-syntax-uri-02.nt | 2 + .../c14n/nt-syntax-uri-03-c14n.nt | 1 + .../rdf-n-triples/c14n/nt-syntax-uri-03.nt | 2 + .../c14n/nt-syntax-uri-04-c14n.nt | 1 + .../rdf-n-triples/c14n/nt-syntax-uri-04.nt | 2 + .../rdf-n-triples/c14n/triple-term-01-c14n.nt | 1 + .../rdf-n-triples/c14n/triple-term-01.nt | 1 + .../rdf-n-triples/c14n/triple-term-02-c14n.nt | 1 + .../rdf-n-triples/c14n/triple-term-02.nt | 1 + .../rdf-n-triples/c14n/triple-term-03-c14n.nt | 1 + .../rdf-n-triples/c14n/triple-term-03.nt | 1 + .../rdf-n-triples/c14n/triple-term-04-c14n.nt | 1 + .../rdf-n-triples/c14n/triple-term-04.nt | 1 + .../w3c/rdf12/rdf-n-triples/manifest.ttl | 36 ++ .../rdf12/rdf-n-triples/syntax/manifest.ttl | 220 ++++++++ .../syntax/ntriples-langdir-1.nt | 1 + .../syntax/ntriples-langdir-2.nt | 1 + .../syntax/ntriples-langdir-bad-1.nt | 1 + .../syntax/ntriples-langdir-bad-2.nt | 1 + .../syntax/ntriples-langdir-bad-3.nt | 1 + .../syntax/ntriples-langdir-bad-4.nt | 1 + .../syntax/ntriples-langdir-bad-5.nt | 1 + .../syntax/ntriples12-bad-iri-1.nt | 1 + .../syntax/ntriples12-bad-reified-syntax-1.nt | 1 + .../syntax/ntriples12-bad-reified-syntax-2.nt | 1 + .../syntax/ntriples12-bad-reified-syntax-3.nt | 1 + .../syntax/ntriples12-bad-reified-syntax-4.nt | 1 + .../syntax/ntriples12-bad-syntax-01.nt | 1 + .../syntax/ntriples12-bad-syntax-02.nt | 1 + .../syntax/ntriples12-bad-syntax-03.nt | 1 + .../syntax/ntriples12-bad-syntax-04.nt | 1 + .../syntax/ntriples12-bad-syntax-05.nt | 1 + .../syntax/ntriples12-bad-syntax-06.nt | 1 + .../syntax/ntriples12-bad-syntax-07.nt | 1 + .../syntax/ntriples12-bad-syntax-08.nt | 1 + .../syntax/ntriples12-bad-syntax-09.nt | 1 + .../syntax/ntriples12-bad-syntax-10.nt | 1 + .../syntax/ntriples12-bnode-1.nt | 2 + ...ntriples12-bnode-bad-annotated-syntax-1.nt | 1 + ...ntriples12-bnode-bad-annotated-syntax-2.nt | 1 + .../syntax/ntriples12-nested-1.nt | 3 + .../syntax/ntriples12-syntax-01.nt | 1 + .../syntax/ntriples12-syntax-02.nt | 1 + .../syntax/ntriples12-syntax-03.nt | 1 + .../resources/w3c/rdf12/rdf-trig/README.md | 22 + .../w3c/rdf12/rdf-trig/eval/manifest.ttl | 204 +++++++ .../eval/trig12-eval-annotation-01.nq | 3 + .../eval/trig12-eval-annotation-01.trig | 3 + .../eval/trig12-eval-annotation-02.nq | 8 + .../eval/trig12-eval-annotation-02.trig | 12 + .../eval/trig12-eval-annotation-03.nq | 9 + .../eval/trig12-eval-annotation-03.trig | 7 + .../eval/trig12-eval-annotation-04.nq | 5 + .../eval/trig12-eval-annotation-04.trig | 3 + .../eval/trig12-eval-annotation-05.nq | 4 + .../eval/trig12-eval-annotation-05.trig | 4 + .../eval/trig12-eval-annotation-06.nq | 3 + .../eval/trig12-eval-annotation-06.trig | 3 + .../eval/trig12-eval-annotation-07.nq | 5 + .../eval/trig12-eval-annotation-07.trig | 6 + .../eval/trig12-eval-annotation-08.nq | 3 + .../eval/trig12-eval-annotation-08.trig | 3 + .../eval/trig12-eval-annotation-09.nq | 4 + .../eval/trig12-eval-annotation-09.trig | 3 + .../eval/trig12-eval-annotation-10.nq | 5 + .../eval/trig12-eval-annotation-10.trig | 3 + .../eval/trig12-eval-annotation-11.nq | 4 + .../eval/trig12-eval-annotation-11.trig | 3 + .../eval/trig12-eval-annotation-12.nq | 5 + .../eval/trig12-eval-annotation-12.trig | 3 + .../rdf-trig/eval/trig12-eval-bnode-1.nq | 3 + .../rdf-trig/eval/trig12-eval-bnode-1.trig | 6 + .../rdf-trig/eval/trig12-eval-bnode-2.nq | 4 + .../rdf-trig/eval/trig12-eval-bnode-2.trig | 6 + ...ig12-eval-reified-triples-annotation-01.nq | 4 + ...12-eval-reified-triples-annotation-01.trig | 3 + ...ig12-eval-reified-triples-annotation-02.nq | 4 + ...12-eval-reified-triples-annotation-02.trig | 3 + ...ig12-eval-reified-triples-annotation-03.nq | 4 + ...12-eval-reified-triples-annotation-03.trig | 3 + .../rdf12/rdf-trig/eval/trig12-eval-rt-01.nq | 2 + .../rdf-trig/eval/trig12-eval-rt-01.trig | 3 + .../rdf12/rdf-trig/eval/trig12-eval-rt-02.nq | 2 + .../rdf-trig/eval/trig12-eval-rt-02.trig | 3 + .../rdf12/rdf-trig/eval/trig12-eval-rt-03.nq | 2 + .../rdf-trig/eval/trig12-eval-rt-03.trig | 3 + .../rdf12/rdf-trig/eval/trig12-eval-rt-04.nq | 2 + .../rdf-trig/eval/trig12-eval-rt-04.trig | 3 + .../rdf12/rdf-trig/eval/trig12-eval-rt-05.nq | 2 + .../rdf-trig/eval/trig12-eval-rt-05.trig | 3 + .../rdf12/rdf-trig/eval/trig12-eval-rt-06.nq | 2 + .../rdf-trig/eval/trig12-eval-rt-06.trig | 3 + .../rdf12/rdf-trig/eval/trig12-eval-rt-07.nq | 2 + .../rdf-trig/eval/trig12-eval-rt-07.trig | 3 + .../rdf12/rdf-trig/eval/trig12-eval-rt-08.nq | 2 + .../rdf-trig/eval/trig12-eval-rt-08.trig | 3 + .../resources/w3c/rdf12/rdf-trig/manifest.ttl | 36 ++ .../w3c/rdf12/rdf-trig/syntax/manifest.ttl | 259 +++++++++ .../rdf-trig/syntax/trig12-annotation-1.trig | 3 + .../rdf-trig/syntax/trig12-annotation-2.trig | 12 + .../rdf-trig/syntax/trig12-annotation-3.trig | 3 + .../rdf-trig/syntax/trig12-annotation-4.trig | 3 + .../rdf-trig/syntax/trig12-annotation-5.trig | 3 + .../rdf-trig/syntax/trig12-annotation-6.trig | 3 + .../rdf-trig/syntax/trig12-annotation-7.trig | 3 + .../rdf-trig/syntax/trig12-annotation-8.trig | 3 + .../rdf12/rdf-trig/syntax/trig12-base-1.trig | 3 + .../rdf12/rdf-trig/syntax/trig12-base-2.trig | 3 + .../rdf-trig/syntax/trig12-base-bad-1.trig | 3 + .../rdf-trig/syntax/trig12-base-bad-2.trig | 3 + .../rdf-trig/syntax/trig12-syntax-bad-01.trig | 6 + .../rdf-trig/syntax/trig12-syntax-bad-02.trig | 6 + .../rdf-trig/syntax/trig12-syntax-bad-03.trig | 5 + .../rdf-trig/syntax/trig12-syntax-bad-04.trig | 5 + .../rdf-trig/syntax/trig12-syntax-bad-05.trig | 5 + .../rdf-trig/syntax/trig12-syntax-bad-06.trig | 6 + .../rdf-trig/syntax/trig12-syntax-bad-07.trig | 3 + .../rdf-trig/syntax/trig12-syntax-bad-08.trig | 3 + .../syntax/trig12-syntax-bad-ann-1.trig | 4 + .../syntax/trig12-syntax-bad-ann-2.trig | 3 + .../syntax/trig12-syntax-basic-01.trig | 6 + .../syntax/trig12-syntax-basic-02.trig | 6 + .../syntax/trig12-syntax-basic-03.trig | 3 + .../syntax/trig12-syntax-basic-04.trig | 6 + .../syntax/trig12-syntax-bnode-01.trig | 6 + .../syntax/trig12-syntax-bnode-02.trig | 6 + .../syntax/trig12-syntax-bnode-03.trig | 3 + .../syntax/trig12-syntax-compound.trig | 12 + .../syntax/trig12-syntax-inside-01.trig | 6 + .../syntax/trig12-syntax-inside-02.trig | 7 + .../syntax/trig12-syntax-inside-03.trig | 4 + .../syntax/trig12-syntax-inside-04.trig | 4 + .../syntax/trig12-syntax-nested-01.trig | 9 + .../syntax/trig12-syntax-nested-02.trig | 7 + .../resources/w3c/rdf12/rdf-turtle/README.md | 22 + .../w3c/rdf12/rdf-turtle/eval/manifest.ttl | 232 ++++++++ .../eval/turtle12-eval-annotation-01.nt | 3 + .../eval/turtle12-eval-annotation-01.ttl | 3 + .../eval/turtle12-eval-annotation-02.nt | 8 + .../eval/turtle12-eval-annotation-02.ttl | 10 + .../eval/turtle12-eval-annotation-03.nt | 9 + .../eval/turtle12-eval-annotation-03.ttl | 5 + .../eval/turtle12-eval-annotation-04.nt | 5 + .../eval/turtle12-eval-annotation-04.ttl | 3 + .../eval/turtle12-eval-annotation-05.nt | 4 + .../eval/turtle12-eval-annotation-05.ttl | 4 + .../eval/turtle12-eval-annotation-06.nt | 3 + .../eval/turtle12-eval-annotation-06.ttl | 3 + .../eval/turtle12-eval-annotation-07.nt | 5 + .../eval/turtle12-eval-annotation-07.ttl | 4 + .../eval/turtle12-eval-annotation-08.nt | 3 + .../eval/turtle12-eval-annotation-08.ttl | 3 + .../eval/turtle12-eval-annotation-09.nt | 4 + .../eval/turtle12-eval-annotation-09.ttl | 3 + .../eval/turtle12-eval-annotation-10.nt | 5 + .../eval/turtle12-eval-annotation-10.ttl | 3 + .../eval/turtle12-eval-annotation-11.nt | 4 + .../eval/turtle12-eval-annotation-11.ttl | 3 + .../eval/turtle12-eval-annotation-12.nt | 5 + .../eval/turtle12-eval-annotation-12.ttl | 3 + .../rdf-turtle/eval/turtle12-eval-bnode-01.nt | 3 + .../eval/turtle12-eval-bnode-01.ttl | 4 + .../rdf-turtle/eval/turtle12-eval-bnode-02.nt | 4 + .../eval/turtle12-eval-bnode-02.ttl | 4 + ...le12-eval-reified-triples-annotation-01.nt | 4 + ...e12-eval-reified-triples-annotation-01.ttl | 3 + ...le12-eval-reified-triples-annotation-02.nt | 4 + ...e12-eval-reified-triples-annotation-02.ttl | 3 + ...le12-eval-reified-triples-annotation-03.nt | 4 + ...e12-eval-reified-triples-annotation-03.ttl | 3 + .../rdf-turtle/eval/turtle12-eval-rt-01.nt | 2 + .../rdf-turtle/eval/turtle12-eval-rt-01.ttl | 3 + .../rdf-turtle/eval/turtle12-eval-rt-02.nt | 2 + .../rdf-turtle/eval/turtle12-eval-rt-02.ttl | 3 + .../rdf-turtle/eval/turtle12-eval-rt-03.nt | 2 + .../rdf-turtle/eval/turtle12-eval-rt-03.ttl | 3 + .../rdf-turtle/eval/turtle12-eval-rt-04.nt | 2 + .../rdf-turtle/eval/turtle12-eval-rt-04.ttl | 3 + .../rdf-turtle/eval/turtle12-eval-rt-05.nt | 2 + .../rdf-turtle/eval/turtle12-eval-rt-05.ttl | 3 + .../rdf-turtle/eval/turtle12-eval-rt-06.nt | 2 + .../rdf-turtle/eval/turtle12-eval-rt-06.ttl | 3 + .../rdf-turtle/eval/turtle12-eval-rt-07.nt | 2 + .../rdf-turtle/eval/turtle12-eval-rt-07.ttl | 3 + .../rdf-turtle/eval/turtle12-eval-rt-08.nt | 2 + .../rdf-turtle/eval/turtle12-eval-rt-08.ttl | 3 + .../rdf-turtle/eval/turtle12-eval-tt-01.nt | 1 + .../rdf-turtle/eval/turtle12-eval-tt-01.ttl | 4 + .../rdf-turtle/eval/turtle12-eval-tt-02.nt | 1 + .../rdf-turtle/eval/turtle12-eval-tt-02.ttl | 4 + .../rdf-turtle/eval/turtle12-eval-tt-03.nt | 1 + .../rdf-turtle/eval/turtle12-eval-tt-03.ttl | 4 + .../rdf-turtle/eval/turtle12-eval-tt-04.nt | 3 + .../rdf-turtle/eval/turtle12-eval-tt-04.ttl | 6 + .../w3c/rdf12/rdf-turtle/manifest.ttl | 36 ++ .../w3c/rdf12/rdf-turtle/syntax/manifest.ttl | 518 ++++++++++++++++++ .../rdf-turtle/syntax/nt-ttl12-bad-10.ttl | 1 + .../syntax/nt-ttl12-bad-syntax-01.ttl | 1 + .../syntax/nt-ttl12-bad-syntax-02.ttl | 1 + .../syntax/nt-ttl12-bad-syntax-03.ttl | 1 + .../syntax/nt-ttl12-bad-syntax-04.ttl | 1 + .../syntax/nt-ttl12-bad-syntax-05.ttl | 1 + .../syntax/nt-ttl12-bad-syntax-06.ttl | 1 + .../syntax/nt-ttl12-bad-syntax-07.ttl | 1 + .../syntax/nt-ttl12-bad-syntax-08.ttl | 1 + .../syntax/nt-ttl12-bad-syntax-09.ttl | 1 + .../rdf-turtle/syntax/nt-ttl12-bnode-1.ttl | 2 + .../rdf-turtle/syntax/nt-ttl12-langdir-1.ttl | 1 + .../rdf-turtle/syntax/nt-ttl12-langdir-2.ttl | 1 + .../syntax/nt-ttl12-langdir-bad-1.ttl | 1 + .../syntax/nt-ttl12-langdir-bad-2.ttl | 1 + .../rdf-turtle/syntax/nt-ttl12-nested-1.ttl | 3 + .../rdf-turtle/syntax/nt-ttl12-syntax-1.ttl | 1 + .../rdf-turtle/syntax/nt-ttl12-syntax-2.ttl | 1 + .../rdf-turtle/syntax/nt-ttl12-syntax-3.ttl | 1 + .../syntax/turtle12-annotation-1.ttl | 3 + .../syntax/turtle12-annotation-2.ttl | 10 + .../syntax/turtle12-annotation-3.ttl | 3 + .../syntax/turtle12-annotation-4.ttl | 3 + .../syntax/turtle12-annotation-5.ttl | 3 + .../syntax/turtle12-annotation-6.ttl | 3 + .../syntax/turtle12-annotation-7.ttl | 3 + .../syntax/turtle12-annotation-8.ttl | 3 + .../syntax/turtle12-surrogate-pair-bad-01.ttl | 2 + .../syntax/turtle12-surrogate-pair-bad-02.ttl | 2 + .../syntax/turtle12-surrogates-bad-01.ttl | 3 + .../syntax/turtle12-surrogates-bad-02.ttl | 3 + .../syntax/turtle12-surrogates-bad-03.ttl | 3 + .../syntax/turtle12-surrogates-bad-04.ttl | 2 + .../syntax/turtle12-surrogates-bad-05.ttl | 2 + .../syntax/turtle12-syntax-bad-01.ttl | 4 + .../syntax/turtle12-syntax-bad-02.ttl | 4 + .../syntax/turtle12-syntax-bad-03.ttl | 3 + .../syntax/turtle12-syntax-bad-04.ttl | 3 + .../syntax/turtle12-syntax-bad-05.ttl | 3 + .../syntax/turtle12-syntax-bad-06.ttl | 4 + .../syntax/turtle12-syntax-bad-07.ttl | 3 + .../syntax/turtle12-syntax-bad-ann-1.ttl | 6 + .../syntax/turtle12-syntax-bad-ann-2.ttl | 3 + .../syntax/turtle12-syntax-basic-01.ttl | 4 + .../syntax/turtle12-syntax-basic-02.ttl | 4 + .../syntax/turtle12-syntax-basic-03.ttl | 3 + .../syntax/turtle12-syntax-basic-04.ttl | 4 + .../syntax/turtle12-syntax-basic-05.ttl | 4 + .../syntax/turtle12-syntax-basic-06.ttl | 4 + .../syntax/turtle12-syntax-basic-07.ttl | 3 + .../syntax/turtle12-syntax-basic-08.ttl | 4 + .../syntax/turtle12-syntax-bnode-01.ttl | 4 + .../syntax/turtle12-syntax-bnode-02.ttl | 4 + .../syntax/turtle12-syntax-bnode-03.ttl | 3 + .../syntax/turtle12-syntax-compound.ttl | 11 + .../syntax/turtle12-syntax-inside-01.ttl | 4 + .../syntax/turtle12-syntax-inside-02.ttl | 5 + .../syntax/turtle12-syntax-inside-03.ttl | 4 + .../syntax/turtle12-syntax-inside-04.ttl | 4 + .../syntax/turtle12-syntax-nested-01.ttl | 7 + .../syntax/turtle12-syntax-nested-02.ttl | 5 + .../rdf-turtle/syntax/turtle12-version-01.ttl | 4 + .../rdf-turtle/syntax/turtle12-version-02.ttl | 4 + .../rdf-turtle/syntax/turtle12-version-03.ttl | 6 + .../rdf-turtle/syntax/turtle12-version-04.ttl | 7 + .../rdf-turtle/syntax/turtle12-version-05.ttl | 4 + .../rdf-turtle/syntax/turtle12-version-06.ttl | 4 + .../rdf-turtle/syntax/turtle12-version-07.ttl | 5 + .../rdf-turtle/syntax/turtle12-version-08.ttl | 19 + .../syntax/turtle12-version-bad-01.ttl | 1 + .../syntax/turtle12-version-bad-02.ttl | 1 + .../syntax/turtle12-version-bad-03.ttl | 1 + .../syntax/turtle12-version-bad-04.ttl | 1 + .../syntax/turtle12-version-bad-05.ttl | 1 + .../syntax/turtle12-version-bad-06.ttl | 1 + 461 files changed, 4438 insertions(+), 2 deletions(-) create mode 100644 src/test/java/com/ebremer/beakgraph/TermFidelityTest.java create mode 100644 src/test/java/com/ebremer/beakgraph/WriterEngines.java create mode 100644 src/test/java/com/ebremer/beakgraph/core/lib/NodeComparatorDirLangTest.java create mode 100644 src/test/java/com/ebremer/beakgraph/w3c/W3CRdf12SuiteTest.java create mode 100644 src/test/resources/w3c/rdf12/LICENSE.md create mode 100644 src/test/resources/w3c/rdf12/README.md create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/README.md create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/comment_following_triple-c14n.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/comment_following_triple.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/dirlangtagged_string-c14n.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/dirlangtagged_string.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/extra_whitespace-01-c14n.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/extra_whitespace-01.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/extra_whitespace-02-c14n.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/extra_whitespace-02.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/extra_whitespace-03-c14n.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/extra_whitespace-03.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/extra_whitespace-04-c14n.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/extra_whitespace-04.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/langtagged_string-c14n.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/langtagged_string.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_all_controls-c14n.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_all_controls.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_all_punctuation-c14n.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_all_punctuation.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_ascii_boundaries-c14n.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_ascii_boundaries.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_needing_uchar_escaping-01-c14n.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_needing_uchar_escaping-01.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_needing_uchar_escaping-02.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_2_dquotes-c14n.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_2_dquotes.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_2_squotes-c14n.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_2_squotes.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_BACKSPACE-c14n.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_BACKSPACE.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_CARRIAGE_RETURN-c14n.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_CARRIAGE_RETURN.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_CHARACTER_TABULATION-c14n.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_CHARACTER_TABULATION.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_FORM_FEED-c14n.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_FORM_FEED.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_LINE_FEED-c14n.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_LINE_FEED.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_REVERSE_SOLIDUS-c14n.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_REVERSE_SOLIDUS.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_REVERSE_SOLIDUS2-c14n.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_REVERSE_SOLIDUS2.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_UTF8_boundaries-c14n.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_UTF8_boundaries.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_dquote-c14n.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_dquote.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_extra_whitespace-c14n.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_extra_whitespace.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_numeric_escape4-c14n.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_numeric_escape4.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_numeric_escape8-c14n.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_numeric_escape8.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_squote-c14n.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_squote.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_string_dt-c14n.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_string_dt.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/manifest.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/minimal_whitespace-01-c14n.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/minimal_whitespace-01.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/minimal_whitespace-02-c14n.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/minimal_whitespace-02.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/nq-syntax-str-esc-01-c14n.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/nq-syntax-str-esc-01.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/nq-syntax-str-esc-02-c14n.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/nq-syntax-str-esc-02.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/nq-syntax-str-esc-03-c14n.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/nq-syntax-str-esc-03.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/nq-syntax-uri-01-c14n.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/nq-syntax-uri-01.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/nq-syntax-uri-02-c14n.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/nq-syntax-uri-02.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/nq-syntax-uri-03-c14n.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/nq-syntax-uri-03.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/nq-syntax-uri-04-c14n.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/nq-syntax-uri-04.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/triple-term-01-c14n.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/triple-term-01.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/triple-term-02-c14n.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/triple-term-02.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/triple-term-03-c14n.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/triple-term-03.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/triple-term-04-c14n.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/c14n/triple-term-04.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/manifest.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/syntax/manifest.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads-langdir-1.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads-langdir-2.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads-langdir-bad-1.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads-langdir-bad-2.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-bad-reified-syntax-1.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-bad-reified-syntax-2.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-bad-reified-syntax-3.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-bad-reified-syntax-4.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-bad-syntax-01.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-bad-syntax-02.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-bad-syntax-03.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-bad-syntax-04.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-bad-syntax-05.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-bad-syntax-06.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-bad-syntax-07.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-bad-syntax-08.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-bad-syntax-09.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-bad-syntax-10.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-bnode-1.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-bnode-bad-annotated-syntax-1.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-bnode-bad-annotated-syntax-2.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-nested-1.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-nested-bad-annotated-syntax-1.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-nested-bad-annotated-syntax-2.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-syntax-01.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-syntax-02.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-syntax-03.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/README.md create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/comment_following_triple-c14n.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/comment_following_triple.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/dirlangtagged_string-c14n.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/dirlangtagged_string.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/extra_whitespace-01-c14n.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/extra_whitespace-01.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/extra_whitespace-02-c14n.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/extra_whitespace-02.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/extra_whitespace-03-c14n.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/extra_whitespace-03.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/extra_whitespace-04-c14n.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/extra_whitespace-04.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/langtagged_string-c14n.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/langtagged_string.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_all_controls-c14n.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_all_controls.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_all_punctuation-c14n.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_all_punctuation.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_ascii_boundaries-c14n.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_ascii_boundaries.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_needing_uchar_escaping-01-c14n.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_needing_uchar_escaping-01.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_needing_uchar_escaping-02.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_2_dquotes-c14n.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_2_dquotes.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_2_squotes-c14n.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_2_squotes.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_BACKSPACE-c14n.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_BACKSPACE.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_CARRIAGE_RETURN-c14n.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_CARRIAGE_RETURN.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_CHARACTER_TABULATION-c14n.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_CHARACTER_TABULATION.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_FORM_FEED-c14n.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_FORM_FEED.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_LINE_FEED-c14n.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_LINE_FEED.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_REVERSE_SOLIDUS-c14n.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_REVERSE_SOLIDUS.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_REVERSE_SOLIDUS2-c14n.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_REVERSE_SOLIDUS2.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_UTF8_boundaries-c14n.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_UTF8_boundaries.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_dquote-c14n.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_dquote.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_extra_whitespace-c14n.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_extra_whitespace.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_numeric_escape4-c14n.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_numeric_escape4.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_numeric_escape8-c14n.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_numeric_escape8.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_squote-c14n.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_squote.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_string_dt-c14n.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_string_dt.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/manifest.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/minimal_whitespace-01-c14n.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/minimal_whitespace-01.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/minimal_whitespace-02-c14n.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/minimal_whitespace-02.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/nt-syntax-str-esc-01-c14n.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/nt-syntax-str-esc-01.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/nt-syntax-str-esc-02-c14n.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/nt-syntax-str-esc-02.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/nt-syntax-str-esc-03-c14n.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/nt-syntax-str-esc-03.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/nt-syntax-uri-01-c14n.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/nt-syntax-uri-01.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/nt-syntax-uri-02-c14n.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/nt-syntax-uri-02.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/nt-syntax-uri-03-c14n.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/nt-syntax-uri-03.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/nt-syntax-uri-04-c14n.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/nt-syntax-uri-04.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/triple-term-01-c14n.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/triple-term-01.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/triple-term-02-c14n.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/triple-term-02.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/triple-term-03-c14n.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/triple-term-03.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/triple-term-04-c14n.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/c14n/triple-term-04.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/manifest.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/syntax/manifest.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples-langdir-1.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples-langdir-2.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples-langdir-bad-1.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples-langdir-bad-2.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples-langdir-bad-3.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples-langdir-bad-4.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples-langdir-bad-5.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-bad-iri-1.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-bad-reified-syntax-1.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-bad-reified-syntax-2.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-bad-reified-syntax-3.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-bad-reified-syntax-4.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-bad-syntax-01.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-bad-syntax-02.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-bad-syntax-03.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-bad-syntax-04.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-bad-syntax-05.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-bad-syntax-06.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-bad-syntax-07.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-bad-syntax-08.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-bad-syntax-09.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-bad-syntax-10.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-bnode-1.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-bnode-bad-annotated-syntax-1.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-bnode-bad-annotated-syntax-2.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-nested-1.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-syntax-01.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-syntax-02.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-syntax-03.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/README.md create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/eval/manifest.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-01.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-01.trig create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-02.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-02.trig create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-03.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-03.trig create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-04.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-04.trig create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-05.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-05.trig create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-06.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-06.trig create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-07.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-07.trig create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-08.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-08.trig create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-09.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-09.trig create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-10.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-10.trig create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-11.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-11.trig create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-12.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-12.trig create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-bnode-1.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-bnode-1.trig create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-bnode-2.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-bnode-2.trig create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-reified-triples-annotation-01.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-reified-triples-annotation-01.trig create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-reified-triples-annotation-02.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-reified-triples-annotation-02.trig create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-reified-triples-annotation-03.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-reified-triples-annotation-03.trig create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-rt-01.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-rt-01.trig create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-rt-02.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-rt-02.trig create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-rt-03.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-rt-03.trig create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-rt-04.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-rt-04.trig create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-rt-05.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-rt-05.trig create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-rt-06.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-rt-06.trig create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-rt-07.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-rt-07.trig create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-rt-08.nq create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-rt-08.trig create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/manifest.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/syntax/manifest.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-annotation-1.trig create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-annotation-2.trig create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-annotation-3.trig create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-annotation-4.trig create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-annotation-5.trig create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-annotation-6.trig create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-annotation-7.trig create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-annotation-8.trig create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-base-1.trig create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-base-2.trig create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-base-bad-1.trig create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-base-bad-2.trig create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-bad-01.trig create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-bad-02.trig create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-bad-03.trig create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-bad-04.trig create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-bad-05.trig create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-bad-06.trig create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-bad-07.trig create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-bad-08.trig create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-bad-ann-1.trig create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-bad-ann-2.trig create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-basic-01.trig create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-basic-02.trig create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-basic-03.trig create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-basic-04.trig create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-bnode-01.trig create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-bnode-02.trig create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-bnode-03.trig create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-compound.trig create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-inside-01.trig create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-inside-02.trig create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-inside-03.trig create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-inside-04.trig create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-nested-01.trig create mode 100644 src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-nested-02.trig create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/README.md create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/eval/manifest.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-01.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-01.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-02.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-02.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-03.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-03.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-04.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-04.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-05.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-05.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-06.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-06.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-07.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-07.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-08.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-08.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-09.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-09.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-10.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-10.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-11.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-11.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-12.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-12.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-bnode-01.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-bnode-01.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-bnode-02.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-bnode-02.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-reified-triples-annotation-01.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-reified-triples-annotation-01.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-reified-triples-annotation-02.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-reified-triples-annotation-02.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-reified-triples-annotation-03.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-reified-triples-annotation-03.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-rt-01.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-rt-01.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-rt-02.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-rt-02.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-rt-03.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-rt-03.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-rt-04.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-rt-04.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-rt-05.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-rt-05.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-rt-06.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-rt-06.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-rt-07.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-rt-07.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-rt-08.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-rt-08.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-tt-01.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-tt-01.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-tt-02.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-tt-02.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-tt-03.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-tt-03.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-tt-04.nt create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-tt-04.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/manifest.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/syntax/manifest.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/syntax/nt-ttl12-bad-10.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/syntax/nt-ttl12-bad-syntax-01.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/syntax/nt-ttl12-bad-syntax-02.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/syntax/nt-ttl12-bad-syntax-03.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/syntax/nt-ttl12-bad-syntax-04.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/syntax/nt-ttl12-bad-syntax-05.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/syntax/nt-ttl12-bad-syntax-06.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/syntax/nt-ttl12-bad-syntax-07.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/syntax/nt-ttl12-bad-syntax-08.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/syntax/nt-ttl12-bad-syntax-09.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/syntax/nt-ttl12-bnode-1.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/syntax/nt-ttl12-langdir-1.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/syntax/nt-ttl12-langdir-2.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/syntax/nt-ttl12-langdir-bad-1.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/syntax/nt-ttl12-langdir-bad-2.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/syntax/nt-ttl12-nested-1.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/syntax/nt-ttl12-syntax-1.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/syntax/nt-ttl12-syntax-2.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/syntax/nt-ttl12-syntax-3.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-annotation-1.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-annotation-2.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-annotation-3.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-annotation-4.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-annotation-5.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-annotation-6.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-annotation-7.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-annotation-8.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-surrogate-pair-bad-01.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-surrogate-pair-bad-02.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-surrogates-bad-01.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-surrogates-bad-02.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-surrogates-bad-03.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-surrogates-bad-04.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-surrogates-bad-05.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-bad-01.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-bad-02.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-bad-03.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-bad-04.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-bad-05.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-bad-06.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-bad-07.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-bad-ann-1.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-bad-ann-2.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-basic-01.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-basic-02.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-basic-03.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-basic-04.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-basic-05.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-basic-06.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-basic-07.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-basic-08.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-bnode-01.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-bnode-02.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-bnode-03.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-compound.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-inside-01.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-inside-02.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-inside-03.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-inside-04.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-nested-01.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-nested-02.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-version-01.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-version-02.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-version-03.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-version-04.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-version-05.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-version-06.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-version-07.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-version-08.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-version-bad-01.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-version-bad-02.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-version-bad-03.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-version-bad-04.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-version-bad-05.ttl create mode 100644 src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-version-bad-06.ttl diff --git a/src/main/java/com/ebremer/beakgraph/core/lib/NodeComparator.java b/src/main/java/com/ebremer/beakgraph/core/lib/NodeComparator.java index c58302b3..e12b0247 100644 --- a/src/main/java/com/ebremer/beakgraph/core/lib/NodeComparator.java +++ b/src/main/java/com/ebremer/beakgraph/core/lib/NodeComparator.java @@ -7,6 +7,7 @@ import javax.xml.datatype.Duration; import javax.xml.datatype.XMLGregorianCalendar; import org.apache.jena.graph.Node; +import org.apache.jena.graph.TextDirection; import org.apache.jena.sparql.core.Quad; import org.apache.jena.sparql.expr.NodeValue; import org.apache.jena.sparql.util.NodeCmp; @@ -90,6 +91,31 @@ public int compare(Node n1, Node n2) { } return n1.getLiteralLexicalForm().compareTo(n2.getLiteralLexicalForm()); } + + // Language-tagged pairs (rdf:langString / rdf:dirLangString) never go + // through compareAlways either: Jena 6.1.0's base-direction support + // there is incoherent - same-(lex,lang) cross-kind or cross-direction + // pairs THROW, different-language dirLangString pairs answer 0 for + // DISTINCT terms, and mixed-kind pairs flip between lang-first and + // lex-first ordering, which is cyclic against the clean (lang, lex) + // order plain langString pairs get. Compare explicitly on + // (language tag, lexical form, base direction) instead: for two plain + // langString literals that is exactly the (lang, lex) order + // compareAlways already produces - this branch only EXTENDS it to base + // directions - and every language-kinded literal occupies the same + // value-space rank against other spaces (verified), so pairs with only + // one language-kinded side stay on compareAlways safely. + if (hasLanguage(n1) && hasLanguage(n2)) { + int c = n1.getLiteralLanguage().compareTo(n2.getLiteralLanguage()); + if (c != 0) { + return c; + } + c = n1.getLiteralLexicalForm().compareTo(n2.getLiteralLexicalForm()); + if (c != 0) { + return c; + } + return Integer.compare(directionRank(n1), directionRank(n2)); + } try { NodeValue nv1 = nodeValue(n1); NodeValue nv2 = nodeValue(n2); @@ -127,10 +153,10 @@ public int compare(Node n1, Node n2) { // Break the tie on the exact RDF term so distinct terms get distinct, // stable dictionary positions instead of collapsing onto one id (which // would make locate() return the wrong term). - return NodeCmp.compareRDFTerms(n1, n2); + return compareExactLiteralTerms(n1, n2); } catch (Exception e) { // Absolute fallback if Jena fails to parse a highly malformed literal - return NodeCmp.compareRDFTerms(n1, n2); + return compareExactLiteralTerms(n1, n2); } } @@ -138,6 +164,48 @@ public int compare(Node n1, Node n2) { return NodeCmp.compareRDFTerms(n1, n2); } + /** + * Final tie-break on the exact RDF term for the literal path. Delegates to + * Jena's {@code NodeCmp}, then repairs one Jena 6.1.0 gap: {@code + * compareRDFTerms} answers 0 for DISTINCT {@code rdf:dirLangString} + * literals - {@code Util.isLangString} is false when a base direction is + * present, so the comparison falls through to lexical form + datatype URI + * and ignores both the language tag and the direction. A comparator + * answering "equal" for non-equal terms collapses them onto one dictionary + * id (ids ARE comparator ranks), so the remaining tie is broken on + * (language tag, base direction). The refinement only splits pairs NodeCmp + * already considers equal, so it cannot disturb the order of any other + * pair. Simplify when NodeCmp orders dirLangString correctly upstream - + * NodeComparatorDirLangTest#jenaNodeCmpGapStillPresent is the canary. + */ + private static int compareExactLiteralTerms(Node n1, Node n2) { + int c = NodeCmp.compareRDFTerms(n1, n2); + if (c != 0 || n1.equals(n2)) { + return c; + } + String lang1 = n1.getLiteralLanguage(); + String lang2 = n2.getLiteralLanguage(); + c = ((lang1 == null) ? "" : lang1).compareTo((lang2 == null) ? "" : lang2); + if (c != 0) { + return c; + } + return Integer.compare(directionRank(n1), directionRank(n2)); + } + + /** absent < ltr < rtl - any fixed order works; it only needs to be total and stable. */ + private static int directionRank(Node n) { + TextDirection d = n.getLiteralBaseDirection(); + if (d == null) { + return 0; + } + return (d == TextDirection.LTR) ? 1 : 2; + } + + private static boolean hasLanguage(Node n) { + String lang = n.getLiteralLanguage(); + return lang != null && !lang.isEmpty(); + } + private static final int GROUP_DURATION = 9; /** diff --git a/src/test/java/com/ebremer/beakgraph/TermFidelityTest.java b/src/test/java/com/ebremer/beakgraph/TermFidelityTest.java new file mode 100644 index 00000000..cbf202e3 --- /dev/null +++ b/src/test/java/com/ebremer/beakgraph/TermFidelityTest.java @@ -0,0 +1,161 @@ +package com.ebremer.beakgraph; + +import static org.junit.jupiter.api.Assertions.assertTrue; + +import com.ebremer.beakgraph.core.BeakGraph; +import java.io.File; +import java.nio.file.Files; +import java.nio.file.Path; +import java.util.Iterator; +import java.util.TreeSet; +import java.util.stream.Stream; +import org.apache.jena.graph.Node; +import org.apache.jena.riot.Lang; +import org.apache.jena.riot.RDFParser; +import org.apache.jena.sparql.core.DatasetGraph; +import org.apache.jena.sparql.core.DatasetGraphFactory; +import org.apache.jena.sparql.core.Quad; +import org.apache.jena.sparql.util.IsoMatcher; +import org.junit.jupiter.api.io.TempDir; +import org.junit.jupiter.params.ParameterizedTest; +import org.junit.jupiter.params.provider.MethodSource; + +/** + * Term-fidelity harness (PLAN Phase 1.4): parse -> write -> read -> assert + * DATASET ISOMORPHISM against the source, for every writer engine. Isomorphism + * is the RDF-correct form of "term set equality": it catches a store that + * silently rewrites terms (the dirLangString corruption built "successfully" + * with the right triple COUNT and the wrong terms) while still allowing the + * blank-node relabeling BeakGraph's rank-derived labels legitimately perform. + * + *

The fixture deliberately covers every term shape the format stores: + * IRIs, blank nodes (shared across graphs - label bijection must be + * dataset-wide), plain / lang-tagged / typed literals, every by-value numeric + * datatype (canonical spellings only - non-canonical spellings are a + * documented deviation), the term-exact strings path (unbounded integers, + * decimals, dates, booleans), value-equal-but-term-distinct pairs, unicode + * with surrogate pairs, a string past the zstd compression threshold, and + * composite (cdt:) literals. Named graphs use IRI and blank-node names. + * + *

Phases 2 and 3 extend THIS fixture (base-direction literals, + * triple terms) - one place, six engines covered, instead of touching five + * parity tests. + */ +class TermFidelityTest { + + private static final String FIXTURE = """ + @prefix : . + @prefix xsd: . + @prefix cdt: . + + :s :p :o . + :s :p _:shared . + _:shared :label "shared bnode" . + :s :str "" . + :s :str "plain string" . + :s :long "this string is deliberately longer than the sixty-four byte zstd compression threshold used by the FCD writer" . + :s :uni "caf\\u00E9 \\u00FCn\\u00EFcode \\U0001F426" . + :s :lang "hello"@en . + :s :lang "hello"@en-GB . + :s :lang "bonjour"@fr . + :s :int "42"^^xsd:int . + :s :int "-7"^^xsd:int . + :s :long2 "123456789012"^^xsd:long . + :s :float "2.5"^^xsd:float . + :s :double "-3.25"^^xsd:double . + :s :integer "123456789012345678901234567890"^^xsd:integer . + :s :decimal "3.14"^^xsd:decimal . + :s :bool "true"^^xsd:boolean . + :s :date "2026-07-16"^^xsd:date . + :s :dt "2026-07-16T12:00:00Z"^^xsd:dateTime . + :s :dt "2026-07-16T12:00:00"^^xsd:dateTime . + :s :vi "1"^^xsd:int . + :s :vi "1"^^xsd:integer . + :s :list "[1, 2, 3]"^^cdt:List . + :s :list "[9]"^^cdt:List . + :s :list "[10]"^^cdt:List . + :s :map "{\\"k\\": 5}"^^cdt:Map . + + :g1 { + :a :b :c . + _:shared :in "g1" . + :a :val "1"^^xsd:int . + } + + _:gname { + :x :y "graph named by a blank node" . + } + """; + + @TempDir + static Path dir; + + static Stream engines() { + return WriterEngines.all(); + } + + @ParameterizedTest(name = "{0}") + @MethodSource("engines") + void datasetSurvivesRoundTripIsomorphically(WriterEngines.Engine engine) throws Exception { + engine.assumeAvailable(); + Path src = dir.resolve(engine.name() + ".trig"); + Files.writeString(src, FIXTURE); + File dest = dir.resolve(engine.name() + ".h5").toFile(); + engine.buildStore(src.toFile(), dest); + + DatasetGraph expected = normalize(parseFixture()); + try (BeakGraph bg = BG.getBeakGraph(dest)) { + DatasetGraph actual = normalize(bg.getDataset().asDatasetGraph()); + assertTrue(IsoMatcher.isomorphic(expected, actual), + () -> "round-trip is not isomorphic to the source\n" + diff(expected, actual)); + } + } + + private static DatasetGraph parseFixture() { + DatasetGraph dsg = DatasetGraphFactory.create(); + RDFParser.create().fromString(FIXTURE).lang(Lang.TRIG).parse(dsg); + return dsg; + } + + /** + * Copy with two normalizations so both sides are compared fairly: BeakGraph's + * derived metadata graphs (urn:x-beakgraph:*) are excluded, and both default + * graph sentinels map onto Quad.defaultGraphIRI. + */ + private static DatasetGraph normalize(DatasetGraph in) { + DatasetGraph out = DatasetGraphFactory.create(); + Iterator it = in.find(Node.ANY, Node.ANY, Node.ANY, Node.ANY); + while (it.hasNext()) { + Quad q = it.next(); + Node g = q.getGraph(); + if (g != null && g.isURI() && g.getURI().startsWith("urn:x-beakgraph:")) { + continue; + } + out.add(new Quad(q.isDefaultGraph() ? Quad.defaultGraphIRI : g, + q.getSubject(), q.getPredicate(), q.getObject())); + } + return out; + } + + private static String diff(DatasetGraph expected, DatasetGraph actual) { + TreeSet exp = quadStrings(expected); + TreeSet act = quadStrings(actual); + StringBuilder sb = new StringBuilder(); + sb.append("expected ").append(exp.size()).append(" quads, actual ").append(act.size()).append('\n'); + exp.stream().filter(s -> !act.contains(s)).limit(12) + .forEach(s -> sb.append(" only in source: ").append(s).append('\n')); + act.stream().filter(s -> !exp.contains(s)).limit(12) + .forEach(s -> sb.append(" only in store : ").append(s).append('\n')); + sb.append("(blank-node label differences are expected; term differences are the bug)"); + return sb.toString(); + } + + private static TreeSet quadStrings(DatasetGraph dsg) { + TreeSet out = new TreeSet<>(); + Iterator it = dsg.find(Node.ANY, Node.ANY, Node.ANY, Node.ANY); + while (it.hasNext()) { + out.add(it.next().toString()); + } + return out; + } +} diff --git a/src/test/java/com/ebremer/beakgraph/WriterEngines.java b/src/test/java/com/ebremer/beakgraph/WriterEngines.java new file mode 100644 index 00000000..71cf4c25 --- /dev/null +++ b/src/test/java/com/ebremer/beakgraph/WriterEngines.java @@ -0,0 +1,80 @@ +package com.ebremer.beakgraph; + +import com.ebremer.beakgraph.core.BeakGraphWriter; +import com.ebremer.beakgraph.hdf5.writers.HDF5Writer; +import com.ebremer.beakgraph.hdf5.writers.hugeUltra.HugeUltraHDF5Writer; +import com.ebremer.beakgraph.hdf5.writers.parallel.ParallelHDF5Writer; +import com.ebremer.beakgraph.hdf5.writers.plaid.PlaidHDF5Writer; +import com.ebremer.beakgraph.hdf5.writers.ultra.UltraHDF5Writer; +import com.ebremer.beakgraph.huge.HugeHDF5Writer; +import com.ebremer.beakgraph.huge.NativeHdf5File; +import java.io.File; +import java.util.stream.Stream; +import org.junit.jupiter.api.Assumptions; + +/** + * Test-support enumeration of all six writer engines, so cross-engine suites + * iterate ONE list instead of mirroring six builder invocations per test class + * (the same mirror-topology hazard the production code has). + */ +public final class WriterEngines { + + private WriterEngines() {} + + @FunctionalInterface + public interface Factory { + BeakGraphWriter create(File src, File dest) throws Exception; + } + + public record Engine(String name, boolean needsNative, Factory factory) { + public void assumeAvailable() { + Assumptions.assumeTrue(!needsNative || NativeHdf5File.isAvailable(), + "native HDF5 library unavailable"); + } + + public void buildStore(File src, File dest) throws Exception { + factory.create(src, dest).write(); + } + + @Override + public String toString() { + return name; + } + } + + public static Stream all() { + return Stream.of( + new Engine("method0-HDF5Writer", false, (src, dest) -> + HDF5Writer.Builder().setSource(src).setDestination(dest).build()), + new Engine("method1-Huge", true, (src, dest) -> { + HugeHDF5Writer.Builder b = HugeHDF5Writer.Builder().setDestination(dest); + b.setSource(src); + return b.build(); + }), + new Engine("method2-Parallel", false, (src, dest) -> { + ParallelHDF5Writer.Builder b = ParallelHDF5Writer.Builder() + .setDestination(dest).setCores(2); + b.setSource(src); + return b.build(); + }), + new Engine("method3-Ultra", false, (src, dest) -> { + UltraHDF5Writer.Builder b = UltraHDF5Writer.Builder() + .setDestination(dest).setCores(2); + b.setSource(src); + return b.build(); + }), + new Engine("method4-HugeUltra", true, (src, dest) -> { + HugeUltraHDF5Writer.Builder b = HugeUltraHDF5Writer.Builder() + .setDestination(dest).setCores(2); + b.setSource(src); + return b.build(); + }), + new Engine("method5-Plaid", true, (src, dest) -> { + PlaidHDF5Writer.Builder b = PlaidHDF5Writer.Builder() + .setDestination(dest).setCores(2); + b.setSource(src); + return b.build(); + }) + ); + } +} diff --git a/src/test/java/com/ebremer/beakgraph/core/lib/NodeComparatorCdtTest.java b/src/test/java/com/ebremer/beakgraph/core/lib/NodeComparatorCdtTest.java index 6fddbc7a..69109aee 100644 --- a/src/test/java/com/ebremer/beakgraph/core/lib/NodeComparatorCdtTest.java +++ b/src/test/java/com/ebremer/beakgraph/core/lib/NodeComparatorCdtTest.java @@ -43,6 +43,13 @@ class NodeComparatorCdtTest { @TempDir static Path dir; + @org.junit.jupiter.api.BeforeAll + static void initJena() { + // Comparator tests touch TypeMapper/NodeValue without building a store + // first; initialize Jena explicitly so class-init order cannot NPE. + org.apache.jena.sys.JenaSystem.init(); + } + private static Node lit(String lex, String dt) { return NodeFactory.createLiteralDT(lex, TypeMapper.getInstance().getSafeTypeByName(dt)); } diff --git a/src/test/java/com/ebremer/beakgraph/core/lib/NodeComparatorDirLangTest.java b/src/test/java/com/ebremer/beakgraph/core/lib/NodeComparatorDirLangTest.java new file mode 100644 index 00000000..ef769591 --- /dev/null +++ b/src/test/java/com/ebremer/beakgraph/core/lib/NodeComparatorDirLangTest.java @@ -0,0 +1,131 @@ +package com.ebremer.beakgraph.core.lib; + +import static org.junit.jupiter.api.Assertions.assertEquals; +import static org.junit.jupiter.api.Assertions.assertTrue; + +import java.util.ArrayList; +import java.util.Collections; +import java.util.List; +import java.util.Random; +import org.apache.jena.graph.Node; +import org.apache.jena.graph.NodeFactory; +import org.apache.jena.sparql.util.NodeCmp; +import org.junit.jupiter.api.Test; + +/** + * Pins {@link NodeComparator}'s dirLangString tie-break (PLAN Phase 1.2), the + * hard prerequisite for storing rdf:dirLangString: Jena 6.1.0's + * {@code NodeCmp.compareRDFTerms} answers 0 for DISTINCT dirLangString + * literals (it ignores both the language tag and the base direction), and + * dictionary ids are comparator ranks - so without the tie-break, distinct + * terms collapse onto one id. + */ +class NodeComparatorDirLangTest { + + @org.junit.jupiter.api.BeforeAll + static void initJena() { + // Comparator tests touch TypeMapper/NodeValue without building a store + // first; initialize Jena explicitly so class-init order cannot NPE. + org.apache.jena.sys.JenaSystem.init(); + } + + private static int sign(Node a, Node b) { + return Integer.signum(NodeComparator.INSTANCE.compare(a, b)); + } + + /** + * The canary: this pins the UPSTREAM Jena bug the tie-break exists to + * repair. When this test fails, Jena has fixed NodeCmp - file nothing, + * celebrate, and consider simplifying + * NodeComparator#compareExactLiteralTerms (its refinement then becomes + * unreachable but stays harmless). + */ + @Test + void jenaNodeCmpGapStillPresent() { + Node ltr = NodeFactory.createLiteralDirLang("abc", "en", "ltr"); + Node rtl = NodeFactory.createLiteralDirLang("abc", "en", "rtl"); + Node fr = NodeFactory.createLiteralDirLang("abc", "fr", "rtl"); + assertEquals(0, NodeCmp.compareRDFTerms(ltr, rtl), + "Jena fixed NodeCmp for base direction - see this test's javadoc"); + assertEquals(0, NodeCmp.compareRDFTerms(ltr, fr), + "Jena fixed NodeCmp for dirLangString language tags - see this test's javadoc"); + } + + @Test + void distinctDirLangTermsGetDistinctRanks() { + Node enLtr = NodeFactory.createLiteralDirLang("abc", "en", "ltr"); + Node enRtl = NodeFactory.createLiteralDirLang("abc", "en", "rtl"); + Node frLtr = NodeFactory.createLiteralDirLang("abc", "fr", "ltr"); + Node frRtl = NodeFactory.createLiteralDirLang("abc", "fr", "rtl"); + + Node[] all = {enLtr, enRtl, frLtr, frRtl}; + for (Node a : all) { + for (Node b : all) { + if (a.equals(b)) { + assertEquals(0, sign(a, b)); + } else { + assertTrue(sign(a, b) != 0, "distinct terms must not tie: " + a + " vs " + b); + assertEquals(-sign(b, a), sign(a, b), "antisymmetry: " + a + " vs " + b); + } + } + } + // The chosen refinement: language tag first, then absent < ltr < rtl. + assertEquals(-1, sign(enLtr, enRtl)); + assertEquals(-1, sign(enRtl, frLtr)); + } + + @Test + void orderingIsATotalOrderAcrossLangKinds() { + List cand = new ArrayList<>(); + for (String lex : new String[]{"abc", "zzz"}) { + cand.add(NodeFactory.createLiteralString(lex)); + cand.add(NodeFactory.createLiteralLang(lex, "en")); + cand.add(NodeFactory.createLiteralLang(lex, "fr")); + cand.add(NodeFactory.createLiteralDirLang(lex, "en", "ltr")); + cand.add(NodeFactory.createLiteralDirLang(lex, "en", "rtl")); + cand.add(NodeFactory.createLiteralDirLang(lex, "fr", "ltr")); + cand.add(NodeFactory.createLiteralDirLang(lex, "fr", "rtl")); + } + int asymmetry = 0; + int intransitive = 0; + for (Node a : cand) { + for (Node b : cand) { + if (sign(a, b) != -sign(b, a)) { + asymmetry++; + } + } + } + for (Node a : cand) { + for (Node b : cand) { + for (Node c : cand) { + if (sign(a, b) < 0 && sign(b, c) < 0 && sign(a, c) >= 0) { + intransitive++; + } + } + } + } + assertEquals(0, asymmetry); + assertEquals(0, intransitive); + } + + @Test + void shuffledSortsAgree() { + List pool = new ArrayList<>(); + for (int k = 0; k < 20; k++) { + pool.add(NodeFactory.createLiteralDirLang("v" + (k % 7), (k % 2 == 0) ? "en" : "fr", + (k % 3 == 0) ? "ltr" : "rtl")); + pool.add(NodeFactory.createLiteralLang("v" + (k % 7), "en")); + } + List reference = null; + for (int seed = 0; seed < 8; seed++) { + List shuffled = new ArrayList<>(pool); + Collections.shuffle(shuffled, new Random(seed)); + shuffled.sort(NodeComparator.INSTANCE); + if (reference == null) { + reference = shuffled; + } else { + assertEquals(reference, shuffled, "sort order depended on input order (seed " + seed + ")"); + } + } + } +} diff --git a/src/test/java/com/ebremer/beakgraph/w3c/W3CRdf12SuiteTest.java b/src/test/java/com/ebremer/beakgraph/w3c/W3CRdf12SuiteTest.java new file mode 100644 index 00000000..bdd19852 --- /dev/null +++ b/src/test/java/com/ebremer/beakgraph/w3c/W3CRdf12SuiteTest.java @@ -0,0 +1,255 @@ +package com.ebremer.beakgraph.w3c; + +import static org.junit.jupiter.api.Assertions.assertThrows; +import static org.junit.jupiter.api.Assertions.assertTrue; +import static org.junit.jupiter.api.Assertions.fail; + +import com.ebremer.beakgraph.BG; +import com.ebremer.beakgraph.core.BeakGraph; +import com.ebremer.beakgraph.hdf5.writers.HDF5Writer; +import java.io.File; +import java.nio.file.Path; +import java.nio.file.Paths; +import java.util.ArrayList; +import java.util.Iterator; +import java.util.List; +import java.util.stream.Stream; +import org.apache.jena.graph.Node; +import org.apache.jena.rdf.model.Model; +import org.apache.jena.rdf.model.RDFNode; +import org.apache.jena.rdf.model.Resource; +import org.apache.jena.riot.Lang; +import org.apache.jena.riot.RDFDataMgr; +import org.apache.jena.riot.RDFParser; +import org.apache.jena.sparql.core.DatasetGraph; +import org.apache.jena.sparql.core.DatasetGraphFactory; +import org.apache.jena.sparql.core.Quad; +import org.apache.jena.sparql.util.IsoMatcher; +import org.junit.jupiter.api.Assumptions; +import org.junit.jupiter.api.DynamicContainer; +import org.junit.jupiter.api.DynamicNode; +import org.junit.jupiter.api.DynamicTest; +import org.junit.jupiter.api.TestFactory; +import org.junit.jupiter.api.io.TempDir; + +/** + * Manifest-driven runner for the vendored W3C RDF 1.2 test suites + * (src/test/resources/w3c/rdf12 - see its README for provenance). + * + *

BeakGraph currently rejects RDF 1.2 terms it cannot store (triple terms, + * base-direction literals), so the runner asserts CONTAINMENT semantics: a + * test input containing unsupported terms must abort the build loudly; inputs + * without them must build and round-trip isomorphically. When Phases 2/3 land + * real storage, {@link #containsUnsupportedTerms} shrinks and the same + * manifests become the conformance oracle - no test code changes needed for + * new manifest entries. + * + *

Per test type: + *

+ */ +class W3CRdf12SuiteTest { + + private static final String MF = "http://www.w3.org/2001/sw/DataAccess/tests/test-manifest#"; + + private record Suite(String dir, Lang lang) {} + + private static final List SUITES = List.of( + new Suite("rdf-turtle/syntax", Lang.TURTLE), + new Suite("rdf-turtle/eval", Lang.TURTLE), + new Suite("rdf-n-triples/syntax", Lang.NTRIPLES), + new Suite("rdf-n-triples/c14n", Lang.NTRIPLES), + new Suite("rdf-n-quads/syntax", Lang.NQUADS), + new Suite("rdf-n-quads/c14n", Lang.NQUADS), + new Suite("rdf-trig/syntax", Lang.TRIG), + new Suite("rdf-trig/eval", Lang.TRIG)); + + @TempDir + static Path tmp; + + @TestFactory + Stream w3cRdf12() { + return SUITES.stream().map(this::suiteContainer); + } + + private DynamicContainer suiteContainer(Suite suite) { + Path manifestPath = resourcePath("/w3c/rdf12/" + suite.dir() + "/manifest.ttl"); + Model m = RDFDataMgr.loadModel(manifestPath.toUri().toString()); + Resource manifest = m.listResourcesWithProperty( + m.createProperty(MF, "entries")).nextResource(); + String assumedBase = manifest.getProperty(m.createProperty(MF, "assumedTestBase")) + .getObject().asResource().getURI(); + + List tests = new ArrayList<>(); + Iterator entries = manifest.getProperty(m.createProperty(MF, "entries")) + .getObject().as(org.apache.jena.rdf.model.RDFList.class).iterator(); + while (entries.hasNext()) { + Resource entry = entries.next().asResource(); + String type = entry.getProperty(org.apache.jena.vocabulary.RDF.type) + .getObject().asResource().getLocalName(); + String name = entry.getProperty(m.createProperty(MF, "name")).getString(); + Path action = toPath(entry.getProperty(m.createProperty(MF, "action")) + .getObject().asResource().getURI()); + Path result = entry.hasProperty(m.createProperty(MF, "result")) + ? toPath(entry.getProperty(m.createProperty(MF, "result")) + .getObject().asResource().getURI()) + : null; + String label = entry.getLocalName() + ": " + name; + tests.add(DynamicTest.dynamicTest(label, + () -> runEntry(type, suite.lang(), assumedBase, action, result, entry.getLocalName()))); + } + return DynamicContainer.dynamicContainer(suite.dir() + " (" + tests.size() + ")", tests); + } + + private void runEntry(String type, Lang lang, String assumedBase, + Path action, Path result, String id) throws Exception { + String base = assumedBase + action.getFileName(); + if (type.endsWith("PositiveC14N")) { + Assumptions.abort("c14n: canonical serialization is out of scope for a storage layer"); + } else if (type.endsWith("NegativeSyntax")) { + try { + parse(action, lang, base); + } catch (Exception correctlyRejected) { + return; + } + // Same policy as the eval divergences: parsing is Jena's layer, so a + // negative-syntax document Jena ACCEPTS is an upstream leniency, not + // a BeakGraph failure (whatever Jena hands over still passes the + // term-kind guards). Abort so it shows as skipped-with-reason; the + // vendored README lists the known cases for Jena 6.1.0. + Assumptions.abort("upstream: Jena accepts this negative-syntax document"); + } else if (type.endsWith("PositiveSyntax")) { + DatasetGraph parsed = parse(action, lang, base); + containmentSplit(parsed, action, id, null, lang); + } else if (type.endsWith("Eval")) { + DatasetGraph parsed = parse(action, lang, base); + DatasetGraph expected = parse(result, resultLang(result), base); + Assumptions.assumeTrue(IsoMatcher.isomorphic(normalize(parsed), normalize(expected)), + "upstream: Jena's parse differs from the W3C expected result"); + containmentSplit(parsed, action, id, expected, lang); + } else { + fail("unhandled manifest test type: " + type); + } + } + + /** + * The containment split: unsupported terms present -> BeakGraph must abort + * the build loudly on the RAW file; absent -> the build must succeed, and + * for eval tests the store must be isomorphic to the parsed input. + */ + private void containmentSplit(DatasetGraph parsed, Path rawAction, String id, + DatasetGraph expectedOrNull, Lang lang) throws Exception { + File dest = tmp.resolve(id + ".h5").toFile(); + if (containsUnsupportedTerms(parsed)) { + Exception ex = assertThrows(Exception.class, + () -> build(rawAction.toFile(), dest)); + assertTrue(chainMentionsGuard(ex), + "build failed, but not on a term-kind guard: " + ex); + return; + } + // Supported terms only: absolutize through Jena (the raw file may use + // relative IRIs, which BeakGraph deliberately stores unresolved), then + // the store must hold an isomorphic dataset. + Path absolutized = tmp.resolve(id + ".nq"); + RDFDataMgr.write(java.nio.file.Files.newOutputStream(absolutized), parsed, Lang.NQUADS); + build(absolutized.toFile(), dest); + DatasetGraph reference = (expectedOrNull != null) ? expectedOrNull : parsed; + try (BeakGraph bg = BG.getBeakGraph(dest)) { + assertTrue(IsoMatcher.isomorphic( + normalize(reference), + normalize(bg.getDataset().asDatasetGraph())), + "store round-trip is not isomorphic to the parsed input"); + } + } + + // ---- helpers ---- + + private static void build(File src, File dest) throws Exception { + HDF5Writer.Builder().setSource(src).setDestination(dest).build().write(); + } + + private static DatasetGraph parse(Path file, Lang lang, String base) { + DatasetGraph dsg = DatasetGraphFactory.create(); + RDFParser.create() + .source(file.toUri().toString()) + .lang(lang) + .base(base) + .parse(dsg); + return dsg; + } + + private static Lang resultLang(Path result) { + return result.getFileName().toString().endsWith(".nq") ? Lang.NQUADS : Lang.NTRIPLES; + } + + private static boolean containsUnsupportedTerms(DatasetGraph dsg) { + Iterator it = dsg.find(Node.ANY, Node.ANY, Node.ANY, Node.ANY); + while (it.hasNext()) { + Quad q = it.next(); + for (Node n : new Node[]{q.getGraph(), q.getSubject(), q.getPredicate(), q.getObject()}) { + if (n == null) { + continue; + } + if (n.isTripleTerm()) { + return true; + } + if (n.isLiteral() && n.getLiteralBaseDirection() != null) { + return true; + } + } + } + return false; + } + + private static boolean chainMentionsGuard(Throwable t) { + for (Throwable c = t; c != null; c = c.getCause()) { + String msg = c.getMessage(); + if (msg != null && (msg.contains("Unexpected") || msg.contains("Unsupported") + || msg.contains("base direction cannot be stored"))) { + return true; + } + } + return false; + } + + private static DatasetGraph normalize(DatasetGraph in) { + DatasetGraph out = DatasetGraphFactory.create(); + Iterator it = in.find(Node.ANY, Node.ANY, Node.ANY, Node.ANY); + while (it.hasNext()) { + Quad q = it.next(); + Node g = q.getGraph(); + if (g != null && g.isURI() && g.getURI().startsWith("urn:x-beakgraph:")) { + continue; + } + out.add(new Quad(q.isDefaultGraph() ? Quad.defaultGraphIRI : g, + q.getSubject(), q.getPredicate(), q.getObject())); + } + return out; + } + + private static Path resourcePath(String resource) { + try { + var url = W3CRdf12SuiteTest.class.getResource(resource); + if (url == null) { + throw new IllegalStateException("vendored suite missing: " + resource); + } + return Paths.get(url.toURI()); + } catch (java.net.URISyntaxException e) { + throw new IllegalStateException(e); + } + } + + private static Path toPath(String fileUri) { + return Paths.get(java.net.URI.create(fileUri)); + } +} diff --git a/src/test/resources/w3c/rdf12/LICENSE.md b/src/test/resources/w3c/rdf12/LICENSE.md new file mode 100644 index 00000000..9b31735a --- /dev/null +++ b/src/test/resources/w3c/rdf12/LICENSE.md @@ -0,0 +1,2 @@ +This repository is covered by the dual-licensing approach described in +[LICENSES FOR W3C TEST SUITES](https://www.w3.org/Consortium/Legal/2008/04-testsuite-copyright.html). diff --git a/src/test/resources/w3c/rdf12/README.md b/src/test/resources/w3c/rdf12/README.md new file mode 100644 index 00000000..9d317312 --- /dev/null +++ b/src/test/resources/w3c/rdf12/README.md @@ -0,0 +1,28 @@ +# W3C RDF 1.2 test suites (vendored) + +Vendored from https://github.com/w3c/rdf-tests (path `rdf/rdf12/`), +commit `d3e844aaa3e2f2b5250f2d1c988ce58870d6bc86`, on 2026-07-16. + +Suites: rdf-turtle (syntax, eval), rdf-n-triples (syntax, c14n), +rdf-n-quads (syntax, c14n), rdf-trig (syntax, eval). + +Distributed under the W3C Test Suite License and the W3C 3-clause BSD License +(see LICENSE.md and the headers in each manifest.ttl). + +Runner: `com.ebremer.beakgraph.w3c.W3CRdf12SuiteTest` — a manifest-driven +JUnit @TestFactory. To refresh, re-copy from a newer rdf-tests commit and +update the hash above; new manifest entries appear as tests automatically. + +## Known upstream divergences (Jena 6.1.0) + +Six negative-syntax documents are ACCEPTED by Jena 6.1.0's parser; the runner +reports them as aborted ("upstream: Jena accepts this negative-syntax +document") rather than failed, because parsing is Jena's layer and anything it +hands over still passes BeakGraph's term-kind guards: + +- rdf-turtle/syntax: turtle12-surrogate-pair-bad-01, turtle12-surrogate-pair-bad-02 +- rdf-n-triples/syntax: ntriples12-bad-iri-1, ntriples-langdir-bad-3, + ntriples-langdir-bad-4, ntriples-langdir-bad-5 + +Re-check this list on any Jena upgrade: entries disappearing from the aborted +set mean Jena tightened its parser. diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/README.md b/src/test/resources/w3c/rdf12/rdf-n-quads/README.md new file mode 100644 index 00000000..527c7f7a --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/README.md @@ -0,0 +1,18 @@ +This README is for the W3C RDF & SPARQL Working Group's N-Quads test suite. +This test suite contains three kinds of tests: + +* Positive syntax (`rdft:TestNQuadsPositiveSyntax`) — an input N-Quads file with no syntax errors. +* Negative syntax (`rdft:TestNQuadsNegativeSyntax`) — an input N-Quads file with at least one syntax error. +* Positive canonicalization (`rdft:TestNQuadsPositiveC14N`) — an input N-Quads file with no syntax errors. + +The `manifest.ttl` files in this directory lists tests in the RDF-star WG's N-Quads test suite. +All tests have a name (`mf:name`) and an input (`mf:action`). + +* An implementation passes a positive syntax test if it parses the + input. +* An implementation passes a negative syntax test if it fails to parse + the input. +* An implementation passes a positive canonicalization test if it parses the + input, and generates the expected result (`mf:result`) compared as text when generating the canonical form of triples. + +The home of the test suite is . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/comment_following_triple-c14n.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/comment_following_triple-c14n.nq new file mode 100644 index 00000000..a52ec902 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/comment_following_triple-c14n.nq @@ -0,0 +1 @@ + . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/comment_following_triple.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/comment_following_triple.nq new file mode 100644 index 00000000..00abe11f --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/comment_following_triple.nq @@ -0,0 +1,2 @@ +# comment + . # comment diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/dirlangtagged_string-c14n.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/dirlangtagged_string-c14n.nq new file mode 100644 index 00000000..0bbc63ac --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/dirlangtagged_string-c14n.nq @@ -0,0 +1 @@ + "chat"@en-gb--ltr . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/dirlangtagged_string.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/dirlangtagged_string.nq new file mode 100644 index 00000000..47f62f38 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/dirlangtagged_string.nq @@ -0,0 +1 @@ + "chat"@EN-GB--ltr . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/extra_whitespace-01-c14n.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/extra_whitespace-01-c14n.nq new file mode 100644 index 00000000..a52ec902 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/extra_whitespace-01-c14n.nq @@ -0,0 +1 @@ + . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/extra_whitespace-01.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/extra_whitespace-01.nq new file mode 100644 index 00000000..37526367 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/extra_whitespace-01.nq @@ -0,0 +1 @@ + . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/extra_whitespace-02-c14n.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/extra_whitespace-02-c14n.nq new file mode 100644 index 00000000..6d56d491 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/extra_whitespace-02-c14n.nq @@ -0,0 +1 @@ + "Alice" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/extra_whitespace-02.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/extra_whitespace-02.nq new file mode 100644 index 00000000..756241b7 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/extra_whitespace-02.nq @@ -0,0 +1 @@ + "Alice" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/extra_whitespace-03-c14n.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/extra_whitespace-03-c14n.nq new file mode 100644 index 00000000..06d61fee --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/extra_whitespace-03-c14n.nq @@ -0,0 +1 @@ + "Alice"@en . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/extra_whitespace-03.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/extra_whitespace-03.nq new file mode 100644 index 00000000..b3481aff --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/extra_whitespace-03.nq @@ -0,0 +1 @@ + "Alice" @en . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/extra_whitespace-04-c14n.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/extra_whitespace-04-c14n.nq new file mode 100644 index 00000000..6d6e3221 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/extra_whitespace-04-c14n.nq @@ -0,0 +1 @@ + "2"^^ . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/extra_whitespace-04.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/extra_whitespace-04.nq new file mode 100644 index 00000000..02008d58 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/extra_whitespace-04.nq @@ -0,0 +1 @@ + "2" ^^ . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/langtagged_string-c14n.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/langtagged_string-c14n.nq new file mode 100644 index 00000000..ecd19401 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/langtagged_string-c14n.nq @@ -0,0 +1 @@ + "chat"@en . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/langtagged_string.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/langtagged_string.nq new file mode 100644 index 00000000..06d0b530 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/langtagged_string.nq @@ -0,0 +1 @@ + "chat"@EN . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_all_controls-c14n.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_all_controls-c14n.nq new file mode 100644 index 00000000..b580faf9 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_all_controls-c14n.nq @@ -0,0 +1 @@ + "\u0000\u0001\u0002\u0003\u0004\u0005\u0006\u0007\b\t\u000B\f\u000E\u000F\u0010\u0011\u0012\u0013\u0014\u0015\u0016\u0017\u0018\u0019\u001A\u001B\u001C\u001D\u001E\u001F" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_all_controls.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_all_controls.nq new file mode 100644 index 00000000..c7870001 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_all_controls.nq @@ -0,0 +1 @@ + "\u0000\u0001\u0002\u0003\u0004\u0005\u0006\u0007\u0008\t\u000B\u000C\u000E\u000F\u0010\u0011\u0012\u0013\u0014\u0015\u0016\u0017\u0018\u0019\u001A\u001B\u001C\u001D\u001E\u001F" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_all_punctuation-c14n.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_all_punctuation-c14n.nq new file mode 100644 index 00000000..c2c66d4a --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_all_punctuation-c14n.nq @@ -0,0 +1 @@ + " !\"#$%&():;<=>?@[]^_`{|}~" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_all_punctuation.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_all_punctuation.nq new file mode 100644 index 00000000..c2c66d4a --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_all_punctuation.nq @@ -0,0 +1 @@ + " !\"#$%&():;<=>?@[]^_`{|}~" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_ascii_boundaries-c14n.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_ascii_boundaries-c14n.nq new file mode 100644 index 00000000..7ef1f4f7 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_ascii_boundaries-c14n.nq @@ -0,0 +1 @@ + "\u0000\t\u000B\f\u000E&([]\u007F" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_ascii_boundaries.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_ascii_boundaries.nq new file mode 100644 index 0000000000000000000000000000000000000000..1948cf85eb8c66dd64dd80d9975901b304414045 GIT binary patch literal 76 zcmcD?C@Cqh($`PaORY%EEyzjLFSb*#!4NF4Q&3{y "\u0000\u0001\u0002\u0003\u0004\u0005\u0006\u0007\u000B\u000E\u000F\u0010\u0011\u0012\u0013\u0014\u0015\u0016\u0017\u0018\u0019\u001A\u001B\u001C\u001D\u001E\u001F\u007F\uFFFE\uFFFF" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_needing_uchar_escaping-01.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_needing_uchar_escaping-01.nq new file mode 100644 index 0000000000000000000000000000000000000000..ee499f685b58c450278c27b53b485b41a03154b9 GIT binary patch literal 103 zcmcD?C@Cqh($`PaORY%EEyzjLFSb*#!4NF4Q&3`HWMXDvWn<^&;};MV5*85^6PJ*b bl9rK`ldpfjf8YE4`;`>1Xic|M(BlFC=*JxI literal 0 HcmV?d00001 diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_needing_uchar_escaping-02.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_needing_uchar_escaping-02.nq new file mode 100644 index 00000000..31573bd0 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_needing_uchar_escaping-02.nq @@ -0,0 +1,2 @@ + "\U00000000\U00000001\U00000002\U00000003\U00000004\U00000005\U00000006\U00000007\U0000000B\U0000000E\U0000000F\U00000010\U00000011\U00000012\U00000013\U00000014\U00000015\U00000016\U00000017\U00000018\U00000019\U0000001A\U0000001B\U0000001C\U0000001D\U0000001E\U0000001F\U0000007F\U0000FFFE\U0000FFFF" . +# 30 codepoints diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_2_dquotes-c14n.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_2_dquotes-c14n.nq new file mode 100644 index 00000000..828cf8a6 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_2_dquotes-c14n.nq @@ -0,0 +1 @@ + "x\"\"y" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_2_dquotes.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_2_dquotes.nq new file mode 100644 index 00000000..828cf8a6 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_2_dquotes.nq @@ -0,0 +1 @@ + "x\"\"y" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_2_squotes-c14n.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_2_squotes-c14n.nq new file mode 100644 index 00000000..69850e07 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_2_squotes-c14n.nq @@ -0,0 +1 @@ + "x''y" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_2_squotes.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_2_squotes.nq new file mode 100644 index 00000000..69850e07 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_2_squotes.nq @@ -0,0 +1 @@ + "x''y" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_BACKSPACE-c14n.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_BACKSPACE-c14n.nq new file mode 100644 index 00000000..e0ba1df5 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_BACKSPACE-c14n.nq @@ -0,0 +1 @@ + "\b" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_BACKSPACE.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_BACKSPACE.nq new file mode 100644 index 00000000..fc925a1c --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_BACKSPACE.nq @@ -0,0 +1 @@ + "\u0008" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_CARRIAGE_RETURN-c14n.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_CARRIAGE_RETURN-c14n.nq new file mode 100644 index 00000000..83cf4093 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_CARRIAGE_RETURN-c14n.nq @@ -0,0 +1 @@ + "\r" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_CARRIAGE_RETURN.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_CARRIAGE_RETURN.nq new file mode 100644 index 00000000..7915bc0c --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_CARRIAGE_RETURN.nq @@ -0,0 +1 @@ + "\u000D" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_CHARACTER_TABULATION-c14n.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_CHARACTER_TABULATION-c14n.nq new file mode 100644 index 00000000..363ff3b1 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_CHARACTER_TABULATION-c14n.nq @@ -0,0 +1 @@ + "\t" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_CHARACTER_TABULATION.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_CHARACTER_TABULATION.nq new file mode 100644 index 00000000..1ef626a7 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_CHARACTER_TABULATION.nq @@ -0,0 +1 @@ + "\u0009" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_FORM_FEED-c14n.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_FORM_FEED-c14n.nq new file mode 100644 index 00000000..2449bb9f --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_FORM_FEED-c14n.nq @@ -0,0 +1 @@ + "\f" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_FORM_FEED.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_FORM_FEED.nq new file mode 100644 index 00000000..9dce888a --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_FORM_FEED.nq @@ -0,0 +1 @@ + "\u000c" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_LINE_FEED-c14n.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_LINE_FEED-c14n.nq new file mode 100644 index 00000000..334a90f5 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_LINE_FEED-c14n.nq @@ -0,0 +1 @@ + "\n" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_LINE_FEED.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_LINE_FEED.nq new file mode 100644 index 00000000..4a974944 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_LINE_FEED.nq @@ -0,0 +1 @@ + "\u000a" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_REVERSE_SOLIDUS-c14n.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_REVERSE_SOLIDUS-c14n.nq new file mode 100644 index 00000000..5798a1cd --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_REVERSE_SOLIDUS-c14n.nq @@ -0,0 +1 @@ + "\\" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_REVERSE_SOLIDUS.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_REVERSE_SOLIDUS.nq new file mode 100644 index 00000000..5798a1cd --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_REVERSE_SOLIDUS.nq @@ -0,0 +1 @@ + "\\" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_REVERSE_SOLIDUS2-c14n.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_REVERSE_SOLIDUS2-c14n.nq new file mode 100644 index 00000000..e2912c45 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_REVERSE_SOLIDUS2-c14n.nq @@ -0,0 +1 @@ + "test-\\" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_REVERSE_SOLIDUS2.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_REVERSE_SOLIDUS2.nq new file mode 100644 index 00000000..e2912c45 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_REVERSE_SOLIDUS2.nq @@ -0,0 +1 @@ + "test-\\" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_UTF8_boundaries-c14n.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_UTF8_boundaries-c14n.nq new file mode 100644 index 00000000..5c7b5706 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_UTF8_boundaries-c14n.nq @@ -0,0 +1 @@ + "€߿ࠀ࿿က쿿퀀퟿�𐀀𿿽񀀀󿿽􀀀􏿽" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_UTF8_boundaries.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_UTF8_boundaries.nq new file mode 100644 index 00000000..5c7b5706 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_UTF8_boundaries.nq @@ -0,0 +1 @@ + "€߿ࠀ࿿က쿿퀀퟿�𐀀𿿽񀀀󿿽􀀀􏿽" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_dquote-c14n.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_dquote-c14n.nq new file mode 100644 index 00000000..5bb06485 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_dquote-c14n.nq @@ -0,0 +1 @@ + "x\"y" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_dquote.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_dquote.nq new file mode 100644 index 00000000..6b8dba52 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_dquote.nq @@ -0,0 +1 @@ + "x\u0022y" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_extra_whitespace-c14n.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_extra_whitespace-c14n.nq new file mode 100644 index 00000000..ead15641 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_extra_whitespace-c14n.nq @@ -0,0 +1 @@ + " a b c \n\n\t\t\r\r" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_extra_whitespace.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_extra_whitespace.nq new file mode 100644 index 00000000..ead15641 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_extra_whitespace.nq @@ -0,0 +1 @@ + " a b c \n\n\t\t\r\r" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_numeric_escape4-c14n.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_numeric_escape4-c14n.nq new file mode 100644 index 00000000..ee299963 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_numeric_escape4-c14n.nq @@ -0,0 +1 @@ + "o" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_numeric_escape4.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_numeric_escape4.nq new file mode 100644 index 00000000..8b9ede52 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_numeric_escape4.nq @@ -0,0 +1 @@ + "\u006F" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_numeric_escape8-c14n.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_numeric_escape8-c14n.nq new file mode 100644 index 00000000..ee299963 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_numeric_escape8-c14n.nq @@ -0,0 +1 @@ + "o" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_numeric_escape8.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_numeric_escape8.nq new file mode 100644 index 00000000..6b19bdb1 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_numeric_escape8.nq @@ -0,0 +1 @@ + "\U0000006F" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_squote-c14n.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_squote-c14n.nq new file mode 100644 index 00000000..2427bbc0 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_squote-c14n.nq @@ -0,0 +1 @@ + "x'y" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_squote.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_squote.nq new file mode 100644 index 00000000..2427bbc0 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_squote.nq @@ -0,0 +1 @@ + "x'y" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_string_dt-c14n.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_string_dt-c14n.nq new file mode 100644 index 00000000..b718cde2 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_string_dt-c14n.nq @@ -0,0 +1 @@ + "foo" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_string_dt.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_string_dt.nq new file mode 100644 index 00000000..b5fe8ba3 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/literal_with_string_dt.nq @@ -0,0 +1 @@ + "foo"^^ . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/manifest.ttl b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/manifest.ttl new file mode 100644 index 00000000..4eea356a --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/manifest.ttl @@ -0,0 +1,395 @@ +## Distributed under both the "W3C Test Suite License" [1] +## and the "W3C 3-clause BSD License". +## [1] https://www.w3.org/Consortium/Legal/2008/04-testsuite-license +## [2] https://www.w3.org/Consortium/Legal/2008/03-bsd-license +## +## Test types +## * rdft:TestNQuadsPositiveC14N – N-Quads canonicalization + +PREFIX : +PREFIX rdf: +PREFIX rdfs: +PREFIX mf: +PREFIX rdft: + +:manifest a mf:Manifest ; + rdfs:label "RDF 1.2 N-Quads Canonicalization Test Suite"@en; + rdfs:comment "Tests the generation of canonical N-Quads."@en; + mf:assumedTestBase ; + rdfs:seeAlso ; + mf:entries ( + :comment_following_triple + :extra_whitespace-01 + :extra_whitespace-02 + :extra_whitespace-03 + :extra_whitespace-04 + :langtagged_string + # :lantag_with_subtag + :dirlangtagged_string + :literal_all_controls + :literal_all_punctuation + :literal_ascii_boundaries + :literal_with_2_dquotes + :literal_with_2_squotes + :literal_with_BACKSPACE + :literal_with_CARRIAGE_RETURN + :literal_with_CHARACTER_TABULATION + :literal_with_dquote + :literal_with_FORM_FEED + :literal_with_LINE_FEED + :literal_with_numeric_escape4 + :literal_with_numeric_escape8 + :literal_with_REVERSE_SOLIDUS + :literal_with_REVERSE_SOLIDUS2 + :literal_with_squote + :literal_with_string_dt + :literal_with_extra_whitespace + :literal_with_UTF8_boundaries + :minimal_whitespace-01 + :minimal_whitespace-02 + :triple-term-01 + :triple-term-02 + :triple-term-03 + :triple-term-04 + :nq-syntax-uri-01 + :nq-syntax-uri-02 + :nq-syntax-uri-03 + :nq-syntax-uri-04 + :nq-syntax-str-esc-01 + :nq-syntax-str-esc-02 + :nq-syntax-str-esc-03 + :literal_needing_uchar_escaping-01 + :literal_needing_uchar_escaping-02 + ) . + +:comment_following_triple rdf:type rdft:TestNQuadsPositiveC14N ; + mf:name "C14N comment_following_triple" ; + rdfs:comment "Tests canonicalization of quads including comments" ; + rdft:approval rdft:Proposed ; + mf:action ; + mf:result ; + . + +:langtagged_string rdf:type rdft:TestNQuadsPositiveC14N ; + mf:name "C14N langtagged_string" ; + rdfs:comment "Tests canonicalization of quads including language-tagged string" ; + rdft:approval rdft:Proposed ; + mf:action ; + mf:result ; + . + +#:lantag_with_subtag rdf:type rdft:TestNQuadsPositiveC14N ; +# mf:name "C14N lantag_with_subtag" ; +# rdfs:comment "Tests canonicalization of quads including language-tagged string with subtag" ; +# rdft:approval rdft:Proposed ; +# mf:action ; +# mf:result ; +# . + +:dirlangtagged_string rdf:type rdft:TestNQuadsPositiveC14N ; + mf:name "C14N literal with base direction ltr" ; + rdfs:comment "Tests canonicalization of quads including directional language-tagged string" ; + rdft:approval rdft:Proposed ; + mf:action ; + mf:result ; + . + +:literal_all_controls rdf:type rdft:TestNQuadsPositiveC14N ; + mf:name "C14N literal_all_controls" ; + rdfs:comment "Tests canonicalization of literals with control characters" ; + rdft:approval rdft:Proposed ; + mf:action ; + mf:result ; + . + +:literal_all_punctuation rdf:type rdft:TestNQuadsPositiveC14N ; + mf:name "C14N literal_all_punctuation" ; + rdfs:comment "Tests canonicalization of literals with punctuation characters" ; + rdft:approval rdft:Proposed ; + mf:action ; + mf:result ; + . + +:literal_ascii_boundaries rdf:type rdft:TestNQuadsPositiveC14N ; + mf:name "C14N literal_ascii_boundaries" ; + rdfs:comment "Tests canonicalization of literal_ascii_boundaries '\\x00\\x26\\x28...'" ; + rdft:approval rdft:Proposed ; + mf:action ; + mf:result ; + . + +:literal_with_2_dquotes rdf:type rdft:TestNQuadsPositiveC14N ; + mf:name "C14N literal_with_2_dquotes" ; + rdfs:comment "Tests canonicalization of literal with 2 dquotes \"\"\"a\"\"b\"\"\"" ; + rdft:approval rdft:Proposed ; + mf:action ; + mf:result ; + . + +:literal_with_2_squotes rdf:type rdft:TestNQuadsPositiveC14N ; + mf:name "C14N literal_with_2_squotes" ; + rdfs:comment "Tests canonicalization of literal with 2 squotes \"x''y\"" ; + rdft:approval rdft:Proposed ; + mf:action ; + mf:result ; + . + +:literal_with_BACKSPACE rdf:type rdft:TestNQuadsPositiveC14N ; + mf:name "C14N literal_with_BACKSPACE" ; + rdfs:comment "Tests canonicalization of literals with backspace" ; + rdft:approval rdft:Proposed ; + mf:action ; + mf:result ; + . + +:literal_with_CARRIAGE_RETURN rdf:type rdft:TestNQuadsPositiveC14N ; + mf:name "C14N literal_with_CARRIAGE_RETURN" ; + rdfs:comment "Tests canonicalization of literals with carriage return" ; + rdft:approval rdft:Proposed ; + mf:action ; + mf:result ; + . + +:literal_with_CHARACTER_TABULATION rdf:type rdft:TestNQuadsPositiveC14N ; + mf:name "C14N literal_with_CHARACTER_TABULATION" ; + rdfs:comment "Tests canonicalization of literals with character tabulation" ; + rdft:approval rdft:Proposed ; + mf:action ; + mf:result ; + . + +:literal_with_dquote rdf:type rdft:TestNQuadsPositiveC14N ; + mf:name "C14N literal_with_dquote" ; + rdfs:comment "Tests canonicalization of literals with double quote" ; + rdft:approval rdft:Proposed ; + mf:action ; + mf:result ; + . + +:literal_with_FORM_FEED rdf:type rdft:TestNQuadsPositiveC14N ; + mf:name "C14N literal_with_FORM_FEED" ; + rdfs:comment "Tests canonicalization of literals with form feed" ; + rdft:approval rdft:Proposed ; + mf:action ; + mf:result ; + . + +:literal_with_LINE_FEED rdf:type rdft:TestNQuadsPositiveC14N ; + mf:name "C14N literal_with_LINE_FEED" ; + rdfs:comment "Tests canonicalization of literals with line feed" ; + rdft:approval rdft:Proposed ; + mf:action ; + mf:result ; + . + +:literal_with_numeric_escape4 rdf:type rdft:TestNQuadsPositiveC14N ; + mf:name "C14N literal_with_numeric_escape4" ; + rdfs:comment "Tests canonicalization of literals with numeric escapes" ; + rdft:approval rdft:Proposed ; + mf:action ; + mf:result ; + . + +:literal_with_numeric_escape8 rdf:type rdft:TestNQuadsPositiveC14N ; + mf:name "C14N literal_with_numeric_escape8" ; + rdfs:comment "Tests canonicalization of literals with numeric escapes" ; + rdft:approval rdft:Proposed ; + mf:action ; + mf:result ; + . + +:literal_with_REVERSE_SOLIDUS rdf:type rdft:TestNQuadsPositiveC14N ; + mf:name "C14N literal_with_REVERSE_SOLIDUS" ; + rdfs:comment "Tests canonicalization of literals with reverse solidus" ; + rdft:approval rdft:Proposed ; + mf:action ; + mf:result ; + . + +:literal_with_REVERSE_SOLIDUS2 rdf:type rdft:TestNQuadsPositiveC14N ; + mf:name "C14N literal_with_REVERSE_SOLIDUS2" ; + rdfs:comment "Tests canonicalization of literals with reverse solidus" ; + rdft:approval rdft:Proposed ; + mf:action ; + mf:result ; + . + +:literal_with_squote rdf:type rdft:TestNQuadsPositiveC14N ; + mf:name "C14N literal_with_squote" ; + rdfs:comment "Tests canonicalization of literals with single quotes" ; + rdft:approval rdft:Proposed ; + mf:action ; + mf:result ; + . + +:literal_with_string_dt rdf:type rdft:TestNQuadsPositiveC14N ; + mf:name "C14N literal_with_string_dt" ; + rdfs:comment "Tests canonicalization of literal with explicit xsd:string" ; + rdft:approval rdft:Proposed ; + mf:action ; + mf:result ; + . + +:literal_with_UTF8_boundaries rdf:type rdft:TestNQuadsPositiveC14N ; + mf:name "C14N literal_with_UTF8_boundaries" ; + rdfs:comment "Tests canonicalization of literals with UTF8 boundaries" ; + rdft:approval rdft:Proposed ; + mf:action ; + mf:result ; + . + +:literal_with_extra_whitespace rdf:type rdft:TestNQuadsPositiveC14N ; + mf:name "C14N literal_with_extra_whitespace" ; + rdfs:comment "Tests canonicalization of quads with literals having extra whitespace" ; + rdft:approval rdft:Proposed ; + mf:action ; + mf:result ; + . + +:minimal_whitespace-01 rdf:type rdft:TestNQuadsPositiveC14N ; + mf:name "C14N minimal_whitespace-01" ; + rdfs:comment "Tests canonicalization of quads without optional whitespace" ; + rdft:approval rdft:Proposed ; + mf:action ; + mf:result ; + . + +:triple-term-01 rdf:type rdft:TestNQuadsPositiveC14N ; + mf:name "C14N triple-term-01" ; + rdfs:comment "Tests canonicalization of triple terms with iri subject and object" ; + mf:action ; + mf:result ; + . + +:triple-term-02 rdf:type rdft:TestNQuadsPositiveC14N ; + mf:name "C14N triple-term-02" ; + rdfs:comment "Tests canonicalization of triple terms with iri subject and bnode object" ; + mf:action ; + mf:result ; + . + +:triple-term-03 rdf:type rdft:TestNQuadsPositiveC14N ; + mf:name "C14N triple-term-03" ; + rdfs:comment "Tests canonicalization of triple terms with iri subject and literal object" ; + mf:action ; + mf:result ; + . + +:triple-term-04 rdf:type rdft:TestNQuadsPositiveC14N ; + mf:name "C14N triple-term-03" ; + rdfs:comment "Tests canonicalization of triple terms with triple term object" ; + mf:action ; + mf:result ; + . + +:minimal_whitespace-02 rdf:type rdft:TestNQuadsPositiveC14N ; + mf:name "C14N minimal_whitespace-02" ; + rdfs:comment "Tests canonicalization of quads without optional whitespace" ; + rdft:approval rdft:Proposed ; + mf:action ; + mf:result ; + . + +:extra_whitespace-01 rdf:type rdft:TestNQuadsPositiveC14N ; + mf:name "C14N extra_whitespace-01" ; + rdfs:comment "Tests canonicalization of quads with extra whitespace" ; + rdft:approval rdft:Proposed ; + mf:action ; + mf:result ; + . + +:extra_whitespace-02 rdf:type rdft:TestNQuadsPositiveC14N ; + mf:name "C14N extra_whitespace-02" ; + rdfs:comment "Tests canonicalization of quads with extra whitespace" ; + rdft:approval rdft:Proposed ; + mf:action ; + mf:result ; + . + +:extra_whitespace-03 rdf:type rdft:TestNQuadsPositiveC14N ; + mf:name "C14N extra_whitespace-03" ; + rdfs:comment "Tests canonicalization of quads with extra whitespace" ; + rdft:approval rdft:Proposed ; + mf:action ; + mf:result ; + . + +:extra_whitespace-04 rdf:type rdft:TestNQuadsPositiveC14N ; + mf:name "C14N extra_whitespace-04" ; + rdfs:comment "Tests canonicalization of quads with extra whitespace" ; + rdft:approval rdft:Proposed ; + mf:action ; + mf:result ; + . + +:nq-syntax-uri-01 rdf:type rdft:TestNQuadsPositiveC14N ; + mf:name "C14N nq-syntax-uri-01" ; + rdfs:comment "Tests canonicalization of IRIs" ; + rdft:approval rdft:Proposed ; + mf:action ; + mf:result ; + . + +:nq-syntax-uri-02 rdf:type rdft:TestNQuadsPositiveC14N ; + mf:name "C14N nq-syntax-uri-02" ; + rdfs:comment "Tests canonicalization of IRIs" ; + rdft:approval rdft:Proposed ; + mf:action ; + mf:result ; + . + +:nq-syntax-uri-03 rdf:type rdft:TestNQuadsPositiveC14N ; + mf:name "C14N nq-syntax-uri-03" ; + rdfs:comment "Tests canonicalization of IRIs" ; + rdft:approval rdft:Proposed ; + mf:action ; + mf:result ; + . + +:nq-syntax-uri-04 rdf:type rdft:TestNQuadsPositiveC14N ; + mf:name "C14N nq-syntax-uri-04" ; + rdfs:comment "Tests canonicalization of IRIs" ; + rdft:approval rdft:Proposed ; + mf:action ; + mf:result ; + . + +:nq-syntax-str-esc-01 rdf:type rdft:TestNQuadsPositiveC14N ; + mf:name "C14N nq-syntax-str-esc-01" ; + rdfs:comment "Tests canonicalization of string escapes" ; + rdft:approval rdft:Proposed ; + mf:action ; + mf:result ; + . + +:nq-syntax-str-esc-02 rdf:type rdft:TestNQuadsPositiveC14N ; + mf:name "C14N nq-syntax-str-esc-02" ; + rdfs:comment "Tests canonicalization of string escapes" ; + rdft:approval rdft:Proposed ; + mf:action ; + mf:result ; + . + +:nq-syntax-str-esc-03 rdf:type rdft:TestNQuadsPositiveC14N ; + mf:name "C14N nq-syntax-str-esc-03" ; + rdfs:comment "Tests canonicalization of string escapes" ; + rdft:approval rdft:Proposed ; + mf:action ; + mf:result ; + . + +:literal_needing_uchar_escaping-01 rdf:type rdft:TestNQuadsPositiveC14N ; + mf:name "C14N literal_needing_uchar_escaping-01" ; + rdfs:comment "Tests canonicalization of strings with codepoints requiring UCHAR escaping, with input using raw UTF-8 data" ; + rdft:approval rdft:Proposed ; + mf:action ; + mf:result ; + . + +:literal_needing_uchar_escaping-02 rdf:type rdft:TestNQuadsPositiveC14N ; + mf:name "C14N literal_needing_uchar_escaping-02" ; + rdfs:comment "Tests canonicalization of strings with codepoints requiring UCHAR escaping, with input using \\U escaping" ; + rdft:approval rdft:Proposed ; + mf:action ; + mf:result ; + . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/minimal_whitespace-01-c14n.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/minimal_whitespace-01-c14n.nq new file mode 100644 index 00000000..a52ec902 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/minimal_whitespace-01-c14n.nq @@ -0,0 +1 @@ + . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/minimal_whitespace-01.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/minimal_whitespace-01.nq new file mode 100644 index 00000000..6381c50b --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/minimal_whitespace-01.nq @@ -0,0 +1 @@ +. \ No newline at end of file diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/minimal_whitespace-02-c14n.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/minimal_whitespace-02-c14n.nq new file mode 100644 index 00000000..6d56d491 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/minimal_whitespace-02-c14n.nq @@ -0,0 +1 @@ + "Alice" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/minimal_whitespace-02.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/minimal_whitespace-02.nq new file mode 100644 index 00000000..0fca0b63 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/minimal_whitespace-02.nq @@ -0,0 +1 @@ +"Alice". \ No newline at end of file diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/nq-syntax-str-esc-01-c14n.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/nq-syntax-str-esc-01-c14n.nq new file mode 100644 index 00000000..0bb8806b --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/nq-syntax-str-esc-01-c14n.nq @@ -0,0 +1 @@ + "a\n" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/nq-syntax-str-esc-01.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/nq-syntax-str-esc-01.nq new file mode 100644 index 00000000..0bb8806b --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/nq-syntax-str-esc-01.nq @@ -0,0 +1 @@ + "a\n" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/nq-syntax-str-esc-02-c14n.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/nq-syntax-str-esc-02-c14n.nq new file mode 100644 index 00000000..1ed4c434 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/nq-syntax-str-esc-02-c14n.nq @@ -0,0 +1 @@ + "a b" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/nq-syntax-str-esc-02.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/nq-syntax-str-esc-02.nq new file mode 100644 index 00000000..817e0a57 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/nq-syntax-str-esc-02.nq @@ -0,0 +1 @@ + "a\u0020b" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/nq-syntax-str-esc-03-c14n.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/nq-syntax-str-esc-03-c14n.nq new file mode 100644 index 00000000..1ed4c434 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/nq-syntax-str-esc-03-c14n.nq @@ -0,0 +1 @@ + "a b" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/nq-syntax-str-esc-03.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/nq-syntax-str-esc-03.nq new file mode 100644 index 00000000..8b15b815 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/nq-syntax-str-esc-03.nq @@ -0,0 +1 @@ + "a\U00000020b" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/nq-syntax-uri-01-c14n.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/nq-syntax-uri-01-c14n.nq new file mode 100644 index 00000000..a52ec902 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/nq-syntax-uri-01-c14n.nq @@ -0,0 +1 @@ + . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/nq-syntax-uri-01.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/nq-syntax-uri-01.nq new file mode 100644 index 00000000..a52ec902 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/nq-syntax-uri-01.nq @@ -0,0 +1 @@ + . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/nq-syntax-uri-02-c14n.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/nq-syntax-uri-02-c14n.nq new file mode 100644 index 00000000..c65af5b3 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/nq-syntax-uri-02-c14n.nq @@ -0,0 +1 @@ + . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/nq-syntax-uri-02.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/nq-syntax-uri-02.nq new file mode 100644 index 00000000..2c9fcda7 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/nq-syntax-uri-02.nq @@ -0,0 +1,2 @@ +# x53 is capital S + . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/nq-syntax-uri-03-c14n.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/nq-syntax-uri-03-c14n.nq new file mode 100644 index 00000000..c65af5b3 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/nq-syntax-uri-03-c14n.nq @@ -0,0 +1 @@ + . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/nq-syntax-uri-03.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/nq-syntax-uri-03.nq new file mode 100644 index 00000000..03093088 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/nq-syntax-uri-03.nq @@ -0,0 +1,2 @@ +# x53 is capital S + . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/nq-syntax-uri-04-c14n.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/nq-syntax-uri-04-c14n.nq new file mode 100644 index 00000000..d39263bf --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/nq-syntax-uri-04-c14n.nq @@ -0,0 +1 @@ + . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/nq-syntax-uri-04.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/nq-syntax-uri-04.nq new file mode 100644 index 00000000..3a411fab --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/nq-syntax-uri-04.nq @@ -0,0 +1,2 @@ +# IRI with all chars in it. + . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/triple-term-01-c14n.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/triple-term-01-c14n.nq new file mode 100644 index 00000000..3386ecef --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/triple-term-01-c14n.nq @@ -0,0 +1 @@ + <<( )>> . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/triple-term-01.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/triple-term-01.nq new file mode 100644 index 00000000..3e53be6d --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/triple-term-01.nq @@ -0,0 +1 @@ + <<()>>. diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/triple-term-02-c14n.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/triple-term-02-c14n.nq new file mode 100644 index 00000000..00758386 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/triple-term-02-c14n.nq @@ -0,0 +1 @@ + <<( _:o1 )>> . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/triple-term-02.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/triple-term-02.nq new file mode 100644 index 00000000..43fadb7b --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/triple-term-02.nq @@ -0,0 +1 @@ + <<(_:o1)>>. diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/triple-term-03-c14n.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/triple-term-03-c14n.nq new file mode 100644 index 00000000..b32879c6 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/triple-term-03-c14n.nq @@ -0,0 +1 @@ + <<( "o1" )>> . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/triple-term-03.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/triple-term-03.nq new file mode 100644 index 00000000..bd06ec1f --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/triple-term-03.nq @@ -0,0 +1 @@ + <<("o1")>>. diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/triple-term-04-c14n.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/triple-term-04-c14n.nq new file mode 100644 index 00000000..a9587cef --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/triple-term-04-c14n.nq @@ -0,0 +1 @@ + <<( <<( "o2" )>> )>> . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/triple-term-04.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/triple-term-04.nq new file mode 100644 index 00000000..7180adc5 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/c14n/triple-term-04.nq @@ -0,0 +1 @@ + <<(<<("o2")>>)>>. diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/manifest.ttl b/src/test/resources/w3c/rdf12/rdf-n-quads/manifest.ttl new file mode 100644 index 00000000..499778b1 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/manifest.ttl @@ -0,0 +1,36 @@ +PREFIX rdf: +PREFIX rdfs: +PREFIX mf: +PREFIX rdft: +PREFIX trs: +PREFIX dct: +PREFIX xsd: +PREFIX foaf: +PREFIX skos: + +trs:manifest rdf:type mf:Manifest ; + rdfs:label "RDF 1.2 N-Quads tests"@en ; + skos:prefLabel "La suite des tests pour RDF 1.2 N-Quads"@fr; + skos:prefLabel "Conjunto de pruebas para RDF 1.2 N-Quads"@es; + dct:issued "2023-10-28"^^xsd:date ; + rdfs:seeAlso ; + mf:assumedTestBase ; + dct:modified "2023-10-28"^^xsd:date ; + dct:licence ; + dct:creator [ foaf:homepage ; foaf:name "W3C RDF & SPARQL Working Group" ] ; + rdfs:comment """ + These test suites are a product of the [W3C RDF & SPARQL Working Group](https://www.w3.org/groups/wg/rdf-star/) as well as the + RDF-Star Interest Group within the W3C RDF-DEV Community Group, + and has been maintained by the + [RDF Test Curation Community Group](https://www.w3.org/community/rdf-tests/) + at [https://github.com/w3c/rdf-tests/tree/main/rdf/rdf11](https://github.com/w3c/rdf-tests/tree/main/rdf/rdf11/). + + Conformance with RDF 1.2 specifications can be determined via successfully running the + tests for relevant specifications + along with the relevant RDF 1.1 tests. + """; + mf:include ( + + + <../../rdf11/rdf-n-quads/manifest.ttl> + ) . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/manifest.ttl b/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/manifest.ttl new file mode 100644 index 00000000..3e60a78c --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/manifest.ttl @@ -0,0 +1,207 @@ +## Distributed under both the "W3C Test Suite License" [1] +## and the "W3C 3-clause BSD License". +## [1] https://www.w3.org/Consortium/Legal/2008/04-testsuite-license +## [2] https://www.w3.org/Consortium/Legal/2008/03-bsd-license + +PREFIX rdf: +PREFIX rdfs: +PREFIX mf: +PREFIX rdft: +PREFIX trs: +PREFIX dct: +PREFIX xsd: +PREFIX foaf: +PREFIX skos: + +trs:manifest rdf:type mf:Manifest ; + rdfs:label "RDF 1.2 N-Quads Syntax Tests"@en ; + skos:prefLabel "La suite des tests pour RDF 1.2 N-Quads"@fr; + skos:prefLabel "Conjunto de pruebas para RDF 1.2 N-Quads"@es; + mf:assumedTestBase ; + dct:issued "2023-07-20"^^xsd:date ; + dct:modified "2023-07-20"^^xsd:date ; + dct:licence ; + dct:creator [ foaf:homepage ; foaf:name "W3C RDF & SPARQL Working Group" ] ; + rdfs:seeAlso ; + mf:entries + ( + trs:nquads12-01 + trs:nquads12-02 + trs:nquads12-03 + + trs:nquads12-bnode-1 + + trs:nquads12-nested-1 + + trs:nquads-langdir-1 + trs:nquads-langdir-2 + + trs:nquads12-bad-01 + trs:nquads12-bad-02 + trs:nquads12-bad-03 + trs:nquads12-bad-04 + trs:nquads12-bad-05 + trs:nquads12-bad-06 + trs:nquads12-bad-07 + trs:nquads12-bad-08 + trs:nquads12-bad-09 + trs:nquads12-bad-10 + + trs:nquads12-bad-reified-1 + trs:nquads12-bad-reified-2 + trs:nquads12-bad-reified-3 + trs:nquads12-bad-reified-4 + + trs:nquads12-bnode-bad-annotated-syntax-1 + trs:nquads12-bnode-bad-annotated-syntax-2 + trs:nquads12-nested-bad-annotated-syntax-1 + trs:nquads12-nested-bad-annotated-syntax-2 + + trs:nquads-langdir-bad-1 + trs:nquads-langdir-bad-2 + ) . + +trs:nquads12-01 rdf:type rdft:TestNQuadsPositiveSyntax ; + mf:name "N-Quads-12 - object triple term" ; + mf:action ; + . + +trs:nquads12-02 rdf:type rdft:TestNQuadsPositiveSyntax ; + mf:name "N-Quads-12 - object triple term, no whitespace" ; + mf:action ; + . + +trs:nquads12-03 rdf:type rdft:TestNQuadsPositiveSyntax ; + mf:name "N-Quads-12 - Nested, no whitespace" ; + mf:action ; + . + +# Blank nodes + +trs:nquads12-bnode-1 rdf:type rdft:TestNQuadsPositiveSyntax ; + mf:name "N-Quads-12 - Blank node subject" ; + mf:action ; + . + +trs:nquads12-nested-1 rdf:type rdft:TestNQuadsPositiveSyntax ; + mf:name "N-Quads-12 - Nested object term" ; + mf:action ; + . + +# Base direction + +trs:nquads-langdir-1 rdf:type rdft:TestNQuadsPositiveSyntax ; + mf:name "N-Quads literal with base direction ltr" ; + mf:action ; + . + +trs:nquads-langdir-2 rdf:type rdft:TestNQuadsPositiveSyntax ; + mf:name "N-Quads literal with base direction rtl" ; + mf:action ; + . + +## Bad syntax + +trs:nquads12-bad-01 rdf:type rdft:TestNQuadsNegativeSyntax ; + mf:name "N-Quads-12 - Bad - reified triple as predicate" ; + mf:action ; + . + +trs:nquads12-bad-02 rdf:type rdft:TestNQuadsNegativeSyntax ; + mf:name "N-Quads-12 - Bad - reified triple, literal subject" ; + mf:action ; + . + +trs:nquads12-bad-03 rdf:type rdft:TestNQuadsNegativeSyntax ; + mf:name "N-Quads-12 - Bad - reified triple, literal predicate" ; + mf:action ; + . + +trs:nquads12-bad-04 rdf:type rdft:TestNQuadsNegativeSyntax ; + mf:name "N-Quads-12 - Bad - reified triple, blank node predicate" ; + mf:action ; + . + +trs:nquads12-bad-05 rdf:type rdft:TestNQuadsNegativeSyntax ; + mf:name "N-Quads-12 - Bad - triple term as predicate" ; + mf:action ; + . + +trs:nquads12-bad-06 rdf:type rdft:TestNQuadsNegativeSyntax ; + mf:name "N-Quads-12 - Bad - triple term, literal subject" ; + mf:action ; + . + +trs:nquads12-bad-07 rdf:type rdft:TestNQuadsNegativeSyntax ; + mf:name "N-Quads-12 - Bad - triple term, literal predicate" ; + mf:action ; + . + +trs:nquads12-bad-08 rdf:type rdft:TestNQuadsNegativeSyntax ; + mf:name "N-Quads-12 - Bad - triple term, blank node predicate" ; + mf:action ; + . + +trs:nquads12-bad-09 rdf:type rdft:TestNQuadsNegativeSyntax ; + mf:name "N-Quads-12 - Bad - reified triple object" ; + mf:action ; + . + +trs:nquads12-bad-10 rdf:type rdft:TestNQuadsNegativeSyntax ; + mf:name "N-Quads-12 - Bad - triple term as subject" ; + mf:action ; + . + +trs:nquads12-bad-reified-1 rdf:type rdft:TestNQuadsNegativeSyntax ; + mf:name "N-Quads-12 - Bad - subject reified triple" ; + mf:action ; + . + +trs:nquads12-bad-reified-2 rdf:type rdft:TestNQuadsNegativeSyntax ; + mf:name "N-Quads-12 - Bad - object reified triple" ; + mf:action ; + . + +trs:nquads12-bad-reified-3 rdf:type rdft:TestNQuadsNegativeSyntax ; + mf:name "N-Quads-12 - Bad - subject and object reified triples" ; + mf:action ; + . + +trs:nquads12-bad-reified-4 rdf:type rdft:TestNQuadsNegativeSyntax ; + mf:name "N-Quads-12 - Bad - predicate reified triple" ; + mf:action ; + . + +# Annotation syntax is not permitted in nq + +trs:nquads12-bnode-bad-annotated-syntax-1 rdf:type rdft:TestNQuadsNegativeSyntax ; + mf:name "N-Quads-12 - Bad - annotated triple, blank node subject" ; + mf:action ; + . + +trs:nquads12-bnode-bad-annotated-syntax-2 rdf:type rdft:TestNQuadsNegativeSyntax ; + mf:name "N-Quads-12 - Bad - annotated triple, blank node object" ; + mf:action ; + . + +trs:nquads12-nested-bad-annotated-syntax-1 rdf:type rdft:TestNQuadsNegativeSyntax ; + mf:name "N-Quads-12 - Bad - annotated triple, nested subject term" ; + mf:action ; + . + +trs:nquads12-nested-bad-annotated-syntax-2 rdf:type rdft:TestNQuadsNegativeSyntax ; + mf:name "N-Quads-12 - Bad - annotated triple, nested object term" ; + mf:action ; + . + +# Base direction + +trs:nquads-langdir-bad-1 rdf:type rdft:TestNQuadsNegativeSyntax ; + mf:name "N-Quads literal- Bad - undefined base direction" ; + mf:action ; + . + +trs:nquads-langdir-bad-2 rdf:type rdft:TestNQuadsNegativeSyntax ; + mf:name "N-Quads literal- Bad - upper case LTR" ; + mf:action ; + . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads-langdir-1.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads-langdir-1.nq new file mode 100644 index 00000000..4d167189 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads-langdir-1.nq @@ -0,0 +1 @@ + "Hello"@en--ltr . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads-langdir-2.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads-langdir-2.nq new file mode 100644 index 00000000..0a4f0b6a --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads-langdir-2.nq @@ -0,0 +1 @@ + "Hello"@en--rtl . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads-langdir-bad-1.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads-langdir-bad-1.nq new file mode 100644 index 00000000..e46bc931 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads-langdir-bad-1.nq @@ -0,0 +1 @@ + "Hello"@en--unk . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads-langdir-bad-2.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads-langdir-bad-2.nq new file mode 100644 index 00000000..5742251e --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads-langdir-bad-2.nq @@ -0,0 +1 @@ + "Hello"@en--LTR . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-bad-reified-syntax-1.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-bad-reified-syntax-1.nq new file mode 100644 index 00000000..639752aa --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-bad-reified-syntax-1.nq @@ -0,0 +1 @@ +<< >> . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-bad-reified-syntax-2.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-bad-reified-syntax-2.nq new file mode 100644 index 00000000..fff50698 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-bad-reified-syntax-2.nq @@ -0,0 +1 @@ + << >> . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-bad-reified-syntax-3.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-bad-reified-syntax-3.nq new file mode 100644 index 00000000..ab37655b --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-bad-reified-syntax-3.nq @@ -0,0 +1 @@ +<< >> << >> . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-bad-reified-syntax-4.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-bad-reified-syntax-4.nq new file mode 100644 index 00000000..8c0f806a --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-bad-reified-syntax-4.nq @@ -0,0 +1 @@ + << >> . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-bad-syntax-01.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-bad-syntax-01.nq new file mode 100644 index 00000000..b336536a --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-bad-syntax-01.nq @@ -0,0 +1 @@ + << >> . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-bad-syntax-02.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-bad-syntax-02.nq new file mode 100644 index 00000000..2f761e6b --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-bad-syntax-02.nq @@ -0,0 +1 @@ + <<( "XYZ" )>> . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-bad-syntax-03.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-bad-syntax-03.nq new file mode 100644 index 00000000..bf3d6032 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-bad-syntax-03.nq @@ -0,0 +1 @@ + <<( "XYZ" )>> . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-bad-syntax-04.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-bad-syntax-04.nq new file mode 100644 index 00000000..72fa9668 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-bad-syntax-04.nq @@ -0,0 +1 @@ + << _:label >> > . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-bad-syntax-05.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-bad-syntax-05.nq new file mode 100644 index 00000000..98714b1a --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-bad-syntax-05.nq @@ -0,0 +1 @@ + <<( )>> . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-bad-syntax-06.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-bad-syntax-06.nq new file mode 100644 index 00000000..ab656182 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-bad-syntax-06.nq @@ -0,0 +1 @@ +<<( "XYZ" )>> . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-bad-syntax-07.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-bad-syntax-07.nq new file mode 100644 index 00000000..9d648c1b --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-bad-syntax-07.nq @@ -0,0 +1 @@ +<<( "XYZ" )>> . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-bad-syntax-08.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-bad-syntax-08.nq new file mode 100644 index 00000000..8dd3f7aa --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-bad-syntax-08.nq @@ -0,0 +1 @@ +<<( _:label )>> . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-bad-syntax-09.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-bad-syntax-09.nq new file mode 100644 index 00000000..79800c88 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-bad-syntax-09.nq @@ -0,0 +1 @@ + << >> . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-bad-syntax-10.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-bad-syntax-10.nq new file mode 100644 index 00000000..b13c6535 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-bad-syntax-10.nq @@ -0,0 +1 @@ +<<( )>> . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-bnode-1.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-bnode-1.nq new file mode 100644 index 00000000..e26d4978 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-bnode-1.nq @@ -0,0 +1,2 @@ +_:b0 . +_:b1 <<( _:b0 )>> . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-bnode-bad-annotated-syntax-1.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-bnode-bad-annotated-syntax-1.nq new file mode 100644 index 00000000..7d93058f --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-bnode-bad-annotated-syntax-1.nq @@ -0,0 +1 @@ +_:b0 {| "ABC" |} . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-bnode-bad-annotated-syntax-2.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-bnode-bad-annotated-syntax-2.nq new file mode 100644 index 00000000..8f6ad589 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-bnode-bad-annotated-syntax-2.nq @@ -0,0 +1 @@ + _:b1 {| "456"^^ |} . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-nested-1.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-nested-1.nq new file mode 100644 index 00000000..664ccb04 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-nested-1.nq @@ -0,0 +1,3 @@ + . + <<( )>> . + <<( <<( )>> )>> . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-nested-bad-annotated-syntax-1.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-nested-bad-annotated-syntax-1.nq new file mode 100644 index 00000000..659ac6f0 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-nested-bad-annotated-syntax-1.nq @@ -0,0 +1 @@ + {| {| "1"^^ |} |} . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-nested-bad-annotated-syntax-2.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-nested-bad-annotated-syntax-2.nq new file mode 100644 index 00000000..9ac5f5c1 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-nested-bad-annotated-syntax-2.nq @@ -0,0 +1,2 @@ + . + << >> {| |} . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-syntax-01.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-syntax-01.nq new file mode 100644 index 00000000..d4290bba --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-syntax-01.nq @@ -0,0 +1 @@ + <<( )>> . diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-syntax-02.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-syntax-02.nq new file mode 100644 index 00000000..5f5e08ed --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-syntax-02.nq @@ -0,0 +1 @@ +<<()>>. diff --git a/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-syntax-03.nq b/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-syntax-03.nq new file mode 100644 index 00000000..8d637f48 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-quads/syntax/nquads12-syntax-03.nq @@ -0,0 +1 @@ +<<(<<()>>)>>. \ No newline at end of file diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/README.md b/src/test/resources/w3c/rdf12/rdf-n-triples/README.md new file mode 100644 index 00000000..e6bf7df3 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/README.md @@ -0,0 +1,18 @@ +This README is for the W3C RDF & SPARQL Working Group's N-Triples test suite. +This test suite contains three kinds of tests: + +* Positive syntax (`rdft:TestNTriplesPositiveSyntax`) — an input N-Triples file with no syntax errors. +* Negative syntax (`rdft:TestNTriplesNegativeSyntax`) — an input N-Triples file with at least one syntax error. +* Positive canonicalization (`rdft:TestNTriplesPositiveC14N`) — an input N-Triples file with no syntax errors. + +The `manifest.ttl` files in this directory lists tests in the RDF-star WG's N-Triples test suite. +All tests have a name (`mf:name`) and an input (`mf:action`). + +* An implementation passes a positive syntax test if it parses the + input, and signals no errors or warnings. +* An implementation passes a negative syntax test if it fails to parse + the input, or signals an error or warning. +* An implementation passes a positive canonicalization test if it parses the + input, and generates the expected result (`mf:result`) compared as text when generating the canonical form of triples. + +The home of the test suite is . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/comment_following_triple-c14n.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/comment_following_triple-c14n.nt new file mode 100644 index 00000000..02e6ba98 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/comment_following_triple-c14n.nt @@ -0,0 +1 @@ + . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/comment_following_triple.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/comment_following_triple.nt new file mode 100644 index 00000000..179460b1 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/comment_following_triple.nt @@ -0,0 +1,2 @@ +# comment + . # comment diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/dirlangtagged_string-c14n.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/dirlangtagged_string-c14n.nt new file mode 100644 index 00000000..96c09f99 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/dirlangtagged_string-c14n.nt @@ -0,0 +1 @@ + "chat"@en-gb--ltr . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/dirlangtagged_string.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/dirlangtagged_string.nt new file mode 100644 index 00000000..8ec90b00 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/dirlangtagged_string.nt @@ -0,0 +1 @@ + "chat"@EN-GB--ltr . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/extra_whitespace-01-c14n.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/extra_whitespace-01-c14n.nt new file mode 100644 index 00000000..02e6ba98 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/extra_whitespace-01-c14n.nt @@ -0,0 +1 @@ + . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/extra_whitespace-01.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/extra_whitespace-01.nt new file mode 100644 index 00000000..2cce4ad4 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/extra_whitespace-01.nt @@ -0,0 +1 @@ + . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/extra_whitespace-02-c14n.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/extra_whitespace-02-c14n.nt new file mode 100644 index 00000000..637bb8dc --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/extra_whitespace-02-c14n.nt @@ -0,0 +1 @@ + "Alice" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/extra_whitespace-02.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/extra_whitespace-02.nt new file mode 100644 index 00000000..ee1ad4d4 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/extra_whitespace-02.nt @@ -0,0 +1 @@ + "Alice" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/extra_whitespace-03-c14n.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/extra_whitespace-03-c14n.nt new file mode 100644 index 00000000..ed4b9c33 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/extra_whitespace-03-c14n.nt @@ -0,0 +1 @@ + "Alice"@en . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/extra_whitespace-03.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/extra_whitespace-03.nt new file mode 100644 index 00000000..bc9a731e --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/extra_whitespace-03.nt @@ -0,0 +1 @@ + "Alice" @en . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/extra_whitespace-04-c14n.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/extra_whitespace-04-c14n.nt new file mode 100644 index 00000000..81d0f475 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/extra_whitespace-04-c14n.nt @@ -0,0 +1 @@ + "2"^^ . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/extra_whitespace-04.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/extra_whitespace-04.nt new file mode 100644 index 00000000..72d519ec --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/extra_whitespace-04.nt @@ -0,0 +1 @@ + "2" ^^ . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/langtagged_string-c14n.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/langtagged_string-c14n.nt new file mode 100644 index 00000000..1bddb04e --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/langtagged_string-c14n.nt @@ -0,0 +1 @@ + "chat"@en . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/langtagged_string.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/langtagged_string.nt new file mode 100644 index 00000000..5af3d52a --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/langtagged_string.nt @@ -0,0 +1 @@ + "chat"@EN . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_all_controls-c14n.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_all_controls-c14n.nt new file mode 100644 index 00000000..bbe29c9d --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_all_controls-c14n.nt @@ -0,0 +1 @@ + "\u0000\u0001\u0002\u0003\u0004\u0005\u0006\u0007\b\t\u000B\f\u000E\u000F\u0010\u0011\u0012\u0013\u0014\u0015\u0016\u0017\u0018\u0019\u001A\u001B\u001C\u001D\u001E\u001F" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_all_controls.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_all_controls.nt new file mode 100644 index 00000000..91c8af14 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_all_controls.nt @@ -0,0 +1 @@ + "\u0000\u0001\u0002\u0003\u0004\u0005\u0006\u0007\u0008\t\u000B\u000C\u000E\u000F\u0010\u0011\u0012\u0013\u0014\u0015\u0016\u0017\u0018\u0019\u001A\u001B\u001C\u001D\u001E\u001F" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_all_punctuation-c14n.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_all_punctuation-c14n.nt new file mode 100644 index 00000000..c25d818f --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_all_punctuation-c14n.nt @@ -0,0 +1 @@ + " !\"#$%&():;<=>?@[]^_`{|}~" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_all_punctuation.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_all_punctuation.nt new file mode 100644 index 00000000..c25d818f --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_all_punctuation.nt @@ -0,0 +1 @@ + " !\"#$%&():;<=>?@[]^_`{|}~" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_ascii_boundaries-c14n.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_ascii_boundaries-c14n.nt new file mode 100644 index 00000000..167d20e8 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_ascii_boundaries-c14n.nt @@ -0,0 +1 @@ + "\u0000\t\u000B\f\u000E&([]\u007F" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_ascii_boundaries.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_ascii_boundaries.nt new file mode 100644 index 0000000000000000000000000000000000000000..7a4dc71759f854392fcc6118c45153e0d5381d82 GIT binary patch literal 57 xcmcD?C@Cqh($`PaORY%EEyzjLFSb*#!4NF4Q&3{y "\u0000\u0001\u0002\u0003\u0004\u0005\u0006\u0007\u000B\u000E\u000F\u0010\u0011\u0012\u0013\u0014\u0015\u0016\u0017\u0018\u0019\u001A\u001B\u001C\u001D\u001E\u001F\u007F\uFFFE\uFFFF" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_needing_uchar_escaping-01.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_needing_uchar_escaping-01.nt new file mode 100644 index 0000000000000000000000000000000000000000..0ea74d65adc522235c8d74825637197dab7a38e0 GIT binary patch literal 81 zcmcD?C@Cqh($`PaORY%EEyzjLFSb*#!4NF4Q&3`HWMXDvWn<^&;};MV5*85^6PJ*b Vl9rK`ldpfjf8YE4`;`>*xB#uK70dtt literal 0 HcmV?d00001 diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_needing_uchar_escaping-02.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_needing_uchar_escaping-02.nt new file mode 100644 index 00000000..0eea5010 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_needing_uchar_escaping-02.nt @@ -0,0 +1,2 @@ + "\U00000000\U00000001\U00000002\U00000003\U00000004\U00000005\U00000006\U00000007\U0000000B\U0000000E\U0000000F\U00000010\U00000011\U00000012\U00000013\U00000014\U00000015\U00000016\U00000017\U00000018\U00000019\U0000001A\U0000001B\U0000001C\U0000001D\U0000001E\U0000001F\U0000007F\U0000FFFE\U0000FFFF" . +# 30 codepoints diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_2_dquotes-c14n.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_2_dquotes-c14n.nt new file mode 100644 index 00000000..3e69dc10 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_2_dquotes-c14n.nt @@ -0,0 +1 @@ + "x\"\"y" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_2_dquotes.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_2_dquotes.nt new file mode 100644 index 00000000..3e69dc10 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_2_dquotes.nt @@ -0,0 +1 @@ + "x\"\"y" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_2_squotes-c14n.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_2_squotes-c14n.nt new file mode 100644 index 00000000..8ddc52e8 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_2_squotes-c14n.nt @@ -0,0 +1 @@ + "x''y" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_2_squotes.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_2_squotes.nt new file mode 100644 index 00000000..8ddc52e8 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_2_squotes.nt @@ -0,0 +1 @@ + "x''y" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_BACKSPACE-c14n.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_BACKSPACE-c14n.nt new file mode 100644 index 00000000..339013df --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_BACKSPACE-c14n.nt @@ -0,0 +1 @@ + "\b" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_BACKSPACE.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_BACKSPACE.nt new file mode 100644 index 00000000..7dba113b --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_BACKSPACE.nt @@ -0,0 +1 @@ + "\u0008" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_CARRIAGE_RETURN-c14n.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_CARRIAGE_RETURN-c14n.nt new file mode 100644 index 00000000..91b85c89 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_CARRIAGE_RETURN-c14n.nt @@ -0,0 +1 @@ + "\r" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_CARRIAGE_RETURN.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_CARRIAGE_RETURN.nt new file mode 100644 index 00000000..93437ac5 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_CARRIAGE_RETURN.nt @@ -0,0 +1 @@ + "\u000D" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_CHARACTER_TABULATION-c14n.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_CHARACTER_TABULATION-c14n.nt new file mode 100644 index 00000000..a6a9d9f0 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_CHARACTER_TABULATION-c14n.nt @@ -0,0 +1 @@ + "\t" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_CHARACTER_TABULATION.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_CHARACTER_TABULATION.nt new file mode 100644 index 00000000..4cf48384 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_CHARACTER_TABULATION.nt @@ -0,0 +1 @@ + "\u0009" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_FORM_FEED-c14n.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_FORM_FEED-c14n.nt new file mode 100644 index 00000000..10d2c6d7 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_FORM_FEED-c14n.nt @@ -0,0 +1 @@ + "\f" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_FORM_FEED.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_FORM_FEED.nt new file mode 100644 index 00000000..151d6aa8 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_FORM_FEED.nt @@ -0,0 +1 @@ + "\u000c" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_LINE_FEED-c14n.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_LINE_FEED-c14n.nt new file mode 100644 index 00000000..462f97ac --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_LINE_FEED-c14n.nt @@ -0,0 +1 @@ + "\n" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_LINE_FEED.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_LINE_FEED.nt new file mode 100644 index 00000000..e4354e70 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_LINE_FEED.nt @@ -0,0 +1 @@ + "\u000a" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_REVERSE_SOLIDUS-c14n.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_REVERSE_SOLIDUS-c14n.nt new file mode 100644 index 00000000..ebc846ed --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_REVERSE_SOLIDUS-c14n.nt @@ -0,0 +1 @@ + "\\" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_REVERSE_SOLIDUS.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_REVERSE_SOLIDUS.nt new file mode 100644 index 00000000..13381211 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_REVERSE_SOLIDUS.nt @@ -0,0 +1 @@ + "\u005c" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_REVERSE_SOLIDUS2-c14n.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_REVERSE_SOLIDUS2-c14n.nt new file mode 100644 index 00000000..586e364d --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_REVERSE_SOLIDUS2-c14n.nt @@ -0,0 +1 @@ + "test-\\" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_REVERSE_SOLIDUS2.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_REVERSE_SOLIDUS2.nt new file mode 100644 index 00000000..586e364d --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_REVERSE_SOLIDUS2.nt @@ -0,0 +1 @@ + "test-\\" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_UTF8_boundaries-c14n.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_UTF8_boundaries-c14n.nt new file mode 100644 index 00000000..0e1616db --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_UTF8_boundaries-c14n.nt @@ -0,0 +1 @@ + "€߿ࠀ࿿က쿿퀀퟿�𐀀𿿽񀀀󿿽􀀀􏿽" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_UTF8_boundaries.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_UTF8_boundaries.nt new file mode 100644 index 00000000..0e1616db --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_UTF8_boundaries.nt @@ -0,0 +1 @@ + "€߿ࠀ࿿က쿿퀀퟿�𐀀𿿽񀀀󿿽􀀀􏿽" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_dquote-c14n.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_dquote-c14n.nt new file mode 100644 index 00000000..05a1fd3a --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_dquote-c14n.nt @@ -0,0 +1 @@ + "x\"y" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_dquote.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_dquote.nt new file mode 100644 index 00000000..42aec1ef --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_dquote.nt @@ -0,0 +1 @@ + "x\u0022y" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_extra_whitespace-c14n.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_extra_whitespace-c14n.nt new file mode 100644 index 00000000..05d9348f --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_extra_whitespace-c14n.nt @@ -0,0 +1 @@ + " a b c \n\n\t\t\r\r" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_extra_whitespace.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_extra_whitespace.nt new file mode 100644 index 00000000..05d9348f --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_extra_whitespace.nt @@ -0,0 +1 @@ + " a b c \n\n\t\t\r\r" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_numeric_escape4-c14n.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_numeric_escape4-c14n.nt new file mode 100644 index 00000000..3c957edd --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_numeric_escape4-c14n.nt @@ -0,0 +1,2 @@ + "o" . + "\u000E" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_numeric_escape4.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_numeric_escape4.nt new file mode 100644 index 00000000..f247c56f --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_numeric_escape4.nt @@ -0,0 +1,2 @@ + "\u006f" . + "\u000e" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_numeric_escape8-c14n.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_numeric_escape8-c14n.nt new file mode 100644 index 00000000..3c957edd --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_numeric_escape8-c14n.nt @@ -0,0 +1,2 @@ + "o" . + "\u000E" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_numeric_escape8.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_numeric_escape8.nt new file mode 100644 index 00000000..9cb4edca --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_numeric_escape8.nt @@ -0,0 +1,2 @@ + "\U0000006F" . + "\U0000000e" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_squote-c14n.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_squote-c14n.nt new file mode 100644 index 00000000..acf7f58f --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_squote-c14n.nt @@ -0,0 +1 @@ + "x'y" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_squote.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_squote.nt new file mode 100644 index 00000000..acf7f58f --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_squote.nt @@ -0,0 +1 @@ + "x'y" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_string_dt-c14n.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_string_dt-c14n.nt new file mode 100644 index 00000000..7d158ca1 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_string_dt-c14n.nt @@ -0,0 +1 @@ + "foo" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_string_dt.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_string_dt.nt new file mode 100644 index 00000000..c0d86cca --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/literal_with_string_dt.nt @@ -0,0 +1 @@ + "foo"^^ . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/manifest.ttl b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/manifest.ttl new file mode 100644 index 00000000..aa631d25 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/manifest.ttl @@ -0,0 +1,395 @@ +## Distributed under both the "W3C Test Suite License" [1] +## and the "W3C 3-clause BSD License". +## [1] https://www.w3.org/Consortium/Legal/2008/04-testsuite-license +## [2] https://www.w3.org/Consortium/Legal/2008/03-bsd-license +## +## Test types +## * rdft:TestNTriplesPositiveC14N – N-Triples canonicalization + +PREFIX : +PREFIX rdf: +PREFIX rdfs: +PREFIX mf: +PREFIX rdft: + +:manifest a mf:Manifest ; + rdfs:label "RDF 1.2 N-Triples Canonicalization Test Suite"@en; + rdfs:comment "Tests the generation of canonical N-Triples."@en; + mf:assumedTestBase ; + rdfs:seeAlso ; + mf:entries ( + :comment_following_triple + :extra_whitespace-01 + :extra_whitespace-02 + :extra_whitespace-03 + :extra_whitespace-04 + :langtagged_string + # :lantag_with_subtag + :dirlangtagged_string + :literal_all_controls + :literal_all_punctuation + :literal_ascii_boundaries + :literal_with_2_dquotes + :literal_with_2_squotes + :literal_with_BACKSPACE + :literal_with_CARRIAGE_RETURN + :literal_with_CHARACTER_TABULATION + :literal_with_dquote + :literal_with_FORM_FEED + :literal_with_LINE_FEED + :literal_with_numeric_escape4 + :literal_with_numeric_escape8 + :literal_with_REVERSE_SOLIDUS + :literal_with_REVERSE_SOLIDUS2 + :literal_with_squote + :literal_with_string_dt + :literal_with_extra_whitespace + :literal_with_UTF8_boundaries + :minimal_whitespace-01 + :minimal_whitespace-02 + :triple-term-01 + :triple-term-02 + :triple-term-03 + :triple-term-04 + :nt-syntax-uri-01 + :nt-syntax-uri-02 + :nt-syntax-uri-03 + :nt-syntax-uri-04 + :nt-syntax-str-esc-01 + :nt-syntax-str-esc-02 + :nt-syntax-str-esc-03 + :literal_needing_uchar_escaping-01 + :literal_needing_uchar_escaping-02 + ) . + +:comment_following_triple rdf:type rdft:TestNTriplesPositiveC14N ; + mf:name "C14N comment_following_triple" ; + rdfs:comment "Tests canonicalization of triples including comments" ; + rdft:approval rdft:Proposed ; + mf:action ; + mf:result ; + . + +:langtagged_string rdf:type rdft:TestNTriplesPositiveC14N ; + mf:name "C14N langtagged_string" ; + rdfs:comment "Tests canonicalization of triples including language-tagged string" ; + rdft:approval rdft:Proposed ; + mf:action ; + mf:result ; + . + +#:lantag_with_subtag rdf:type rdft:TestNTriplesPositiveC14N ; +# mf:name "C14N lantag_with_subtag" ; +# rdfs:comment "Tests canonicalization of triples including language-tagged string with subtag" ; +# rdft:approval rdft:Proposed ; +# mf:action ; +# mf:result ; +# . + +:dirlangtagged_string rdf:type rdft:TestNTriplesPositiveC14N ; + mf:name "C14N literal with base direction ltr" ; + rdfs:comment "Tests canonicalization of triples including directional language-tagged string" ; + rdft:approval rdft:Proposed ; + mf:action ; + mf:result ; + . + +:literal_all_controls rdf:type rdft:TestNTriplesPositiveC14N ; + mf:name "C14N literal_all_controls" ; + rdfs:comment "Tests canonicalization of literals with control characters" ; + rdft:approval rdft:Proposed ; + mf:action ; + mf:result ; + . + +:literal_all_punctuation rdf:type rdft:TestNTriplesPositiveC14N ; + mf:name "C14N literal_all_punctuation" ; + rdfs:comment "Tests canonicalization of literals with punctuation characters" ; + rdft:approval rdft:Proposed ; + mf:action ; + mf:result ; + . + +:literal_ascii_boundaries rdf:type rdft:TestNTriplesPositiveC14N ; + mf:name "C14N literal_ascii_boundaries" ; + rdfs:comment "Tests canonicalization of literal_ascii_boundaries '\\x00\\x26\\x28...'" ; + rdft:approval rdft:Proposed ; + mf:action ; + mf:result ; + . + +:literal_with_2_dquotes rdf:type rdft:TestNTriplesPositiveC14N ; + mf:name "C14N literal_with_2_dquotes" ; + rdfs:comment "Tests canonicalization of literal with 2 dquotes \"\"\"a\"\"b\"\"\"" ; + rdft:approval rdft:Proposed ; + mf:action ; + mf:result ; + . + +:literal_with_2_squotes rdf:type rdft:TestNTriplesPositiveC14N ; + mf:name "C14N literal_with_2_squotes" ; + rdfs:comment "Tests canonicalization of literal with 2 squotes \"x''y\"" ; + rdft:approval rdft:Proposed ; + mf:action ; + mf:result ; + . + +:literal_with_BACKSPACE rdf:type rdft:TestNTriplesPositiveC14N ; + mf:name "C14N literal_with_BACKSPACE" ; + rdfs:comment "Tests canonicalization of literals with backspace" ; + rdft:approval rdft:Proposed ; + mf:action ; + mf:result ; + . + +:literal_with_CARRIAGE_RETURN rdf:type rdft:TestNTriplesPositiveC14N ; + mf:name "C14N literal_with_CARRIAGE_RETURN" ; + rdfs:comment "Tests canonicalization of literals with carriage return" ; + rdft:approval rdft:Proposed ; + mf:action ; + mf:result ; + . + +:literal_with_CHARACTER_TABULATION rdf:type rdft:TestNTriplesPositiveC14N ; + mf:name "C14N literal_with_CHARACTER_TABULATION" ; + rdfs:comment "Tests canonicalization of literals with character tabulation" ; + rdft:approval rdft:Proposed ; + mf:action ; + mf:result ; + . + +:literal_with_dquote rdf:type rdft:TestNTriplesPositiveC14N ; + mf:name "C14N literal_with_dquote" ; + rdfs:comment "Tests canonicalization of literals with double quote" ; + rdft:approval rdft:Proposed ; + mf:action ; + mf:result ; + . + +:literal_with_FORM_FEED rdf:type rdft:TestNTriplesPositiveC14N ; + mf:name "C14N literal_with_FORM_FEED" ; + rdfs:comment "Tests canonicalization of literals with form feed" ; + rdft:approval rdft:Proposed ; + mf:action ; + mf:result ; + . + +:literal_with_LINE_FEED rdf:type rdft:TestNTriplesPositiveC14N ; + mf:name "C14N literal_with_LINE_FEED" ; + rdfs:comment "Tests canonicalization of literals with line feed" ; + rdft:approval rdft:Proposed ; + mf:action ; + mf:result ; + . + +:literal_with_numeric_escape4 rdf:type rdft:TestNTriplesPositiveC14N ; + mf:name "C14N literal_with_numeric_escape4" ; + rdfs:comment "Tests canonicalization of literals with numeric escapes" ; + rdft:approval rdft:Proposed ; + mf:action ; + mf:result ; + . + +:literal_with_numeric_escape8 rdf:type rdft:TestNTriplesPositiveC14N ; + mf:name "C14N literal_with_numeric_escape8" ; + rdfs:comment "Tests canonicalization of literals with numeric escapes" ; + rdft:approval rdft:Proposed ; + mf:action ; + mf:result ; + . + +:literal_with_REVERSE_SOLIDUS rdf:type rdft:TestNTriplesPositiveC14N ; + mf:name "C14N literal_with_REVERSE_SOLIDUS" ; + rdfs:comment "Tests canonicalization of literals with reverse solidus" ; + rdft:approval rdft:Proposed ; + mf:action ; + mf:result ; + . + +:literal_with_REVERSE_SOLIDUS2 rdf:type rdft:TestNTriplesPositiveC14N ; + mf:name "C14N literal_with_REVERSE_SOLIDUS2" ; + rdfs:comment "Tests canonicalization of literals with reverse solidus" ; + rdft:approval rdft:Proposed ; + mf:action ; + mf:result ; + . + +:literal_with_squote rdf:type rdft:TestNTriplesPositiveC14N ; + mf:name "C14N literal_with_squote" ; + rdfs:comment "Tests canonicalization of literals with single quotes" ; + rdft:approval rdft:Proposed ; + mf:action ; + mf:result ; + . + +:literal_with_string_dt rdf:type rdft:TestNTriplesPositiveC14N ; + mf:name "C14N literal_with_string_dt" ; + rdfs:comment "Tests canonicalization of literal with explicit xsd:string" ; + rdft:approval rdft:Proposed ; + mf:action ; + mf:result ; + . + +:literal_with_UTF8_boundaries rdf:type rdft:TestNTriplesPositiveC14N ; + mf:name "C14N literal_with_UTF8_boundaries" ; + rdfs:comment "Tests canonicalization of literals with UTF8 boundaries" ; + rdft:approval rdft:Proposed ; + mf:action ; + mf:result ; + . + +:literal_with_extra_whitespace rdf:type rdft:TestNTriplesPositiveC14N ; + mf:name "C14N literal_with_extra_whitespace" ; + rdfs:comment "Tests canonicalization of triples with literals having extra whitespace" ; + rdft:approval rdft:Proposed ; + mf:action ; + mf:result ; + . + +:minimal_whitespace-01 rdf:type rdft:TestNTriplesPositiveC14N ; + mf:name "C14N minimal_whitespace-01" ; + rdfs:comment "Tests canonicalization of triples without optional whitespace" ; + rdft:approval rdft:Proposed ; + mf:action ; + mf:result ; + . + +:minimal_whitespace-02 rdf:type rdft:TestNTriplesPositiveC14N ; + mf:name "C14N minimal_whitespace-02" ; + rdfs:comment "Tests canonicalization of triples without optional whitespace" ; + rdft:approval rdft:Proposed ; + mf:action ; + mf:result ; + . + +:extra_whitespace-01 rdf:type rdft:TestNTriplesPositiveC14N ; + mf:name "C14N extra_whitespace-01" ; + rdfs:comment "Tests canonicalization of triples with extra whitespace" ; + rdft:approval rdft:Proposed ; + mf:action ; + mf:result ; + . + +:extra_whitespace-02 rdf:type rdft:TestNTriplesPositiveC14N ; + mf:name "C14N extra_whitespace-02" ; + rdfs:comment "Tests canonicalization of triples with extra whitespace" ; + rdft:approval rdft:Proposed ; + mf:action ; + mf:result ; + . + +:extra_whitespace-03 rdf:type rdft:TestNTriplesPositiveC14N ; + mf:name "C14N extra_whitespace-03" ; + rdfs:comment "Tests canonicalization of triples with extra whitespace" ; + rdft:approval rdft:Proposed ; + mf:action ; + mf:result ; + . + +:extra_whitespace-04 rdf:type rdft:TestNTriplesPositiveC14N ; + mf:name "C14N extra_whitespace-04" ; + rdfs:comment "Tests canonicalization of triples with extra whitespace" ; + rdft:approval rdft:Proposed ; + mf:action ; + mf:result ; + . + +:triple-term-01 rdf:type rdft:TestNTriplesPositiveC14N ; + mf:name "C14N triple-term-01" ; + rdfs:comment "Tests canonicalization of triple terms with iri subject and object" ; + mf:action ; + mf:result ; + . + +:triple-term-02 rdf:type rdft:TestNTriplesPositiveC14N ; + mf:name "C14N triple-term-02" ; + rdfs:comment "Tests canonicalization of triple terms with iri subject and bnode object" ; + mf:action ; + mf:result ; + . + +:triple-term-03 rdf:type rdft:TestNTriplesPositiveC14N ; + mf:name "C14N triple-term-03" ; + rdfs:comment "Tests canonicalization of triple terms with iri subject and literal object" ; + mf:action ; + mf:result ; + . + +:triple-term-04 rdf:type rdft:TestNTriplesPositiveC14N ; + mf:name "C14N triple-term-04" ; + rdfs:comment "Tests canonicalization of triple terms with triple term object" ; + mf:action ; + mf:result ; + . + +:nt-syntax-uri-01 rdf:type rdft:TestNTriplesPositiveC14N ; + mf:name "C14N nt-syntax-uri-01" ; + rdfs:comment "Tests canonicalization of IRIs" ; + rdft:approval rdft:Proposed ; + mf:action ; + mf:result ; + . + +:nt-syntax-uri-02 rdf:type rdft:TestNTriplesPositiveC14N ; + mf:name "C14N nt-syntax-uri-02" ; + rdfs:comment "Tests canonicalization of IRIs" ; + rdft:approval rdft:Proposed ; + mf:action ; + mf:result ; + . + +:nt-syntax-uri-03 rdf:type rdft:TestNTriplesPositiveC14N ; + mf:name "C14N nt-syntax-uri-03" ; + rdfs:comment "Tests canonicalization of IRIs" ; + rdft:approval rdft:Proposed ; + mf:action ; + mf:result ; + . + +:nt-syntax-uri-04 rdf:type rdft:TestNTriplesPositiveC14N ; + mf:name "C14N nt-syntax-uri-04" ; + rdfs:comment "Tests canonicalization of IRIs" ; + rdft:approval rdft:Proposed ; + mf:action ; + mf:result ; + . + +:nt-syntax-str-esc-01 rdf:type rdft:TestNTriplesPositiveC14N ; + mf:name "C14N nt-syntax-str-esc-01" ; + rdfs:comment "Tests canonicalization of string escapes" ; + rdft:approval rdft:Proposed ; + mf:action ; + mf:result ; + . + +:nt-syntax-str-esc-02 rdf:type rdft:TestNTriplesPositiveC14N ; + mf:name "C14N nt-syntax-str-esc-02" ; + rdfs:comment "Tests canonicalization of string escapes" ; + rdft:approval rdft:Proposed ; + mf:action ; + mf:result ; + . + +:nt-syntax-str-esc-03 rdf:type rdft:TestNTriplesPositiveC14N ; + mf:name "C14N nt-syntax-str-esc-03" ; + rdfs:comment "Tests canonicalization of string escapes" ; + rdft:approval rdft:Proposed ; + mf:action ; + mf:result ; + . + +:literal_needing_uchar_escaping-01 rdf:type rdft:TestNTriplesPositiveC14N ; + mf:name "C14N literal_needing_uchar_escaping-01" ; + rdfs:comment "Tests canonicalization of strings with codepoints requiring UCHAR escaping, with input using raw UTF-8 data" ; + rdft:approval rdft:Proposed ; + mf:action ; + mf:result ; + . + +:literal_needing_uchar_escaping-02 rdf:type rdft:TestNTriplesPositiveC14N ; + mf:name "C14N literal_needing_uchar_escaping-02" ; + rdfs:comment "Tests canonicalization of strings with codepoints requiring UCHAR escaping, with input using \\U escaping" ; + rdft:approval rdft:Proposed ; + mf:action ; + mf:result ; + . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/minimal_whitespace-01-c14n.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/minimal_whitespace-01-c14n.nt new file mode 100644 index 00000000..02e6ba98 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/minimal_whitespace-01-c14n.nt @@ -0,0 +1 @@ + . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/minimal_whitespace-01.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/minimal_whitespace-01.nt new file mode 100644 index 00000000..9c706281 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/minimal_whitespace-01.nt @@ -0,0 +1 @@ +. \ No newline at end of file diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/minimal_whitespace-02-c14n.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/minimal_whitespace-02-c14n.nt new file mode 100644 index 00000000..637bb8dc --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/minimal_whitespace-02-c14n.nt @@ -0,0 +1 @@ + "Alice" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/minimal_whitespace-02.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/minimal_whitespace-02.nt new file mode 100644 index 00000000..2a63190a --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/minimal_whitespace-02.nt @@ -0,0 +1 @@ +"Alice". \ No newline at end of file diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/nt-syntax-str-esc-01-c14n.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/nt-syntax-str-esc-01-c14n.nt new file mode 100644 index 00000000..3925f2ec --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/nt-syntax-str-esc-01-c14n.nt @@ -0,0 +1 @@ + "a\n" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/nt-syntax-str-esc-01.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/nt-syntax-str-esc-01.nt new file mode 100644 index 00000000..3925f2ec --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/nt-syntax-str-esc-01.nt @@ -0,0 +1 @@ + "a\n" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/nt-syntax-str-esc-02-c14n.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/nt-syntax-str-esc-02-c14n.nt new file mode 100644 index 00000000..8a5a33fd --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/nt-syntax-str-esc-02-c14n.nt @@ -0,0 +1 @@ + "a b" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/nt-syntax-str-esc-02.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/nt-syntax-str-esc-02.nt new file mode 100644 index 00000000..e7d032f0 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/nt-syntax-str-esc-02.nt @@ -0,0 +1 @@ + "a\u0020b" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/nt-syntax-str-esc-03-c14n.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/nt-syntax-str-esc-03-c14n.nt new file mode 100644 index 00000000..8a5a33fd --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/nt-syntax-str-esc-03-c14n.nt @@ -0,0 +1 @@ + "a b" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/nt-syntax-str-esc-03.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/nt-syntax-str-esc-03.nt new file mode 100644 index 00000000..b8588c79 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/nt-syntax-str-esc-03.nt @@ -0,0 +1 @@ + "a\U00000020b" . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/nt-syntax-uri-01-c14n.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/nt-syntax-uri-01-c14n.nt new file mode 100644 index 00000000..02e6ba98 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/nt-syntax-uri-01-c14n.nt @@ -0,0 +1 @@ + . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/nt-syntax-uri-01.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/nt-syntax-uri-01.nt new file mode 100644 index 00000000..02e6ba98 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/nt-syntax-uri-01.nt @@ -0,0 +1 @@ + . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/nt-syntax-uri-02-c14n.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/nt-syntax-uri-02-c14n.nt new file mode 100644 index 00000000..944f25bc --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/nt-syntax-uri-02-c14n.nt @@ -0,0 +1 @@ + . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/nt-syntax-uri-02.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/nt-syntax-uri-02.nt new file mode 100644 index 00000000..664feea1 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/nt-syntax-uri-02.nt @@ -0,0 +1,2 @@ +# x53 is capital S + . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/nt-syntax-uri-03-c14n.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/nt-syntax-uri-03-c14n.nt new file mode 100644 index 00000000..944f25bc --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/nt-syntax-uri-03-c14n.nt @@ -0,0 +1 @@ + . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/nt-syntax-uri-03.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/nt-syntax-uri-03.nt new file mode 100644 index 00000000..b5aeb26e --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/nt-syntax-uri-03.nt @@ -0,0 +1,2 @@ +# x53 is capital S + . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/nt-syntax-uri-04-c14n.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/nt-syntax-uri-04-c14n.nt new file mode 100644 index 00000000..6f93b75a --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/nt-syntax-uri-04-c14n.nt @@ -0,0 +1 @@ + . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/nt-syntax-uri-04.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/nt-syntax-uri-04.nt new file mode 100644 index 00000000..49bacca7 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/nt-syntax-uri-04.nt @@ -0,0 +1,2 @@ +# IRI with all chars in it. + . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/triple-term-01-c14n.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/triple-term-01-c14n.nt new file mode 100644 index 00000000..2c488829 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/triple-term-01-c14n.nt @@ -0,0 +1 @@ + <<( )>> . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/triple-term-01.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/triple-term-01.nt new file mode 100644 index 00000000..9df6ba29 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/triple-term-01.nt @@ -0,0 +1 @@ + <<()>>. diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/triple-term-02-c14n.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/triple-term-02-c14n.nt new file mode 100644 index 00000000..b3764573 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/triple-term-02-c14n.nt @@ -0,0 +1 @@ + <<( _:o1 )>> . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/triple-term-02.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/triple-term-02.nt new file mode 100644 index 00000000..76ae8299 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/triple-term-02.nt @@ -0,0 +1 @@ + <<(_:o1)>>. diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/triple-term-03-c14n.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/triple-term-03-c14n.nt new file mode 100644 index 00000000..7f31a2bd --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/triple-term-03-c14n.nt @@ -0,0 +1 @@ + <<( "o1" )>> . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/triple-term-03.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/triple-term-03.nt new file mode 100644 index 00000000..eaf862c3 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/triple-term-03.nt @@ -0,0 +1 @@ + <<("o1")>>. diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/triple-term-04-c14n.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/triple-term-04-c14n.nt new file mode 100644 index 00000000..e2440431 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/triple-term-04-c14n.nt @@ -0,0 +1 @@ + <<( <<( "o2" )>> )>> . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/triple-term-04.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/triple-term-04.nt new file mode 100644 index 00000000..130e876c --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/c14n/triple-term-04.nt @@ -0,0 +1 @@ + <<(<<("o2")>>)>>. diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/manifest.ttl b/src/test/resources/w3c/rdf12/rdf-n-triples/manifest.ttl new file mode 100644 index 00000000..a0c9bf45 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/manifest.ttl @@ -0,0 +1,36 @@ +PREFIX rdf: +PREFIX rdfs: +PREFIX mf: +PREFIX rdft: +PREFIX trs: +PREFIX dct: +PREFIX xsd: +PREFIX foaf: +PREFIX skos: + +trs:manifest rdf:type mf:Manifest ; + rdfs:label "RDF 1.2 N-Triples tests"@en ; + skos:prefLabel "La suite des tests pour RDF 1.2 N-Triples"@fr; + skos:prefLabel "Conjunto de pruebas para RDF 1.2 N-Triples"@es; + dct:issued "2023-10-28"^^xsd:date ; + rdfs:seeAlso ; + mf:assumedTestBase ; + dct:modified "2023-10-28"^^xsd:date ; + dct:licence ; + dct:creator [ foaf:homepage ; foaf:name "W3C RDF & SPARQL Working Group" ] ; + rdfs:comment """ + These test suites are a product of the [W3C RDF & SPARQL Working Group](https://www.w3.org/groups/wg/rdf-star/) as well as the + RDF-Star Interest Group within the W3C RDF-DEV Community Group, + and has been maintained by the + [RDF Test Curation Community Group](https://www.w3.org/community/rdf-tests/) + at [https://github.com/w3c/rdf-tests/tree/main/rdf/rdf11](https://github.com/w3c/rdf-tests/tree/main/rdf/rdf11/). + + Conformance with RDF 1.2 specifications can be determined via successfully running the + tests for relevant specifications + along with the relevant RDF 1.1 tests. + """; + mf:include ( + + + <../../rdf11/rdf-n-triples/manifest.ttl> + ) . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/manifest.ttl b/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/manifest.ttl new file mode 100644 index 00000000..f62c6f26 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/manifest.ttl @@ -0,0 +1,220 @@ +## Distributed under both the "W3C Test Suite License" [1] +## and the "W3C 3-clause BSD License". +## [1] https://www.w3.org/Consortium/Legal/2008/04-testsuite-license +## [2] https://www.w3.org/Consortium/Legal/2008/03-bsd-license + +PREFIX rdf: +PREFIX rdfs: +PREFIX mf: +PREFIX rdft: +PREFIX trs: +PREFIX dct: +PREFIX xsd: +PREFIX foaf: +PREFIX skos: + +trs:manifest rdf:type mf:Manifest ; + rdfs:label "RDF 1.2 N-Triples Syntax Tests"@en ; + skos:prefLabel "La suite des tests pour RDF 1.2 N-Triples"@fr; + skos:prefLabel "Conjunto de pruebas para RDF 1.2 N-Triples"@es; + mf:assumedTestBase ; + dct:issued "2023-07-20"^^xsd:date ; + dct:modified "2023-07-20"^^xsd:date ; + dct:licence ; + dct:creator [ foaf:homepage ; foaf:name "W3C RDF & SPARQL Working Group" ] ; + rdfs:seeAlso ; + mf:entries + ( + trs:ntriples12-01 + trs:ntriples12-02 + trs:ntriples12-03 + + trs:ntriples12-bnode-1 + + trs:ntriples12-nested-1 + + trs:ntriples-langdir-1 + trs:ntriples-langdir-2 + + trs:ntriples12-bad-01 + trs:ntriples12-bad-02 + trs:ntriples12-bad-03 + trs:ntriples12-bad-04 + trs:ntriples12-bad-05 + trs:ntriples12-bad-06 + trs:ntriples12-bad-07 + trs:ntriples12-bad-08 + trs:ntriples12-bad-09 + trs:ntriples12-bad-10 + + trs:ntriples12-bad-iri-1 + + trs:ntriples12-bad-reified-1 + trs:ntriples12-bad-reified-2 + trs:ntriples12-bad-reified-3 + trs:ntriples12-bad-reified-4 + + trs:ntriples12-bnode-bad-annotated-syntax-1 + trs:ntriples12-bnode-bad-annotated-syntax-2 + + trs:ntriples-langdir-bad-1 + trs:ntriples-langdir-bad-2 + trs:ntriples-langdir-bad-3 + trs:ntriples-langdir-bad-4 + trs:ntriples-langdir-bad-5 + ) . + +trs:ntriples12-01 rdf:type rdft:TestNTriplesPositiveSyntax ; + mf:name "N-Triples-12 - object triple term" ; + mf:action ; + . + +trs:ntriples12-02 rdf:type rdft:TestNTriplesPositiveSyntax ; + mf:name "N-Triples-12 - object triple term, no whitespace" ; + mf:action ; + . + +trs:ntriples12-03 rdf:type rdft:TestNTriplesPositiveSyntax ; + mf:name "N-Triples-12 - Nested, no whitespace" ; + mf:action ; + . + +# Blank nodes + +trs:ntriples12-bnode-1 rdf:type rdft:TestNTriplesPositiveSyntax ; + mf:name "N-Triples-12 - Blank node subject" ; + mf:action ; + . + +trs:ntriples12-nested-1 rdf:type rdft:TestNTriplesPositiveSyntax ; + mf:name "N-Triples-12 - Nested object term" ; + mf:action ; + . + +# Base direction + +trs:ntriples-langdir-1 rdf:type rdft:TestNTriplesPositiveSyntax ; + mf:name "N-Triples literal with base direction ltr" ; + mf:action ; + . + +trs:ntriples-langdir-2 rdf:type rdft:TestNTriplesPositiveSyntax ; + mf:name "N-Triples literal with base direction rtl" ; + mf:action ; + . + +## Bad syntax + +trs:ntriples12-bad-01 rdf:type rdft:TestNTriplesNegativeSyntax ; + mf:name "N-Triples-12 - Bad - reified triple as predicate" ; + mf:action ; + . + +trs:ntriples12-bad-02 rdf:type rdft:TestNTriplesNegativeSyntax ; + mf:name "N-Triples-12 - Bad - reified triple, literal subject" ; + mf:action ; + . + +trs:ntriples12-bad-03 rdf:type rdft:TestNTriplesNegativeSyntax ; + mf:name "N-Triples-12 - Bad - reified triple, literal predicate" ; + mf:action ; + . + +trs:ntriples12-bad-04 rdf:type rdft:TestNTriplesNegativeSyntax ; + mf:name "N-Triples-12 - Bad - reified triple, blank node predicate" ; + mf:action ; + . + +trs:ntriples12-bad-05 rdf:type rdft:TestNTriplesNegativeSyntax ; + mf:name "N-Triples-12 - Bad - triple term as predicate" ; + mf:action ; + . + +trs:ntriples12-bad-06 rdf:type rdft:TestNTriplesNegativeSyntax ; + mf:name "N-Triples-12 - Bad - triple term, literal subject" ; + mf:action ; + . + +trs:ntriples12-bad-07 rdf:type rdft:TestNTriplesNegativeSyntax ; + mf:name "N-Triples-12 - Bad - triple term, literal predicate" ; + mf:action ; + . + +trs:ntriples12-bad-08 rdf:type rdft:TestNTriplesNegativeSyntax ; + mf:name "N-Triples-12 - Bad - triple term, blank node predicate" ; + mf:action ; + . + +trs:ntriples12-bad-09 rdf:type rdft:TestNTriplesNegativeSyntax ; + mf:name "N-Triples-12 - Bad - reified triple object" ; + mf:action ; + . + +trs:ntriples12-bad-10 rdf:type rdft:TestNTriplesNegativeSyntax ; + mf:name "N-Triples-12 - Bad - triple term as subject" ; + mf:action ; + . + +trs:ntriples12-bad-iri-1 rdf:type rdft:TestNTriplesNegativeSyntax ; + mf:name "N-Triples - Bad - invalid IRI" ; + mf:action ; + . + +trs:ntriples12-bad-reified-1 rdf:type rdft:TestNTriplesNegativeSyntax ; + mf:name "N-Triples-12 - Bad - subject reified triple" ; + mf:action ; + . + +trs:ntriples12-bad-reified-2 rdf:type rdft:TestNTriplesNegativeSyntax ; + mf:name "N-Triples-12 - Bad - object reified triple" ; + mf:action ; + . + +trs:ntriples12-bad-reified-3 rdf:type rdft:TestNTriplesNegativeSyntax ; + mf:name "N-Triples-12 - Bad - subject and object reified triples" ; + mf:action ; + . + +trs:ntriples12-bad-reified-4 rdf:type rdft:TestNTriplesNegativeSyntax ; + mf:name "N-Triples-12 - Bad - predicate reified triple" ; + mf:action ; + . + +# Annotation syntax is not permitted in nt + +trs:ntriples12-bnode-bad-annotated-syntax-1 rdf:type rdft:TestNTriplesNegativeSyntax ; + mf:name "N-Triples-12 - Bad - annotated triple, blank node subject" ; + mf:action ; + . + +trs:ntriples12-bnode-bad-annotated-syntax-2 rdf:type rdft:TestNTriplesNegativeSyntax ; + mf:name "N-Triples-12 - Bad - annotated triple, blank node object" ; + mf:action ; + . + +# Base direction + +trs:ntriples-langdir-bad-1 rdf:type rdft:TestNTriplesNegativeSyntax ; + mf:name "N-Triples literal- Bad - undefined base direction" ; + mf:action ; + . + +trs:ntriples-langdir-bad-2 rdf:type rdft:TestNTriplesNegativeSyntax ; + mf:name "N-Triples literal- Bad - upper case LTR" ; + mf:action ; + . + +trs:ntriples-langdir-bad-3 rdf:type rdft:TestNTriplesNegativeSyntax ; + mf:name "N-Triples - Bad - literal with missing language tag" ; + mf:action ; + . + +trs:ntriples-langdir-bad-4 rdf:type rdft:TestNTriplesNegativeSyntax ; + mf:name "N-Triples - Bad - literal with bad language tag" ; + mf:action ; + . + +trs:ntriples-langdir-bad-5 rdf:type rdft:TestNTriplesNegativeSyntax ; + mf:name "N-Triples - Bad - literal with missing language tag and direction" ; + mf:action ; + . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples-langdir-1.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples-langdir-1.nt new file mode 100644 index 00000000..a58e1092 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples-langdir-1.nt @@ -0,0 +1 @@ + "Hello"@en--ltr . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples-langdir-2.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples-langdir-2.nt new file mode 100644 index 00000000..fe4bc9d5 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples-langdir-2.nt @@ -0,0 +1 @@ + "Hello"@en--rtl . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples-langdir-bad-1.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples-langdir-bad-1.nt new file mode 100644 index 00000000..2c943ddc --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples-langdir-bad-1.nt @@ -0,0 +1 @@ + "Hello"@en--unk . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples-langdir-bad-2.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples-langdir-bad-2.nt new file mode 100644 index 00000000..16dc8be6 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples-langdir-bad-2.nt @@ -0,0 +1 @@ + "Hello"@en--LTR . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples-langdir-bad-3.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples-langdir-bad-3.nt new file mode 100644 index 00000000..982dff02 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples-langdir-bad-3.nt @@ -0,0 +1 @@ + "Hello"^^ . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples-langdir-bad-4.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples-langdir-bad-4.nt new file mode 100644 index 00000000..de2fdaf0 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples-langdir-bad-4.nt @@ -0,0 +1 @@ + "Hello"@cantbethislong . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples-langdir-bad-5.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples-langdir-bad-5.nt new file mode 100644 index 00000000..ca7c8928 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples-langdir-bad-5.nt @@ -0,0 +1 @@ + "Hello"^^ . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-bad-iri-1.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-bad-iri-1.nt new file mode 100644 index 00000000..8ee9f064 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-bad-iri-1.nt @@ -0,0 +1 @@ + . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-bad-reified-syntax-1.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-bad-reified-syntax-1.nt new file mode 100644 index 00000000..7f2be99c --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-bad-reified-syntax-1.nt @@ -0,0 +1 @@ +<< >> . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-bad-reified-syntax-2.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-bad-reified-syntax-2.nt new file mode 100644 index 00000000..5aa2cb20 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-bad-reified-syntax-2.nt @@ -0,0 +1 @@ + << >> . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-bad-reified-syntax-3.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-bad-reified-syntax-3.nt new file mode 100644 index 00000000..16b9420a --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-bad-reified-syntax-3.nt @@ -0,0 +1 @@ +<< >> << >> . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-bad-reified-syntax-4.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-bad-reified-syntax-4.nt new file mode 100644 index 00000000..6915b699 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-bad-reified-syntax-4.nt @@ -0,0 +1 @@ + << >> . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-bad-syntax-01.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-bad-syntax-01.nt new file mode 100644 index 00000000..3719b81a --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-bad-syntax-01.nt @@ -0,0 +1 @@ + <<( )>> . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-bad-syntax-02.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-bad-syntax-02.nt new file mode 100644 index 00000000..1a0f3592 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-bad-syntax-02.nt @@ -0,0 +1 @@ + <<( "XYZ" )>> . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-bad-syntax-03.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-bad-syntax-03.nt new file mode 100644 index 00000000..11f5f18d --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-bad-syntax-03.nt @@ -0,0 +1 @@ + <<( "XYZ" )>> . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-bad-syntax-04.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-bad-syntax-04.nt new file mode 100644 index 00000000..e83c9600 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-bad-syntax-04.nt @@ -0,0 +1 @@ + << _:label >> . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-bad-syntax-05.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-bad-syntax-05.nt new file mode 100644 index 00000000..bd43103f --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-bad-syntax-05.nt @@ -0,0 +1 @@ + <<( )>> . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-bad-syntax-06.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-bad-syntax-06.nt new file mode 100644 index 00000000..e11d54d8 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-bad-syntax-06.nt @@ -0,0 +1 @@ +<<( "XYZ" )>> . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-bad-syntax-07.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-bad-syntax-07.nt new file mode 100644 index 00000000..40b8f1bb --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-bad-syntax-07.nt @@ -0,0 +1 @@ +<<( "XYZ" )>> . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-bad-syntax-08.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-bad-syntax-08.nt new file mode 100644 index 00000000..d1047f93 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-bad-syntax-08.nt @@ -0,0 +1 @@ +<<( _:label )>> . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-bad-syntax-09.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-bad-syntax-09.nt new file mode 100644 index 00000000..390251f2 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-bad-syntax-09.nt @@ -0,0 +1 @@ + << >> . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-bad-syntax-10.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-bad-syntax-10.nt new file mode 100644 index 00000000..242d1825 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-bad-syntax-10.nt @@ -0,0 +1 @@ +<<( )>> . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-bnode-1.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-bnode-1.nt new file mode 100644 index 00000000..a5af9858 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-bnode-1.nt @@ -0,0 +1,2 @@ +_:b0 . +_:b1 <<( _:b0 )>> . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-bnode-bad-annotated-syntax-1.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-bnode-bad-annotated-syntax-1.nt new file mode 100644 index 00000000..598e8382 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-bnode-bad-annotated-syntax-1.nt @@ -0,0 +1 @@ +_:b0 {| "ABC" |} . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-bnode-bad-annotated-syntax-2.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-bnode-bad-annotated-syntax-2.nt new file mode 100644 index 00000000..28d51682 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-bnode-bad-annotated-syntax-2.nt @@ -0,0 +1 @@ + _:b1 {| "456"^^ |} . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-nested-1.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-nested-1.nt new file mode 100644 index 00000000..bd89c0db --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-nested-1.nt @@ -0,0 +1,3 @@ + . + <<( )>> . + <<( <<( )>> )>> . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-syntax-01.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-syntax-01.nt new file mode 100644 index 00000000..0dd45a2a --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-syntax-01.nt @@ -0,0 +1 @@ + <<( )>> . diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-syntax-02.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-syntax-02.nt new file mode 100644 index 00000000..90b85d63 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-syntax-02.nt @@ -0,0 +1 @@ +<<()>>. diff --git a/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-syntax-03.nt b/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-syntax-03.nt new file mode 100644 index 00000000..6825c6b2 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-n-triples/syntax/ntriples12-syntax-03.nt @@ -0,0 +1 @@ +<<(<<()>>)>>. \ No newline at end of file diff --git a/src/test/resources/w3c/rdf12/rdf-trig/README.md b/src/test/resources/w3c/rdf12/rdf-trig/README.md new file mode 100644 index 00000000..2c1aeda2 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/README.md @@ -0,0 +1,22 @@ +This README is for the W3C RDF & SPARQL Working Group's TrigG test suite. +This test suite contains three kinds of tests: + +* Positive evaluation (`rdft:TestTrigEval`) — a pair of an input TriG file and referenced N-Quads file.. +* Positive syntax (`rdft:TestTriGPositiveSyntax`) — an input TriG file with no syntax errors. +* Negative syntax (`rdft:TestTriGNegativeSyntax`) — an input TriG file with at least one syntax error. + +The `manifest.ttl` files in this directory lists tests in the RDF-star WG's TriG test suite. +All tests have a name (`mf:name`) and an input (`mf:action`). + +• An implementation passes an Evaluation test if it parses the input + into a dataset, parses the expected result into another dataset, and + those two dataset are isomorphic (see + ). +• An implementation passes an Negative Evaluation test if it parses the input + into a dataset, parses the expected result into another dataset, and + those two dataset are _not_ isomorphic (see + ). +* An implementation passes a positive syntax test if it parses the input. +* An implementation passes a negative syntax test if it fails to parse the input. + +The home of the test suite is . diff --git a/src/test/resources/w3c/rdf12/rdf-trig/eval/manifest.ttl b/src/test/resources/w3c/rdf12/rdf-trig/eval/manifest.ttl new file mode 100644 index 00000000..fd37082d --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/eval/manifest.ttl @@ -0,0 +1,204 @@ +## Distributed under both the "W3C Test Suite License" [1] +## and the "W3C 3-clause BSD License". +## [1] https://www.w3.org/Consortium/Legal/2008/04-testsuite-license +## [2] https://www.w3.org/Consortium/Legal/2008/03-bsd-license + +PREFIX rdf: +PREFIX rdfs: +PREFIX mf: +PREFIX test: +PREFIX rdft: +PREFIX trs: +PREFIX dct: +PREFIX xsd: +PREFIX foaf: +PREFIX skos: + +trs:manifest rdf:type mf:Manifest ; + rdfs:label "RDF 1.2 TriG Evaluation Tests"@en ; + skos:prefLabel "La suite des tests pour évaluation de RDF 1.2 TriG"@fr; + skos:prefLabel "Conjunto de pruebas para evaluar RDF 1.2 TriG"@es; + mf:assumedTestBase ; + dct:issued "2023-07-20"^^xsd:date ; + rdfs:seeAlso ; + dct:modified "2023-07-20"^^xsd:date ; + dct:licence ; + dct:creator [ foaf:homepage ; foaf:name "W3C RDF & SPARQL Working Group" ] ; + mf:entries + ( + trs:trig12-rt-01 + trs:trig12-rt-02 + trs:trig12-rt-03 + trs:trig12-rt-04 + trs:trig12-rt-05 + trs:trig12-rt-06 + trs:trig12-rt-07 + trs:trig12-rt-08 + trs:trig12-bnode-1 + trs:trig12-bnode-2 + trs:trig12-annotation-01 + trs:trig12-annotation-02 + trs:trig12-annotation-03 + trs:trig12-annotation-04 + trs:trig12-annotation-05 + trs:trig12-annotation-06 + trs:trig12-annotation-07 + trs:trig12-annotation-08 + trs:trig12-annotation-09 + trs:trig12-annotation-10 + trs:trig12-annotation-11 + trs:trig12-annotation-12 + trs:trig12-reified-triples-annotation-01 + trs:trig12-reified-triples-annotation-02 + trs:trig12-reified-triples-annotation-03 + ) . + +trs:trig12-rt-01 rdf:type rdft:TestTrigEval ; + mf:name "TriG 1.2 - subject reification" ; + mf:action ; + mf:result ; + . + +trs:trig12-rt-02 rdf:type rdft:TestTrigEval ; + mf:name "TriG 1.2 - object reification" ; + mf:action ; + mf:result ; + . + +trs:trig12-rt-03 rdf:type rdft:TestTrigEval ; + mf:name "TriG 1.2 - subject reification with identifier" ; + mf:action ; + mf:result ; + . + +trs:trig12-rt-04 rdf:type rdft:TestTrigEval ; + mf:name "TriG 1.2 - object reification with identifier" ; + mf:action ; + mf:result ; + . + +trs:trig12-rt-05 rdf:type rdft:TestTrigEval ; + mf:name "TriG 1.2 - subject reification with bnode identifier" ; + mf:action ; + mf:result ; + . + +trs:trig12-rt-06 rdf:type rdft:TestTrigEval ; + mf:name "TriG 1.2 - object reification with bnode identifier" ; + mf:action ; + mf:result ; + . + +trs:trig12-rt-07 rdf:type rdft:TestTrigEval ; + mf:name "TriG 1.2 - subject reification with empty identifier" ; + mf:action ; + mf:result ; + . + +trs:trig12-rt-08 rdf:type rdft:TestTrigEval ; + mf:name "TriG 1.2 - object reification with empty identifier" ; + mf:action ; + mf:result ; + . + +trs:trig12-bnode-1 rdf:type rdft:TestTrigEval ; + mf:name "TriG 1.2 - blank node label" ; + mf:action ; + mf:result ; + . + +trs:trig12-bnode-2 rdf:type rdft:TestTrigEval ; + mf:name "TriG 1.2 - blank node labels" ; + mf:action ; + mf:result ; + . + +trs:trig12-annotation-01 rdf:type rdft:TestTrigEval ; + mf:name "TriG 1.2 - Annotation form" ; + mf:action ; + mf:result ; + . + +trs:trig12-annotation-02 rdf:type rdft:TestTrigEval ; + mf:name "TriG 1.2 - Annotation example" ; + mf:action ; + mf:result ; + . + +trs:trig12-annotation-03 rdf:type rdft:TestTrigEval ; + mf:name "TriG 1.2 - Annotation - predicate and object lists" ; + mf:action ; + mf:result ; + . + +trs:trig12-annotation-04 rdf:type rdft:TestTrigEval ; + mf:name "TriG 1.2 - Annotation - nested" ; + mf:action ; + mf:result ; + . + +trs:trig12-annotation-05 rdf:type rdft:TestTrigEval ; + mf:name "TriG 1.2 - Annotation object list" ; + mf:action ; + mf:result ; + . + +trs:trig12-annotation-06 rdf:type rdft:TestTrigEval ; + mf:name "TriG 1.2 - Annotation with identifier" ; + mf:action ; + mf:result ; + . + +trs:trig12-annotation-07 rdf:type rdft:TestTrigEval ; + mf:name "TriG 1.2 - Different annotations have different default identifiers" ; + mf:action ; + mf:result ; + . + +trs:trig12-annotation-08 rdf:type rdft:TestTrigEval ; + mf:name "TriG 1.2 - Annotation form with explicit identifier" ; + mf:action ; + mf:result ; + . + +trs:trig12-annotation-09 rdf:type rdft:TestTrigEval ; + mf:name "TriG 1.2 - Annotation form with multiple reifiers" ; + mf:action ; + mf:result ; + . + +trs:trig12-annotation-10 rdf:type rdft:TestTrigEval ; + mf:name "TriG 1.2 - Annotation form with multiple annotation blocks" ; + mf:action ; + mf:result ; + . + +trs:trig12-annotation-11 rdf:type rdft:TestTrigEval ; + mf:name "TriG 1.2 - Annotation form with annotation block followed by reifier" ; + mf:action ; + mf:result ; + . + +trs:trig12-annotation-12 rdf:type rdft:TestTrigEval ; + mf:name "TriG 1.2 - Annotation form with alternating reifiers and annotation blocks" ; + mf:action ; + mf:result ; + . + +trs:trig12-reified-triples-annotation-01 rdf:type rdft:TestTrigEval ; + mf:name "TriG 1.2 - Annotation with reified triples" ; + mf:action ; + mf:result ; + . + +trs:trig12-reified-triples-annotation-02 rdf:type rdft:TestTrigEval ; + mf:name "TriG 1.2 - Annotation on triple with reified triple subject" ; + mf:action ; + mf:result ; + . + +trs:trig12-reified-triples-annotation-03 rdf:type rdft:TestTrigEval ; + mf:name "TriG 1.2 - Annotation on triple with reified triple object" ; + mf:action ; + mf:result ; + . diff --git a/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-01.nq b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-01.nq new file mode 100644 index 00000000..75481c24 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-01.nq @@ -0,0 +1,3 @@ + . +_:anon . +_:anon <<( )>> . diff --git a/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-01.trig b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-01.trig new file mode 100644 index 00000000..9364a9cf --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-01.trig @@ -0,0 +1,3 @@ +PREFIX : + +:G {:s :p :o {| :r :z |} .} diff --git a/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-02.nq b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-02.nq new file mode 100644 index 00000000..ca61d257 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-02.nq @@ -0,0 +1,8 @@ + . +_:anon <<( )>> . +_:anon _:bpl0 . +_:anon _:bpl1 . +_:bpl0 . +_:bpl0 "2020-01-20"^^ . +_:bpl1 . +_:bpl1 "2020-12-31"^^ . diff --git a/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-02.trig b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-02.trig new file mode 100644 index 00000000..0dc1e05f --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-02.trig @@ -0,0 +1,12 @@ +PREFIX : +PREFIX xsd: + +:G { + :s :p :o {| :source [ :graph ; + :date "2020-01-20"^^xsd:date + ] ; + :source [ :graph ; + :date "2020-12-31"^^xsd:date + ] + |} . +} diff --git a/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-03.nq b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-03.nq new file mode 100644 index 00000000..fc7e008a --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-03.nq @@ -0,0 +1,9 @@ + . + . + . +_:a0 <<( )>> . +_:a0 . +_:a1 <<( )>> . +_:a1 . +_:a2 <<( )>> . +_:a2 . diff --git a/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-03.trig b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-03.trig new file mode 100644 index 00000000..336c745e --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-03.trig @@ -0,0 +1,7 @@ +PREFIX : + +:G { + :s :p :o {| :a :b |}; + :p2 :o2 {| :a2 :b2 |}, + :o3 {| :a3 :b3 |}. +} diff --git a/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-04.nq b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-04.nq new file mode 100644 index 00000000..cd00c10d --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-04.nq @@ -0,0 +1,5 @@ + . +_:a0 <<( )>> . +_:a0 . +_:a1 <<(_:a0 )>> . +_:a1 . diff --git a/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-04.trig b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-04.trig new file mode 100644 index 00000000..d6d83da3 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-04.trig @@ -0,0 +1,3 @@ +PREFIX : + +:G {:s :p :o {| :a :b {| :a2 :b2 |} |}.} diff --git a/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-05.nq b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-05.nq new file mode 100644 index 00000000..0598b606 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-05.nq @@ -0,0 +1,4 @@ + . + . +_:anon <<( )>> . +_:anon . diff --git a/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-05.trig b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-05.trig new file mode 100644 index 00000000..59d83040 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-05.trig @@ -0,0 +1,4 @@ +PREFIX : + +:G {:s :p :o1, :o2 {| :a :b |} .} + diff --git a/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-06.nq b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-06.nq new file mode 100644 index 00000000..1409af42 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-06.nq @@ -0,0 +1,3 @@ + . + . + <<( )>> . diff --git a/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-06.trig b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-06.trig new file mode 100644 index 00000000..e43d6f7f --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-06.trig @@ -0,0 +1,3 @@ +PREFIX : + +:G {:s :p :o ~ :i {| :r :z |} .} diff --git a/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-07.nq b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-07.nq new file mode 100644 index 00000000..1f549dc5 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-07.nq @@ -0,0 +1,5 @@ + . +_:anno1 <<( )>> . +_:anno1 . +_:anno2 <<( )>> . +_:anno2 . diff --git a/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-07.trig b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-07.trig new file mode 100644 index 00000000..95f42eab --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-07.trig @@ -0,0 +1,6 @@ +PREFIX : + +:G { + :s :p :o {|:r :s |} . + :s :p :o {|:t :u |} . +} \ No newline at end of file diff --git a/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-08.nq b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-08.nq new file mode 100644 index 00000000..1409af42 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-08.nq @@ -0,0 +1,3 @@ + . + . + <<( )>> . diff --git a/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-08.trig b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-08.trig new file mode 100644 index 00000000..e43d6f7f --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-08.trig @@ -0,0 +1,3 @@ +PREFIX : + +:G {:s :p :o ~ :i {| :r :z |} .} diff --git a/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-09.nq b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-09.nq new file mode 100644 index 00000000..4f977e5a --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-09.nq @@ -0,0 +1,4 @@ + . + <<( )>> . + <<( )>> . + . diff --git a/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-09.trig b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-09.trig new file mode 100644 index 00000000..d7404293 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-09.trig @@ -0,0 +1,3 @@ +PREFIX : + +:G {:s :p :o ~ :i1 ~:i2 {| :r :z |} .} diff --git a/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-10.nq b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-10.nq new file mode 100644 index 00000000..b0faeec2 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-10.nq @@ -0,0 +1,5 @@ + . +_:b1 <<( )>> . +_:b1 . +_:b2 <<( )>> . +_:b2 . diff --git a/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-10.trig b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-10.trig new file mode 100644 index 00000000..d821e650 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-10.trig @@ -0,0 +1,3 @@ +PREFIX : + +:G {:s :p :o {| :r1 :z1 |} {| :r2 :z2 |} .} diff --git a/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-11.nq b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-11.nq new file mode 100644 index 00000000..949b3943 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-11.nq @@ -0,0 +1,4 @@ + . +_:b0 <<( )>> . +_:b0 . + <<( )>> . diff --git a/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-11.trig b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-11.trig new file mode 100644 index 00000000..fd27f545 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-11.trig @@ -0,0 +1,3 @@ +PREFIX : + +:G {:s :p :o {| :r :z |} ~ :i .} diff --git a/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-12.nq b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-12.nq new file mode 100644 index 00000000..7f08e6a2 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-12.nq @@ -0,0 +1,5 @@ + . + <<( )>> . + . + <<( )>> . + . diff --git a/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-12.trig b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-12.trig new file mode 100644 index 00000000..b7fc02f1 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-annotation-12.trig @@ -0,0 +1,3 @@ +PREFIX : + +:s :p :o ~ :i1 {| :r1 :z1 |} ~ :i2 {| :r2 :z2 |}. diff --git a/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-bnode-1.nq b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-bnode-1.nq new file mode 100644 index 00000000..dd54ff54 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-bnode-1.nq @@ -0,0 +1,3 @@ +_:b9 . +_:anon . +_:anon <<( _:b9 )>> . diff --git a/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-bnode-1.trig b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-bnode-1.trig new file mode 100644 index 00000000..1ddce6d7 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-bnode-1.trig @@ -0,0 +1,6 @@ +PREFIX : + +:G { + _:b :p :o . + <<_:b :p :o>> :q :z . +} diff --git a/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-bnode-2.nq b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-bnode-2.nq new file mode 100644 index 00000000..6c2c7c69 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-bnode-2.nq @@ -0,0 +1,4 @@ +_:label1 _:label1 . +_:a0 <<(_:label1 _:label1)>> . +_:a0 _:a1 . +_:a1 <<(_:label1 )>> . diff --git a/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-bnode-2.trig b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-bnode-2.trig new file mode 100644 index 00000000..3d2cb2a0 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-bnode-2.trig @@ -0,0 +1,6 @@ +PREFIX : + +:G { + _:a :p1 _:a . + <<_:a :p1 _:a >> :q <<_:a :p2 :o>> . +} diff --git a/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-reified-triples-annotation-01.nq b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-reified-triples-annotation-01.nq new file mode 100644 index 00000000..b475c5ae --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-reified-triples-annotation-01.nq @@ -0,0 +1,4 @@ + . +_:a0 <<( )>> . +_:a0 _:a1 . +_:a1 <<( )>> . diff --git a/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-reified-triples-annotation-01.trig b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-reified-triples-annotation-01.trig new file mode 100644 index 00000000..a56b8409 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-reified-triples-annotation-01.trig @@ -0,0 +1,3 @@ +PREFIX : + +:G {:s :p :o {| :r <<:s1 :p1 :o1>> |} .} diff --git a/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-reified-triples-annotation-02.nq b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-reified-triples-annotation-02.nq new file mode 100644 index 00000000..e6907c02 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-reified-triples-annotation-02.nq @@ -0,0 +1,4 @@ +_:a0 <<( )>> . +_:a0 . +_:a1 <<(_:a0 )>> . +_:a1 . diff --git a/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-reified-triples-annotation-02.trig b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-reified-triples-annotation-02.trig new file mode 100644 index 00000000..ed4dec93 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-reified-triples-annotation-02.trig @@ -0,0 +1,3 @@ +PREFIX : + +:G {<<:s1 :p1 :o1>> :p :o {| :r :z |} .} diff --git a/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-reified-triples-annotation-03.nq b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-reified-triples-annotation-03.nq new file mode 100644 index 00000000..40ab6d72 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-reified-triples-annotation-03.nq @@ -0,0 +1,4 @@ +_:a0 <<( )>> . + _:a0 . +_:a1 <<( _:a0)>> . +_:a1 . diff --git a/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-reified-triples-annotation-03.trig b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-reified-triples-annotation-03.trig new file mode 100644 index 00000000..5b100673 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-reified-triples-annotation-03.trig @@ -0,0 +1,3 @@ +PREFIX : + +:G {:s :p <<:s2 :p2 :o2>> {| :r :z |} .} diff --git a/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-rt-01.nq b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-rt-01.nq new file mode 100644 index 00000000..82b42c5f --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-rt-01.nq @@ -0,0 +1,2 @@ +_:anon . +_:anon <<( )>> . diff --git a/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-rt-01.trig b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-rt-01.trig new file mode 100644 index 00000000..924f2c82 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-rt-01.trig @@ -0,0 +1,3 @@ +PREFIX : + +:G {<<:s :p :o>> :q :z .} diff --git a/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-rt-02.nq b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-rt-02.nq new file mode 100644 index 00000000..f459690a --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-rt-02.nq @@ -0,0 +1,2 @@ + _:anon . +_:anon <<( )>> . diff --git a/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-rt-02.trig b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-rt-02.trig new file mode 100644 index 00000000..eb460dd2 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-rt-02.trig @@ -0,0 +1,3 @@ +PREFIX : + +:G {:a :q <<:s :p :o>> .} diff --git a/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-rt-03.nq b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-rt-03.nq new file mode 100644 index 00000000..50e856b6 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-rt-03.nq @@ -0,0 +1,2 @@ + . + <<( )>> . diff --git a/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-rt-03.trig b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-rt-03.trig new file mode 100644 index 00000000..384a7be1 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-rt-03.trig @@ -0,0 +1,3 @@ +PREFIX : + +:G {<< :s :p :o ~ :i >> :q :z .} diff --git a/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-rt-04.nq b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-rt-04.nq new file mode 100644 index 00000000..72a80300 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-rt-04.nq @@ -0,0 +1,2 @@ + . + <<( )>> . diff --git a/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-rt-04.trig b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-rt-04.trig new file mode 100644 index 00000000..80f1e4a3 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-rt-04.trig @@ -0,0 +1,3 @@ +PREFIX : + +:a :q << :s :p :o ~ :i >> . diff --git a/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-rt-05.nq b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-rt-05.nq new file mode 100644 index 00000000..b12373a2 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-rt-05.nq @@ -0,0 +1,2 @@ +_:i . +_:i <<( )>> . diff --git a/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-rt-05.trig b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-rt-05.trig new file mode 100644 index 00000000..10b4d57f --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-rt-05.trig @@ -0,0 +1,3 @@ +PREFIX : + +<< :s :p :o ~ _:i >> :q :z . diff --git a/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-rt-06.nq b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-rt-06.nq new file mode 100644 index 00000000..a3346be3 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-rt-06.nq @@ -0,0 +1,2 @@ + _:i . +_:i <<( )>> . diff --git a/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-rt-06.trig b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-rt-06.trig new file mode 100644 index 00000000..4237f9a6 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-rt-06.trig @@ -0,0 +1,3 @@ +PREFIX : + +:a :q << :s :p :o ~ _:i >> . diff --git a/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-rt-07.nq b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-rt-07.nq new file mode 100644 index 00000000..e793deef --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-rt-07.nq @@ -0,0 +1,2 @@ +_:bn . +_:bn <<( )>> . diff --git a/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-rt-07.trig b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-rt-07.trig new file mode 100644 index 00000000..a6bb344e --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-rt-07.trig @@ -0,0 +1,3 @@ +PREFIX : + +<< :s :p :o ~ >> :q :z . diff --git a/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-rt-08.nq b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-rt-08.nq new file mode 100644 index 00000000..64a1ade9 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-rt-08.nq @@ -0,0 +1,2 @@ + _:bn . +_:bn <<( )>> . diff --git a/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-rt-08.trig b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-rt-08.trig new file mode 100644 index 00000000..342c7f3b --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/eval/trig12-eval-rt-08.trig @@ -0,0 +1,3 @@ +PREFIX : + +:a :q << :s :p :o ~ >> . diff --git a/src/test/resources/w3c/rdf12/rdf-trig/manifest.ttl b/src/test/resources/w3c/rdf12/rdf-trig/manifest.ttl new file mode 100644 index 00000000..7a97f55e --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/manifest.ttl @@ -0,0 +1,36 @@ +PREFIX rdf: +PREFIX rdfs: +PREFIX mf: +PREFIX rdft: +PREFIX trs: +PREFIX dct: +PREFIX xsd: +PREFIX foaf: +PREFIX skos: + +trs:manifest rdf:type mf:Manifest ; + rdfs:label "RDF 1.2 TriG tests"@en ; + skos:prefLabel "La suite des tests pour RDF 1.2 TriG"@fr; + skos:prefLabel "Conjunto de pruebas para RDF 1.2 TriG"@es; + mf:assumedTestBase ; + dct:issued "2023-10-28"^^xsd:date ; + rdfs:seeAlso ; + dct:modified "2023-10-28"^^xsd:date ; + dct:licence ; + dct:creator [ foaf:homepage ; foaf:name "W3C RDF & SPARQL Working Group" ] ; + rdfs:comment """ + These test suites are a product of the [W3C RDF & SPARQL Working Group](https://www.w3.org/groups/wg/rdf-star/) as well as the + RDF-Star Interest Group within the W3C RDF-DEV Community Group, + and has been maintained by the + [RDF Test Curation Community Group](https://www.w3.org/community/rdf-tests/) + at [https://github.com/w3c/rdf-tests/tree/main/rdf/rdf11](https://github.com/w3c/rdf-tests/tree/main/rdf/rdf11/). + + Conformance with RDF 1.2 specifications can be determined via successfully running the + tests for relevant specifications + along with the relevant RDF 1.1 tests. + """; + mf:include ( + + + <../../rdf11/rdf-trig/manifest.ttl> + ) . diff --git a/src/test/resources/w3c/rdf12/rdf-trig/syntax/manifest.ttl b/src/test/resources/w3c/rdf12/rdf-trig/syntax/manifest.ttl new file mode 100644 index 00000000..046e4163 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/syntax/manifest.ttl @@ -0,0 +1,259 @@ +## Distributed under both the "W3C Test Suite License" [1] +## and the "W3C 3-clause BSD License". +## [1] https://www.w3.org/Consortium/Legal/2008/04-testsuite-license +## [2] https://www.w3.org/Consortium/Legal/2008/03-bsd-license + +PREFIX rdf: +PREFIX rdfs: +PREFIX mf: +PREFIX rdft: +PREFIX trs: +PREFIX dct: +PREFIX xsd: +PREFIX foaf: +PREFIX skos: + +trs:manifest rdf:type mf:Manifest ; + rdfs:label "RDF 1.2 TriG Syntax Tests"@en ; + skos:prefLabel "La suite des tests pour la syntaxe de RDF 1.2 TriG"@fr ; + skos:prefLabel "Conjunto de pruebas para la sintaxis de RDF 1.2 TriG"@es ; + mf:assumedTestBase ; + dct:issued "2023-07-20"^^xsd:date ; + rdfs:seeAlso ; + dct:modified "2023-07-20"^^xsd:date ; + dct:licence ; + dct:creator [ foaf:homepage ; foaf:name "W3C RDF & SPARQL Working Group" ] ; + mf:entries + ( + trs:trig12-1 + trs:trig12-2 + trs:trig12-3 + trs:trig12-4 + + trs:trig12-inside-1 + trs:trig12-inside-2 + trs:trig12-inside-3 + trs:trig12-inside-4 + + trs:trig12-nested-1 + trs:trig12-nested-2 + + trs:trig12-compound-1 + + trs:trig12-bnode-1 + trs:trig12-bnode-2 + trs:trig12-bnode-3 + + trs:trig12-bad-1 + trs:trig12-bad-2 + trs:trig12-bad-3 + trs:trig12-bad-4 + trs:trig12-bad-5 + trs:trig12-bad-6 + trs:trig12-bad-7 + + trs:trig12-ann-1 + trs:trig12-ann-2 + trs:trig12-ann-3 + trs:trig12-ann-4 + trs:trig12-ann-5 + trs:trig12-ann-6 + trs:trig12-ann-7 + trs:trig12-ann-8 + + trs:trig12-bad-ann-1 + trs:trig12-bad-ann-2 + +## Base direction + + trs:trig12-base-1 + trs:trig12-base-2 + + trs:trig12-base-bad-1 + trs:trig12-base-bad-2 + ) . + +## Good Syntax + +trs:trig12-1 rdf:type rdft:TestTrigPositiveSyntax ; + mf:name "TriG 1.2 - subject reified triple" ; + mf:action ; + . + +trs:trig12-2 rdf:type rdft:TestTrigPositiveSyntax ; + mf:name "TriG 1.2 - object reified triple" ; + mf:action ; + . + +trs:trig12-3 rdf:type rdft:TestTrigPositiveSyntax ; + mf:name "TriG 1.2 - triple term object" ; + mf:action ; + . + +trs:trig12-4 rdf:type rdft:TestTrigPositiveSyntax ; + mf:name "TriG 1.2 - reified triple outside triple" ; + mf:action ; + . + +trs:trig12-inside-1 rdf:type rdft:TestTrigPositiveSyntax ; + mf:name "TriG 1.2 - reified triple inside blankNodePropertyList" ; + mf:action ; + . + +trs:trig12-inside-2 rdf:type rdft:TestTrigPositiveSyntax ; + mf:name "TriG 1.2 - reified triple inside collection" ; + mf:action ; + . + +trs:trig12-inside-3 rdf:type rdft:TestTrigPositiveSyntax ; + mf:name "TriG 1.2 - reified triple with IRI identifier" ; + mf:action ; + . + +trs:trig12-inside-4 rdf:type rdft:TestTrigPositiveSyntax ; + mf:name "TriG 1.2 - reified triple with blank node identifier" ; + mf:action ; + . + +trs:trig12-nested-1 rdf:type rdft:TestTrigPositiveSyntax ; + mf:name "TriG 1.2 - nested quoted triple, subject position" ; + mf:action ; + . + +trs:trig12-nested-2 rdf:type rdft:TestTrigPositiveSyntax ; + mf:name "TriG 1.2 - nested quoted triple, object position" ; + mf:action ; + . + +trs:trig12-compound-1 rdf:type rdft:TestTrigPositiveSyntax ; + mf:name "TriG 1.2 - compound forms" ; + mf:action ; + . + +trs:trig12-bnode-1 rdf:type rdft:TestTrigPositiveSyntax ; + mf:name "TriG 1.2 - blank node subject" ; + mf:action ; + . + +trs:trig12-bnode-2 rdf:type rdft:TestTrigPositiveSyntax ; + mf:name "TriG 1.2 - blank node object" ; + mf:action ; + . + +trs:trig12-bnode-3 rdf:type rdft:TestTrigPositiveSyntax ; + mf:name "TriG 1.2 - blank node" ; + mf:action ; + . + +## Bad Syntax + +trs:trig12-bad-1 rdf:type rdft:TestTrigNegativeSyntax ; + mf:name "TriG 1.2 - bad - reified triple as predicate" ; + mf:action ; + . + +trs:trig12-bad-2 rdf:type rdft:TestTrigNegativeSyntax ; + mf:name "TriG 1.2 - bad - literal in subject position of reified triple" ; + mf:action ; + . + +trs:trig12-bad-3 rdf:type rdft:TestTrigNegativeSyntax ; + mf:name "TriG 1.2 - bad - blank node as predicate in reified triple" ; + mf:action ; + . + +trs:trig12-bad-4 rdf:type rdft:TestTrigNegativeSyntax ; + mf:name "TriG 1.2 - bad - incomplete reified triple" ; + mf:action ; + . + +trs:trig12-bad-5 rdf:type rdft:TestTrigNegativeSyntax ; + mf:name "TriG 1.2 - bad - over-long reified triple"; + mf:action ; + . + +trs:trig12-bad-6 rdf:type rdft:TestTrigNegativeSyntax ; + mf:name "TriG 1.2 - bad - reified with list object"; + mf:action ; + . + +trs:trig12-bad-7 rdf:type rdft:TestTrigNegativeSyntax ; + mf:name "TriG 1.2 - bad - compound blank node expression"; + mf:action ; + . + +## Annotation syntax + +trs:trig12-ann-1 rdf:type rdft:TestTrigPositiveSyntax ; + mf:name "TriG 1.2 - Annotation form" ; + mf:action ; + . + +trs:trig12-ann-2 rdf:type rdft:TestTrigPositiveSyntax ; + mf:name "TriG 1.2 - Annotation example" ; + mf:action ; + . + +trs:trig12-ann-3 rdf:type rdft:TestTrigPositiveSyntax ; + mf:name "TriG 1.2 - Annotation predicateObjecetList" ; + mf:action ; + . + +trs:trig12-ann-4 rdf:type rdft:TestTrigPositiveSyntax ; + mf:name "TriG 1.2 - Annotation followed by predicate/object" ; + mf:action ; + . + +trs:trig12-ann-5 rdf:type rdft:TestTrigPositiveSyntax ; + mf:name "TriG 1.2 - Reifier without annotation block" ; + mf:action ; + . + +trs:trig12-ann-6 rdf:type rdft:TestTrigPositiveSyntax ; + mf:name "TriG 1.2 - Empty reifier without annotation block" ; + mf:action ; + . + +trs:trig12-ann-7 rdf:type rdft:TestTrigPositiveSyntax ; + mf:name "TriG 1.2 - Reifier with annotation block" ; + mf:action ; + . + +trs:trig12-ann-8 rdf:type rdft:TestTrigPositiveSyntax ; + mf:name "TriG 1.2 - Empty reifier with annotation block" ; + mf:action ; + . + +## Bad annotation syntax + +trs:trig12-bad-ann-1 rdf:type rdft:TestTrigNegativeSyntax ; + mf:name "TriG 1.2 - bad - empty annotation" ; + mf:action ; + . + +trs:trig12-bad-ann-2 rdf:type rdft:TestTrigNegativeSyntax ; + mf:name "TriG 1.2 - bad - triple as annotation" ; + mf:action ; + . + +## Base direction + +trs:trig12-base-1 rdf:type rdft:TestTrigPositiveSyntax ; + mf:name "base direction ltr" ; + mf:action ; + . + +trs:trig12-base-2 rdf:type rdft:TestTrigPositiveSyntax ; + mf:name "base direction ltr" ; + mf:action ; + . + +trs:trig12-base-bad-1 rdf:type rdft:TestTrigNegativeSyntax ; + mf:name "undefined base direction" ; + mf:action ; + . + +trs:trig12-base-bad-2 rdf:type rdft:TestTrigNegativeSyntax ; + mf:name "upper case LTR" ; + mf:action ; + . diff --git a/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-annotation-1.trig b/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-annotation-1.trig new file mode 100644 index 00000000..888c8519 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-annotation-1.trig @@ -0,0 +1,3 @@ +PREFIX : + +:G {:s :p :o {| :r :z |} } diff --git a/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-annotation-2.trig b/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-annotation-2.trig new file mode 100644 index 00000000..0dc1e05f --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-annotation-2.trig @@ -0,0 +1,12 @@ +PREFIX : +PREFIX xsd: + +:G { + :s :p :o {| :source [ :graph ; + :date "2020-01-20"^^xsd:date + ] ; + :source [ :graph ; + :date "2020-12-31"^^xsd:date + ] + |} . +} diff --git a/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-annotation-3.trig b/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-annotation-3.trig new file mode 100644 index 00000000..28b032d5 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-annotation-3.trig @@ -0,0 +1,3 @@ +PREFIX : + +:G {:s :p :o {| :q1 :r1 ; :q2 :r2 ; |} .} diff --git a/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-annotation-4.trig b/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-annotation-4.trig new file mode 100644 index 00000000..7ca579d8 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-annotation-4.trig @@ -0,0 +1,3 @@ +PREFIX : + +:G {:s :p :o {| :x :y |} ; :q :r .} diff --git a/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-annotation-5.trig b/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-annotation-5.trig new file mode 100644 index 00000000..2635f6e1 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-annotation-5.trig @@ -0,0 +1,3 @@ +PREFIX : + +:G {:s :p :o ~:e .} diff --git a/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-annotation-6.trig b/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-annotation-6.trig new file mode 100644 index 00000000..f715f694 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-annotation-6.trig @@ -0,0 +1,3 @@ +PREFIX : + +:G {:s :p :o ~ .} diff --git a/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-annotation-7.trig b/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-annotation-7.trig new file mode 100644 index 00000000..20dc49dd --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-annotation-7.trig @@ -0,0 +1,3 @@ +PREFIX : + +:G {:s :p :o ~:e {| :q :r |} .} diff --git a/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-annotation-8.trig b/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-annotation-8.trig new file mode 100644 index 00000000..ca4d56f0 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-annotation-8.trig @@ -0,0 +1,3 @@ +PREFIX : + +:G {:s :p :o ~ {| :q :r |} .} diff --git a/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-base-1.trig b/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-base-1.trig new file mode 100644 index 00000000..89782042 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-base-1.trig @@ -0,0 +1,3 @@ +PREFIX : + +:G { :a :b "Hello"@en--ltr } diff --git a/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-base-2.trig b/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-base-2.trig new file mode 100644 index 00000000..5e9fab1b --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-base-2.trig @@ -0,0 +1,3 @@ +PREFIX : + +:G { :a :b "Hello"@en--rtl } diff --git a/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-base-bad-1.trig b/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-base-bad-1.trig new file mode 100644 index 00000000..3a348ab7 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-base-bad-1.trig @@ -0,0 +1,3 @@ +PREFIX : + +:G { :a :b "Hello"@en--unk } diff --git a/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-base-bad-2.trig b/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-base-bad-2.trig new file mode 100644 index 00000000..05e34535 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-base-bad-2.trig @@ -0,0 +1,3 @@ +PREFIX : + +:G { :a :b "Hello"@en--LTR } diff --git a/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-bad-01.trig b/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-bad-01.trig new file mode 100644 index 00000000..6e718c72 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-bad-01.trig @@ -0,0 +1,6 @@ +PREFIX : + +:G { + :s :p :o . + :x <<:s :p :o>> 123 . +} diff --git a/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-bad-02.trig b/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-bad-02.trig new file mode 100644 index 00000000..79845600 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-bad-02.trig @@ -0,0 +1,6 @@ +PREFIX : + +:G { + :s :p :o . + <<3 :p :o >> :q :z . +} diff --git a/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-bad-03.trig b/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-bad-03.trig new file mode 100644 index 00000000..8e78f14f --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-bad-03.trig @@ -0,0 +1,5 @@ +PREFIX : + +:G { + <<:s [] :o>> :q 123 . +} diff --git a/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-bad-04.trig b/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-bad-04.trig new file mode 100644 index 00000000..6112e3f2 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-bad-04.trig @@ -0,0 +1,5 @@ +PREFIX : + +:G { + :s :p << :p :r >> . +} diff --git a/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-bad-05.trig b/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-bad-05.trig new file mode 100644 index 00000000..cd31a558 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-bad-05.trig @@ -0,0 +1,5 @@ +PREFIX : + +:G { + :s :p << :g :s :p :o >> . +} diff --git a/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-bad-06.trig b/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-bad-06.trig new file mode 100644 index 00000000..9dfe4b5b --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-bad-06.trig @@ -0,0 +1,6 @@ +PREFIX : + +:G { + :s :p ("abc") . + <<:s :p ("abc") >> :q 123 . +} diff --git a/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-bad-07.trig b/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-bad-07.trig new file mode 100644 index 00000000..9d6331f2 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-bad-07.trig @@ -0,0 +1,3 @@ +PREFIX : + +:G {<<:s :p [ :p1 :o1 ] >> :q 123 .} diff --git a/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-bad-08.trig b/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-bad-08.trig new file mode 100644 index 00000000..03b67a31 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-bad-08.trig @@ -0,0 +1,3 @@ +PREFIX : + +:G {:s :p << :g :s :p :o >> .} diff --git a/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-bad-ann-1.trig b/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-bad-ann-1.trig new file mode 100644 index 00000000..04548514 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-bad-ann-1.trig @@ -0,0 +1,4 @@ +PREFIX : + +:G {:s :p :o {| |} .} + diff --git a/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-bad-ann-2.trig b/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-bad-ann-2.trig new file mode 100644 index 00000000..1d74c2c6 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-bad-ann-2.trig @@ -0,0 +1,3 @@ +PREFIX : + +:G {:a :b :c {| :s :p :o |} .} diff --git a/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-basic-01.trig b/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-basic-01.trig new file mode 100644 index 00000000..acbd98a3 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-basic-01.trig @@ -0,0 +1,6 @@ +PREFIX : + +:G { + :s :p :o . + <<:s :p :o>> :q 123 . +} diff --git a/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-basic-02.trig b/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-basic-02.trig new file mode 100644 index 00000000..f1033de4 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-basic-02.trig @@ -0,0 +1,6 @@ +PREFIX : + +:G { + :s :p :o . + :x :p <<:s :p :o>> . +} diff --git a/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-basic-03.trig b/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-basic-03.trig new file mode 100644 index 00000000..0d6d3ccd --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-basic-03.trig @@ -0,0 +1,3 @@ +PREFIX : + +:G {:s :p <<(:s :p :o )>> .} \ No newline at end of file diff --git a/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-basic-04.trig b/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-basic-04.trig new file mode 100644 index 00000000..e6514f37 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-basic-04.trig @@ -0,0 +1,6 @@ +PREFIX : + +:G { + :s :p :o . + <<:s :p :o>> . +} diff --git a/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-bnode-01.trig b/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-bnode-01.trig new file mode 100644 index 00000000..e6051df2 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-bnode-01.trig @@ -0,0 +1,6 @@ +PREFIX : + +:G { + _:a :p :o . + <<_:a :p :o >> :q 456 . +} diff --git a/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-bnode-02.trig b/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-bnode-02.trig new file mode 100644 index 00000000..8d5ddd24 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-bnode-02.trig @@ -0,0 +1,6 @@ +PREFIX : + +:G { + :s :p _:a . + <<:s :p _:a >> :q 456 . +} diff --git a/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-bnode-03.trig b/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-bnode-03.trig new file mode 100644 index 00000000..65df001f --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-bnode-03.trig @@ -0,0 +1,3 @@ +PREFIX : + +:G {<<[] :p [] >> :q :z .} diff --git a/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-compound.trig b/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-compound.trig new file mode 100644 index 00000000..b6f1816f --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-compound.trig @@ -0,0 +1,12 @@ +PREFIX : + +:G { + :x :r :z . + :a :b :c . + <<:a :b :c>> :r :z . + <<:x :r :z >> :p <<:a :b :c>> . + + << <<:x :r :z >> :p <<:a :b :c>> >> + :q + << <<:x :r :z >> :p <<:a :b :c>> >> . +} diff --git a/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-inside-01.trig b/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-inside-01.trig new file mode 100644 index 00000000..c88a87b6 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-inside-01.trig @@ -0,0 +1,6 @@ +PREFIX : + +:G { + :s :p :o . + [ :q <<:s :p :o>> ] :b :c . +} diff --git a/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-inside-02.trig b/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-inside-02.trig new file mode 100644 index 00000000..47254824 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-inside-02.trig @@ -0,0 +1,7 @@ +PREFIX : + +:G { + :s :p :o1 . + :s :p :o2 . + ( <<:s :p :o1>> <<:s :p :o2>> ) :q 123 . +} diff --git a/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-inside-03.trig b/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-inside-03.trig new file mode 100644 index 00000000..8544d367 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-inside-03.trig @@ -0,0 +1,4 @@ +PREFIX : + +:s :p << :s :p :o1 ~ :id >> . +:id :q 123 . diff --git a/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-inside-04.trig b/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-inside-04.trig new file mode 100644 index 00000000..7baee7db --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-inside-04.trig @@ -0,0 +1,4 @@ +PREFIX : + +:s :p <<:s :p :o1 ~_:id>> . +_:id :q 123 . diff --git a/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-nested-01.trig b/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-nested-01.trig new file mode 100644 index 00000000..6b0e977e --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-nested-01.trig @@ -0,0 +1,9 @@ +PREFIX : + +:G { + :s :p :o . + + <<:s :p :o >> :r :z . + + << <<:s :p :o >> :r :z >> :q 1 . +} diff --git a/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-nested-02.trig b/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-nested-02.trig new file mode 100644 index 00000000..2a79fea9 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-trig/syntax/trig12-syntax-nested-02.trig @@ -0,0 +1,7 @@ +PREFIX : + +:G { + :s :p :o . + :a :q <<:s :p :o >> . + << :a :q <<:s :p :o >>>> :r :z . +} diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/README.md b/src/test/resources/w3c/rdf12/rdf-turtle/README.md new file mode 100644 index 00000000..01b42acb --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/README.md @@ -0,0 +1,22 @@ +This README is for the W3C RDF & SPARQL Working Group's Turtle test suite. +This test suite contains three kinds of tests: + +* Positive evaluation (`rdft:TestTurtleEval`) — a pair of an input Turtle file and referenced N-Quads file.. +* Positive syntax (`rdft:TestTurtlePositiveSyntax`) — an input Turtle file with no syntax errors. +* Negative syntax (`rdft:TestTurtleNegativeSyntax`) — an input Turtle file with at least one syntax error. + +The `manifest.ttl` files in this directory lists tests in the RDF-star WG's Turtle test suite. +All tests have a name (`mf:name`) and an input (`mf:action`). + +• An implementation passes an Evaluation test if it parses the input + into a graph, parses the expected result into another graph, and + those two graphs are isomorphic (see + ). +• An implementation passes a Negative Evaluation test if it parses the input + into a graph, parses the expected result into another graph, and + those two graphs are _not_ isomorphic (see + ). +* An implementation passes a positive syntax test if it parses the input. +* An implementation passes a negative syntax test if it fails to parse the input. + +The home of the test suite is . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/eval/manifest.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/eval/manifest.ttl new file mode 100644 index 00000000..8241a84b --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/eval/manifest.ttl @@ -0,0 +1,232 @@ +## Distributed under both the "W3C Test Suite License" [1] +## and the "W3C 3-clause BSD License". +## [1] https://www.w3.org/Consortium/Legal/2008/04-testsuite-license +## [2] https://www.w3.org/Consortium/Legal/2008/03-bsd-license + +PREFIX rdf: +PREFIX rdfs: +PREFIX mf: +PREFIX test: +PREFIX rdft: +PREFIX trs: +PREFIX dct: +PREFIX xsd: +PREFIX foaf: +PREFIX skos: + +trs:manifest rdf:type mf:Manifest ; + rdfs:label "RDF 1.2 Turtle Evaluation Tests"@en ; + skos:prefLabel "La suite des tests pour RDF 1.2 Turtle"@fr; + skos:prefLabel "Conjunto de pruebas para RDF 1.2 Turtle"@es; + mf:assumedTestBase ; + dct:issued "2023-07-20"^^xsd:date ; + rdfs:seeAlso ; + dct:modified "2025-06-10"^^xsd:date ; + dct:licence ; + dct:creator [ foaf:homepage ; foaf:name "W3C RDF & SPARQL Working Group" ] ; + mf:entries + ( + trs:turtle12-rt-01 + trs:turtle12-rt-02 + trs:turtle12-rt-03 + trs:turtle12-rt-04 + trs:turtle12-rt-05 + trs:turtle12-rt-06 + trs:turtle12-rt-07 + trs:turtle12-rt-08 + trs:turtle12-bnode-01 + trs:turtle12-bnode-02 + trs:turtle12-tt-01 + trs:turtle12-tt-02 + trs:turtle12-tt-03 + trs:turtle12-tt-04 + trs:turtle12-annotation-01 + trs:turtle12-annotation-02 + trs:turtle12-annotation-03 + trs:turtle12-annotation-04 + trs:turtle12-annotation-05 + trs:turtle12-annotation-06 + trs:turtle12-annotation-07 + trs:turtle12-annotation-08 + trs:turtle12-annotation-09 + trs:turtle12-annotation-10 + trs:turtle12-annotation-11 + trs:turtle12-annotation-12 + trs:turtle12-reified-triples-annotation-01 + trs:turtle12-reified-triples-annotation-02 + trs:turtle12-reified-triples-annotation-03 + ) . + +trs:turtle12-rt-01 rdf:type rdft:TestTurtleEval ; + mf:name "Turtle 1.2 - subject reification" ; + mf:action ; + mf:result ; + . + +trs:turtle12-rt-02 rdf:type rdft:TestTurtleEval ; + mf:name "Turtle 1.2 - object reification" ; + mf:action ; + mf:result ; + . + +trs:turtle12-rt-03 rdf:type rdft:TestTurtleEval ; + mf:name "Turtle 1.2 - subject reification with identifier" ; + mf:action ; + mf:result ; + . + +trs:turtle12-rt-04 rdf:type rdft:TestTurtleEval ; + mf:name "Turtle 1.2 - object reification with identifier" ; + mf:action ; + mf:result ; + . + +trs:turtle12-rt-05 rdf:type rdft:TestTurtleEval ; + mf:name "Turtle 1.2 - subject reification with bnode identifier" ; + mf:action ; + mf:result ; + . + +trs:turtle12-rt-06 rdf:type rdft:TestTurtleEval ; + mf:name "Turtle 1.2 - object reification with bnode identifier" ; + mf:action ; + mf:result ; + . + +trs:turtle12-rt-07 rdf:type rdft:TestTurtleEval ; + mf:name "Turtle 1.2 - subject reification with empty identifier" ; + mf:action ; + mf:result ; + . + +trs:turtle12-rt-08 rdf:type rdft:TestTurtleEval ; + mf:name "Turtle 1.2 - object reification with empty identifier" ; + mf:action ; + mf:result ; + . + +trs:turtle12-bnode-01 rdf:type rdft:TestTurtleEval ; + mf:name "Turtle 1.2 - blank node label" ; + mf:action ; + mf:result ; + . + +trs:turtle12-bnode-02 rdf:type rdft:TestTurtleEval ; + mf:name "Turtle 1.2 - blank node labels" ; + mf:action ; + mf:result ; + . + +trs:turtle12-tt-01 rdf:type rdft:TestTurtleEval ; + mf:name "Turtle 1.2 - object triple term" ; + mf:action ; + mf:result ; + . + +trs:turtle12-tt-02 rdf:type rdft:TestTurtleEval ; + mf:name "Turtle 1.2 - object triple term, no whitespace" ; + mf:action ; + mf:result ; + . + +trs:turtle12-tt-03 rdf:type rdft:TestTurtleEval ; + mf:name "Turtle 1.2 - Nested, no whitespace" ; + mf:action ; + mf:result ; + . + +trs:turtle12-tt-04 rdf:type rdft:TestTurtleEval ; + mf:name "Turtle 1.2 - Nested object term" ; + mf:action ; + mf:result ; + . + +trs:turtle12-annotation-01 rdf:type rdft:TestTurtleEval ; + mf:name "Turtle 1.2 - Annotation form" ; + mf:action ; + mf:result ; + . + +trs:turtle12-annotation-02 rdf:type rdft:TestTurtleEval ; + mf:name "Turtle 1.2 - Annotation example" ; + mf:action ; + mf:result ; + . + +trs:turtle12-annotation-03 rdf:type rdft:TestTurtleEval ; + mf:name "Turtle 1.2 - Annotation - predicate and object lists" ; + mf:action ; + mf:result ; + . + +trs:turtle12-annotation-04 rdf:type rdft:TestTurtleEval ; + mf:name "Turtle 1.2 - Annotation - nested" ; + mf:action ; + mf:result ; + . + +trs:turtle12-annotation-05 rdf:type rdft:TestTurtleEval ; + mf:name "Turtle 1.2 - Annotation object list" ; + mf:action ; + mf:result ; + . + +trs:turtle12-annotation-06 rdf:type rdft:TestTurtleEval ; + mf:name "Turtle 1.2 - Annotation with identifier" ; + mf:action ; + mf:result ; + . + +trs:turtle12-annotation-07 rdf:type rdft:TestTurtleEval ; + mf:name "Turtle 1.2 - Different annotations have different default identifiers" ; + mf:action ; + mf:result ; + . + +trs:turtle12-annotation-08 rdf:type rdft:TestTurtleEval ; + mf:name "Turtle 1.2 - Annotation form with explicit identifier" ; + mf:action ; + mf:result ; + . + +trs:turtle12-annotation-09 rdf:type rdft:TestTurtleEval ; + mf:name "Turtle 1.2 - Annotation form with multiple reifiers" ; + mf:action ; + mf:result ; + . + +trs:turtle12-annotation-10 rdf:type rdft:TestTurtleEval ; + mf:name "Turtle 1.2 - Annotation form with multiple annotation blocks" ; + mf:action ; + mf:result ; + . + +trs:turtle12-annotation-11 rdf:type rdft:TestTurtleEval ; + mf:name "Turtle 1.2 - Annotation form with annotation block followed by reifier" ; + mf:action ; + mf:result ; + . + +trs:turtle12-annotation-12 rdf:type rdft:TestTurtleEval ; + mf:name "Turtle 1.2 - Annotation form with alternating reifiers and annotation blocks" ; + mf:action ; + mf:result ; + . + +trs:turtle12-reified-triples-annotation-01 rdf:type rdft:TestTurtleEval ; + mf:name "Turtle 1.2 - Annotation with reified triples" ; + mf:action ; + mf:result ; + . + +trs:turtle12-reified-triples-annotation-02 rdf:type rdft:TestTurtleEval ; + mf:name "Turtle 1.2 - Annotation on triple with reified triple subject" ; + mf:action ; + mf:result ; + . + +trs:turtle12-reified-triples-annotation-03 rdf:type rdft:TestTurtleEval ; + mf:name "Turtle 1.2 - Annotation on triple with reified triple object" ; + mf:action ; + mf:result ; + . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-01.nt b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-01.nt new file mode 100644 index 00000000..6f284c4d --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-01.nt @@ -0,0 +1,3 @@ + . +_:anon . +_:anon <<( )>> . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-01.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-01.ttl new file mode 100644 index 00000000..fdba9df1 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-01.ttl @@ -0,0 +1,3 @@ +PREFIX : + +:s :p :o {| :r :z |} . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-02.nt b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-02.nt new file mode 100644 index 00000000..79af2b31 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-02.nt @@ -0,0 +1,8 @@ + . +_:anon <<( )>> . +_:anon _:bpl0 . +_:anon _:bpl1 . +_:bpl0 . +_:bpl0 "2020-01-20"^^ . +_:bpl1 . +_:bpl1 "2020-12-31"^^ . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-02.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-02.ttl new file mode 100644 index 00000000..06ef8eaf --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-02.ttl @@ -0,0 +1,10 @@ +PREFIX : +PREFIX xsd: + +:s :p :o {| :source [ :graph ; + :date "2020-01-20"^^xsd:date + ] ; + :source [ :graph ; + :date "2020-12-31"^^xsd:date + ] + |} . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-03.nt b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-03.nt new file mode 100644 index 00000000..98bf37e9 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-03.nt @@ -0,0 +1,9 @@ + . + . + . +_:a0 <<( )>> . +_:a0 . +_:a1 <<( )>> . +_:a1 . +_:a2 <<( )>> . +_:a2 . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-03.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-03.ttl new file mode 100644 index 00000000..8b2bbd6a --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-03.ttl @@ -0,0 +1,5 @@ +PREFIX : + +:s :p :o {| :a :b |}; + :p2 :o2 {| :a2 :b2 |}, + :o3 {| :a3 :b3 |}. diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-04.nt b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-04.nt new file mode 100644 index 00000000..4ea86f27 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-04.nt @@ -0,0 +1,5 @@ + . +_:a0 <<( )>> . +_:a0 . +_:a1 <<(_:a0 )>> . +_:a1 . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-04.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-04.ttl new file mode 100644 index 00000000..c07c701f --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-04.ttl @@ -0,0 +1,3 @@ +PREFIX : + +:s :p :o {| :a :b {| :a2 :b2 |} |}. diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-05.nt b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-05.nt new file mode 100644 index 00000000..d0905e00 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-05.nt @@ -0,0 +1,4 @@ + . + . +_:anon <<( )>> . +_:anon . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-05.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-05.ttl new file mode 100644 index 00000000..751dc679 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-05.ttl @@ -0,0 +1,4 @@ +PREFIX : + +:s :p :o1, :o2 {| :a :b |} . + diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-06.nt b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-06.nt new file mode 100644 index 00000000..ff2a4cae --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-06.nt @@ -0,0 +1,3 @@ + . + . + <<( )>> . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-06.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-06.ttl new file mode 100644 index 00000000..961bcba2 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-06.ttl @@ -0,0 +1,3 @@ +PREFIX : + +:s :p :o ~ :i {| :r :z |} . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-07.nt b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-07.nt new file mode 100644 index 00000000..da039173 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-07.nt @@ -0,0 +1,5 @@ + . +_:anno1 <<( )>> . +_:anno1 . +_:anno2 <<( )>> . +_:anno2 . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-07.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-07.ttl new file mode 100644 index 00000000..f22ed664 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-07.ttl @@ -0,0 +1,4 @@ +PREFIX : + +:s :p :o {|:r :s |} . +:s :p :o {|:t :u |} . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-08.nt b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-08.nt new file mode 100644 index 00000000..ff2a4cae --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-08.nt @@ -0,0 +1,3 @@ + . + . + <<( )>> . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-08.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-08.ttl new file mode 100644 index 00000000..961bcba2 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-08.ttl @@ -0,0 +1,3 @@ +PREFIX : + +:s :p :o ~ :i {| :r :z |} . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-09.nt b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-09.nt new file mode 100644 index 00000000..bb6e5167 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-09.nt @@ -0,0 +1,4 @@ + . + <<( )>> . + <<( )>> . + . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-09.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-09.ttl new file mode 100644 index 00000000..a0602b19 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-09.ttl @@ -0,0 +1,3 @@ +PREFIX : + +:s :p :o ~ :i1 ~:i2 {| :r :z |} . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-10.nt b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-10.nt new file mode 100644 index 00000000..0e554839 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-10.nt @@ -0,0 +1,5 @@ + . +_:b1 <<( )>> . +_:b1 . +_:b2 <<( )>> . +_:b2 . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-10.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-10.ttl new file mode 100644 index 00000000..f8d31510 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-10.ttl @@ -0,0 +1,3 @@ +PREFIX : + +:s :p :o {| :r1 :z1 |} {| :r2 :z2 |} . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-11.nt b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-11.nt new file mode 100644 index 00000000..48468735 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-11.nt @@ -0,0 +1,4 @@ + . +_:b0 <<( )>> . +_:b0 . + <<( )>> . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-11.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-11.ttl new file mode 100644 index 00000000..aa58fb46 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-11.ttl @@ -0,0 +1,3 @@ +PREFIX : + +:s :p :o {| :r :z |} ~ :i . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-12.nt b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-12.nt new file mode 100644 index 00000000..7f08e6a2 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-12.nt @@ -0,0 +1,5 @@ + . + <<( )>> . + . + <<( )>> . + . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-12.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-12.ttl new file mode 100644 index 00000000..b7fc02f1 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-annotation-12.ttl @@ -0,0 +1,3 @@ +PREFIX : + +:s :p :o ~ :i1 {| :r1 :z1 |} ~ :i2 {| :r2 :z2 |}. diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-bnode-01.nt b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-bnode-01.nt new file mode 100644 index 00000000..7f6b9226 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-bnode-01.nt @@ -0,0 +1,3 @@ +_:b9 . +_:anon . +_:anon <<( _:b9 )>> . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-bnode-01.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-bnode-01.ttl new file mode 100644 index 00000000..a2c01fff --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-bnode-01.ttl @@ -0,0 +1,4 @@ +PREFIX : + +_:b :p :o . +<<_:b :p :o>> :q :z . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-bnode-02.nt b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-bnode-02.nt new file mode 100644 index 00000000..8332e383 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-bnode-02.nt @@ -0,0 +1,4 @@ +_:label1 _:label1 . +_:a0 <<(_:label1 _:label1)>> . +_:a0 _:a1 . +_:a1 <<(_:label1 )>> . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-bnode-02.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-bnode-02.ttl new file mode 100644 index 00000000..8b2e5425 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-bnode-02.ttl @@ -0,0 +1,4 @@ +PREFIX : + +_:a :p1 _:a . +<<_:a :p1 _:a >> :q <<_:a :p2 :o>> . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-reified-triples-annotation-01.nt b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-reified-triples-annotation-01.nt new file mode 100644 index 00000000..710eab41 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-reified-triples-annotation-01.nt @@ -0,0 +1,4 @@ + . +_:a0 <<( )>> . +_:a0 _:a1 . +_:a1 <<( )>> . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-reified-triples-annotation-01.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-reified-triples-annotation-01.ttl new file mode 100644 index 00000000..5245264a --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-reified-triples-annotation-01.ttl @@ -0,0 +1,3 @@ +PREFIX : + +:s :p :o {| :r <<:s1 :p1 :o1>> |} . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-reified-triples-annotation-02.nt b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-reified-triples-annotation-02.nt new file mode 100644 index 00000000..35e5da62 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-reified-triples-annotation-02.nt @@ -0,0 +1,4 @@ +_:a0 <<( )>> . +_:a0 . +_:a1 <<(_:a0 )>> . +_:a1 . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-reified-triples-annotation-02.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-reified-triples-annotation-02.ttl new file mode 100644 index 00000000..e4f70214 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-reified-triples-annotation-02.ttl @@ -0,0 +1,3 @@ +PREFIX : + +<<:s1 :p1 :o1>> :p :o {| :r :z |} . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-reified-triples-annotation-03.nt b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-reified-triples-annotation-03.nt new file mode 100644 index 00000000..1551dcbb --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-reified-triples-annotation-03.nt @@ -0,0 +1,4 @@ +_:a0 <<( )>> . + _:a0 . +_:a1 <<( _:a0)>> . +_:a1 . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-reified-triples-annotation-03.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-reified-triples-annotation-03.ttl new file mode 100644 index 00000000..f19ee115 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-reified-triples-annotation-03.ttl @@ -0,0 +1,3 @@ +PREFIX : + +:s :p <<:s2 :p2 :o2>> {| :r :z |} . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-rt-01.nt b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-rt-01.nt new file mode 100644 index 00000000..7f4f729d --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-rt-01.nt @@ -0,0 +1,2 @@ +_:anon . +_:anon <<( )>> . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-rt-01.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-rt-01.ttl new file mode 100644 index 00000000..ad4940b9 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-rt-01.ttl @@ -0,0 +1,3 @@ +PREFIX : + +<<:s :p :o>> :q :z . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-rt-02.nt b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-rt-02.nt new file mode 100644 index 00000000..e38259e1 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-rt-02.nt @@ -0,0 +1,2 @@ + _:anon . +_:anon <<( )>> . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-rt-02.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-rt-02.ttl new file mode 100644 index 00000000..6e76ac6d --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-rt-02.ttl @@ -0,0 +1,3 @@ +PREFIX : + +:a :q <<:s :p :o>> . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-rt-03.nt b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-rt-03.nt new file mode 100644 index 00000000..7d4460dd --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-rt-03.nt @@ -0,0 +1,2 @@ + . + <<( )>> . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-rt-03.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-rt-03.ttl new file mode 100644 index 00000000..a68f0135 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-rt-03.ttl @@ -0,0 +1,3 @@ +PREFIX : + +<< :s :p :o ~ :i >> :q :z . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-rt-04.nt b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-rt-04.nt new file mode 100644 index 00000000..72a80300 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-rt-04.nt @@ -0,0 +1,2 @@ + . + <<( )>> . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-rt-04.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-rt-04.ttl new file mode 100644 index 00000000..80f1e4a3 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-rt-04.ttl @@ -0,0 +1,3 @@ +PREFIX : + +:a :q << :s :p :o ~ :i >> . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-rt-05.nt b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-rt-05.nt new file mode 100644 index 00000000..b12373a2 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-rt-05.nt @@ -0,0 +1,2 @@ +_:i . +_:i <<( )>> . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-rt-05.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-rt-05.ttl new file mode 100644 index 00000000..10b4d57f --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-rt-05.ttl @@ -0,0 +1,3 @@ +PREFIX : + +<< :s :p :o ~ _:i >> :q :z . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-rt-06.nt b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-rt-06.nt new file mode 100644 index 00000000..a3346be3 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-rt-06.nt @@ -0,0 +1,2 @@ + _:i . +_:i <<( )>> . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-rt-06.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-rt-06.ttl new file mode 100644 index 00000000..4237f9a6 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-rt-06.ttl @@ -0,0 +1,3 @@ +PREFIX : + +:a :q << :s :p :o ~ _:i >> . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-rt-07.nt b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-rt-07.nt new file mode 100644 index 00000000..e793deef --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-rt-07.nt @@ -0,0 +1,2 @@ +_:bn . +_:bn <<( )>> . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-rt-07.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-rt-07.ttl new file mode 100644 index 00000000..a6bb344e --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-rt-07.ttl @@ -0,0 +1,3 @@ +PREFIX : + +<< :s :p :o ~ >> :q :z . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-rt-08.nt b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-rt-08.nt new file mode 100644 index 00000000..64a1ade9 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-rt-08.nt @@ -0,0 +1,2 @@ + _:bn . +_:bn <<( )>> . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-rt-08.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-rt-08.ttl new file mode 100644 index 00000000..342c7f3b --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-rt-08.ttl @@ -0,0 +1,3 @@ +PREFIX : + +:a :q << :s :p :o ~ >> . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-tt-01.nt b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-tt-01.nt new file mode 100644 index 00000000..0dd45a2a --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-tt-01.nt @@ -0,0 +1 @@ + <<( )>> . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-tt-01.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-tt-01.ttl new file mode 100644 index 00000000..eac0b8c4 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-tt-01.ttl @@ -0,0 +1,4 @@ +PREFIX : +PREFIX rdf: + +:a rdf:reifies <<( :s :p :o )>> . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-tt-02.nt b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-tt-02.nt new file mode 100644 index 00000000..90b85d63 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-tt-02.nt @@ -0,0 +1 @@ +<<()>>. diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-tt-02.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-tt-02.ttl new file mode 100644 index 00000000..a5a561ff --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-tt-02.ttl @@ -0,0 +1,4 @@ +BASE +PREFIX rdf: + +rdf:reifies<<()>>. diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-tt-03.nt b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-tt-03.nt new file mode 100644 index 00000000..6825c6b2 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-tt-03.nt @@ -0,0 +1 @@ +<<(<<()>>)>>. \ No newline at end of file diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-tt-03.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-tt-03.ttl new file mode 100644 index 00000000..0633afd4 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-tt-03.ttl @@ -0,0 +1,4 @@ +BASE +PREFIX rdf: + +rdf:reifies<<(<<()>>)>>. \ No newline at end of file diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-tt-04.nt b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-tt-04.nt new file mode 100644 index 00000000..bd89c0db --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-tt-04.nt @@ -0,0 +1,3 @@ + . + <<( )>> . + <<( <<( )>> )>> . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-tt-04.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-tt-04.ttl new file mode 100644 index 00000000..0d5de3e9 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/eval/turtle12-eval-tt-04.ttl @@ -0,0 +1,6 @@ +PREFIX : +PREFIX rdf: + +:s :p :o . +:a rdf:reifies <<( :s1 :p1 :o1 )>> . +:r rdf:reifies <<( :23 rdf:reifies <<( :s3 :p3 :o3 )>> )>> . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/manifest.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/manifest.ttl new file mode 100644 index 00000000..0758e91b --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/manifest.ttl @@ -0,0 +1,36 @@ +PREFIX rdf: +PREFIX rdfs: +PREFIX mf: +PREFIX rdft: +PREFIX trs: +PREFIX dct: +PREFIX xsd: +PREFIX foaf: +PREFIX skos: + +trs:manifest rdf:type mf:Manifest ; + rdfs:label "RDF 1.2 Turtle tests"@en ; + skos:prefLabel "La suite des tests pour RDF 1.2 Turtle"@fr; + skos:prefLabel "Conjunto de pruebas para RDF 1.2 Turtle"@es; + mf:assumedTestBase ; + dct:issued "2023-10-28"^^xsd:date ; + rdfs:seeAlso ; + dct:modified "2025-06-10"^^xsd:date ; + dct:licence ; + dct:creator [ foaf:homepage ; foaf:name "W3C RDF & SPARQL Working Group" ] ; + rdfs:comment """ + These test suites are a product of the [W3C RDF & SPARQL Working Group](https://www.w3.org/groups/wg/rdf-star/) as well as the + RDF-Star Interest Group within the W3C RDF-DEV Community Group, + and has been maintained by the + [RDF Test Curation Community Group](https://www.w3.org/community/rdf-tests/) + at [https://github.com/w3c/rdf-tests/tree/main/rdf/rdf11](https://github.com/w3c/rdf-tests/tree/main/rdf/rdf11/). + + Conformance with RDF 1.2 specifications can be determined via successfully running the + tests for relevant specifications + along with the relevant RDF 1.1 tests. + """; + mf:include ( + + + <../../rdf11/rdf-turtle/manifest.ttl> + ) . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/syntax/manifest.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/manifest.ttl new file mode 100644 index 00000000..16c41106 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/manifest.ttl @@ -0,0 +1,518 @@ +## Distributed under both the "W3C Test Suite License" [1] +## and the "W3C 3-clause BSD License". +## [1] https://www.w3.org/Consortium/Legal/2008/04-testsuite-license +## [2] https://www.w3.org/Consortium/Legal/2008/03-bsd-license + +PREFIX rdf: +PREFIX rdfs: +PREFIX mf: +PREFIX rdft: +PREFIX trs: +PREFIX dct: +PREFIX xsd: +PREFIX foaf: +PREFIX skos: + +trs:manifest rdf:type mf:Manifest ; + rdfs:label "RDF 1.2 Turtle Syntax Tests"@en ; + skos:prefLabel "La suite des tests pour la syntaxe RDF 1.2 Turtle"@fr ; + skos:prefLabel "Conjunto de pruebas para la sintaxis RDF 1.2 Turtle"@es ; + mf:assumedTestBase ; + dct:issued "2023-07-20"^^xsd:date ; + dct:modified "2025-06-10"^^xsd:date ; + dct:licence ; + dct:creator [ foaf:homepage ; foaf:name "W3C RDF & SPARQL Working Group" ] ; + mf:entries + ( + trs:turtle12-1 + trs:turtle12-2 + trs:turtle12-3 + trs:turtle12-4 + trs:turtle12-5 + trs:turtle12-6 + trs:turtle12-7 + trs:turtle12-8 + + trs:turtle12-inside-1 + trs:turtle12-inside-2 + trs:turtle12-inside-3 + trs:turtle12-inside-4 + + trs:turtle12-nested-1 + trs:turtle12-nested-2 + + trs:turtle12-compound-1 + + trs:turtle12-bnode-1 + trs:turtle12-bnode-2 + trs:turtle12-bnode-3 + + trs:turtle12-bad-1 + trs:turtle12-bad-2 + trs:turtle12-bad-3 + trs:turtle12-bad-4 + trs:turtle12-bad-5 + trs:turtle12-bad-6 + trs:turtle12-bad-7 + + trs:turtle12-ann-1 + trs:turtle12-ann-2 + trs:turtle12-ann-3 + trs:turtle12-ann-4 + trs:turtle12-ann-5 + trs:turtle12-ann-6 + trs:turtle12-ann-7 + trs:turtle12-ann-8 + + trs:turtle12-bad-ann-1 + trs:turtle12-bad-ann-2 + +## The same data as the N-Triples 1.2 syntax tests, +## except in file *.ttl and "TestTurtle" + + trs:nt-ttl12-1 + trs:nt-ttl12-2 + trs:nt-ttl12-3 + + trs:nt-ttl12-bnode-1 + + trs:nt-ttl12-nested-1 + +## Base direction + + trs:nt-ttl12-langdir-1 + trs:nt-ttl12-langdir-2 + + trs:nt-ttl12-langdir-bad-1 + trs:nt-ttl12-langdir-bad-2 + + trs:nt-ttl12-bad-01 + trs:nt-ttl12-bad-02 + trs:nt-ttl12-bad-03 + trs:nt-ttl12-bad-04 + trs:nt-ttl12-bad-05 + trs:nt-ttl12-bad-06 + trs:nt-ttl12-bad-07 + trs:nt-ttl12-bad-08 + trs:nt-ttl12-bad-09 + +## Version + + trs:turtle12-version-01 + trs:turtle12-version-02 + trs:turtle12-version-03 + trs:turtle12-version-04 + trs:turtle12-version-05 + trs:turtle12-version-06 + trs:turtle12-version-07 + trs:turtle12-version-08 + + trs:turtle12-version-bad-01 + trs:turtle12-version-bad-02 + trs:turtle12-version-bad-03 + trs:turtle12-version-bad-04 + trs:turtle12-version-bad-05 + trs:turtle12-version-bad-06 + +## Surrogate handling + trs:turtle12-surrogate-pair-bad-01 + trs:turtle12-surrogate-pair-bad-02 + trs:turtle12-surrogates-bad-01 + trs:turtle12-surrogates-bad-02 + trs:turtle12-surrogates-bad-03 + trs:turtle12-surrogates-bad-04 + trs:turtle12-surrogates-bad-05 + ) . + +## Good Syntax + +trs:turtle12-1 rdf:type rdft:TestTurtlePositiveSyntax ; + mf:name "Turtle 1.2 - subject reified triple" ; + mf:action ; + . + +trs:turtle12-2 rdf:type rdft:TestTurtlePositiveSyntax ; + mf:name "Turtle 1.2 - object reified triple" ; + mf:action ; + . + +trs:turtle12-3 rdf:type rdft:TestTurtlePositiveSyntax ; + mf:name "Turtle 1.2 - triple term object" ; + mf:action ; + . + +trs:turtle12-4 rdf:type rdft:TestTurtlePositiveSyntax ; + mf:name "Turtle 1.2 - reified triple outside triple" ; + mf:action ; + . + +trs:turtle12-5 rdf:type rdft:TestTurtlePositiveSyntax ; + mf:name "Turtle 1.2 - reified triple with literal object" ; + mf:action ; + . + +trs:turtle12-6 rdf:type rdft:TestTurtlePositiveSyntax ; + mf:name "Turtle 1.2 - reified triple with keyword object" ; + mf:action ; + . + +trs:turtle12-7 rdf:type rdft:TestTurtlePositiveSyntax ; + mf:name "Turtle 1.2 - triple term with literal object" ; + mf:action ; + . + +trs:turtle12-8 rdf:type rdft:TestTurtlePositiveSyntax ; + mf:name "Turtle 1.2 - triple term with keyword object" ; + mf:action ; + . + +trs:turtle12-inside-1 rdf:type rdft:TestTurtlePositiveSyntax ; + mf:name "Turtle 1.2 - reified triple inside blankNodePropertyList" ; + mf:action ; + . + +trs:turtle12-inside-2 rdf:type rdft:TestTurtlePositiveSyntax ; + mf:name "Turtle 1.2 - reified triple inside collection" ; + mf:action ; + . + +trs:turtle12-inside-3 rdf:type rdft:TestTurtlePositiveSyntax ; + mf:name "Turtle 1.2 - reified triple with IRI identifier" ; + mf:action ; + . + +trs:turtle12-inside-4 rdf:type rdft:TestTurtlePositiveSyntax ; + mf:name "Turtle 1.2 - reified triple with blank node identifier" ; + mf:action ; + . + +trs:turtle12-nested-1 rdf:type rdft:TestTurtlePositiveSyntax ; + mf:name "Turtle 1.2 - nested reified triple, subject position" ; + mf:action ; + . + +trs:turtle12-nested-2 rdf:type rdft:TestTurtlePositiveSyntax ; + mf:name "Turtle 1.2 - nested reified triple, object position" ; + mf:action ; + . + +trs:turtle12-compound-1 rdf:type rdft:TestTurtlePositiveSyntax ; + mf:name "Turtle 1.2 - compound forms" ; + mf:action ; + . + +trs:turtle12-bnode-1 rdf:type rdft:TestTurtlePositiveSyntax ; + mf:name "Turtle 1.2 - blank node subject" ; + mf:action ; + . + +trs:turtle12-bnode-2 rdf:type rdft:TestTurtlePositiveSyntax ; + mf:name "Turtle 1.2 - blank node object" ; + mf:action ; + . + +trs:turtle12-bnode-3 rdf:type rdft:TestTurtlePositiveSyntax ; + mf:name "Turtle 1.2 - blank node" ; + mf:action ; + . + +## Bad Syntax + +trs:turtle12-bad-1 rdf:type rdft:TestTurtleNegativeSyntax ; + mf:name "Turtle 1.2 - bad - reified triple as predicate" ; + mf:action ; + . + +trs:turtle12-bad-2 rdf:type rdft:TestTurtleNegativeSyntax ; + mf:name "Turtle 1.2 - bad - literal in subject position of reified triple" ; + mf:action ; + . + +trs:turtle12-bad-3 rdf:type rdft:TestTurtleNegativeSyntax ; + mf:name "Turtle 1.2 - bad - blank node as predicate in reified triple"; + mf:action ; + . + +trs:turtle12-bad-4 rdf:type rdft:TestTurtleNegativeSyntax ; + mf:name "Turtle 1.2 - bad - incomplete reified triple"; + mf:action ; + . + +trs:turtle12-bad-5 rdf:type rdft:TestTurtleNegativeSyntax ; + mf:name "Turtle 1.2 - bad - over-long reified triple"; + mf:action ; + . + +trs:turtle12-bad-6 rdf:type rdft:TestTurtleNegativeSyntax ; + mf:name "Turtle 1.2 - bad - reified with list object" ; + mf:action ; + . + +trs:turtle12-bad-7 rdf:type rdft:TestTurtleNegativeSyntax ; + mf:name "Turtle 1.2 - bad - compound blank node expression"; + mf:action ; + . + +## Annotation syntax + +trs:turtle12-ann-1 rdf:type rdft:TestTurtlePositiveSyntax ; + mf:name "Turtle 1.2 - Annotation form" ; + mf:action ; + . + +trs:turtle12-ann-2 rdf:type rdft:TestTurtlePositiveSyntax ; + mf:name "Turtle 1.2 - Annotation example" ; + mf:action ; + . + +trs:turtle12-ann-3 rdf:type rdft:TestTurtlePositiveSyntax ; + mf:name "Turtle 1.2 - Annotation predicateObjecetList" ; + mf:action ; + . + +trs:turtle12-ann-4 rdf:type rdft:TestTurtlePositiveSyntax ; + mf:name "Turtle 1.2 - Annotation followed by predicate/object" ; + mf:action ; + . + +trs:turtle12-ann-5 rdf:type rdft:TestTurtlePositiveSyntax ; + mf:name "Turtle 1.2 - Reifier without annotation block" ; + mf:action ; + . + +trs:turtle12-ann-6 rdf:type rdft:TestTurtlePositiveSyntax ; + mf:name "Turtle 1.2 - Empty reifier without annotation block" ; + mf:action ; + . + +trs:turtle12-ann-7 rdf:type rdft:TestTurtlePositiveSyntax ; + mf:name "Turtle 1.2 - Reifier with annotation block" ; + mf:action ; + . + +trs:turtle12-ann-8 rdf:type rdft:TestTurtlePositiveSyntax ; + mf:name "Turtle 1.2 - Empty reifier with annotation block" ; + mf:action ; + . + +## Bad annotation syntax + +trs:turtle12-bad-ann-1 rdf:type rdft:TestTurtleNegativeSyntax ; + mf:name "Turtle 1.2 - bad - empty annotation" ; + mf:action ; + . + +trs:turtle12-bad-ann-2 rdf:type rdft:TestTurtleNegativeSyntax ; + mf:name "Turtle 1.2 - bad - triple as annotation" ; + mf:action ; + . + +## -------------------------------------------------- +## Same data as the N-triples 1.2 tests. +## N-Triples is a subset of Turtle, and the same is true for the 1.2 features. + +## Good Syntax + +trs:nt-ttl12-1 rdf:type rdft:TestTurtlePositiveSyntax ; + mf:name "N-Triples 1.2 as Turtle 1.2 - triple term" ; + mf:action ; + . + +trs:nt-ttl12-2 rdf:type rdft:TestTurtlePositiveSyntax ; + mf:name "N-Triples 1.2 as Turtle 1.2 - whitespace and terms" ; + mf:action ; + . + +trs:nt-ttl12-3 rdf:type rdft:TestTurtlePositiveSyntax ; + mf:name "N-Triples 1.2 as Turtle 1.2 - Nested, no whitespace" ; + mf:action ; + . + +trs:nt-ttl12-langdir-1 rdf:type rdft:TestTurtlePositiveSyntax ; + mf:name "N-Triples 1.2 as Turtle 1.2 - base direction ltr" ; + mf:action ; + . + +trs:nt-ttl12-langdir-2 rdf:type rdft:TestTurtlePositiveSyntax ; + mf:name "N-Triples 1.2 as Turtle 1.2 - base direction ltr" ; + mf:action ; + . + +# Blank nodes + +trs:nt-ttl12-bnode-1 rdf:type rdft:TestTurtlePositiveSyntax ; + mf:name "N-Triples 1.2 as Turtle 1.2 - Blank node object" ; + mf:action ; + . + +trs:nt-ttl12-nested-1 rdf:type rdft:TestTurtlePositiveSyntax ; + mf:name "N-Triples 1.2 as Turtle 1.2 - Nested subject term" ; + mf:action ; + . + +## Bad syntax + +trs:nt-ttl12-bad-01 rdf:type rdft:TestTurtleNegativeSyntax ; + mf:name "N-Triples 1.2 as Turtle 1.2 - Bad - triple term as predicate" ; + mf:action ; + . + +trs:nt-ttl12-bad-02 rdf:type rdft:TestTurtleNegativeSyntax ; + mf:name "N-Triples 1.2 as Turtle 1.2 - Bad - triple term, literal subject" ; + mf:action ; + . + +trs:nt-ttl12-bad-03 rdf:type rdft:TestTurtleNegativeSyntax ; + mf:name "N-Triples 1.2 as Turtle 1.2 - Bad - triple term, literal predicate" ; + mf:action ; + . + +trs:nt-ttl12-bad-04 rdf:type rdft:TestTurtleNegativeSyntax ; + mf:name "N-Triples 1.2 as Turtle 1.2 - Bad - triple term, blank node predicate" ; + mf:action ; + . + +trs:nt-ttl12-bad-05 rdf:type rdft:TestTurtleNegativeSyntax ; + mf:name "N-Triples 1.2 as Turtle 1.2 - Bad - triple term as subject" ; + mf:action ; + . + +trs:nt-ttl12-bad-06 rdf:type rdft:TestTurtleNegativeSyntax ; + mf:name "N-Triples 1.2 as Turtle 1.2 - Bad - reified triple as predicate" ; + mf:action ; + . + +trs:nt-ttl12-bad-07 rdf:type rdft:TestTurtleNegativeSyntax ; + mf:name "N-Triples 1.2 as Turtle 1.2 - Bad - reified triple, literal subject" ; + mf:action ; + . + +trs:nt-ttl12-bad-08 rdf:type rdft:TestTurtleNegativeSyntax ; + mf:name "N-Triples 1.2 as Turtle 1.2 - Bad - reified triple, literal predicate" ; + mf:action ; + . + +trs:nt-ttl12-bad-09 rdf:type rdft:TestTurtleNegativeSyntax ; + mf:name "N-Triples 1.2 as Turtle 1.2 - Bad - reified triple, blank node predicate" ; + mf:action ; + . + +trs:nt-ttl12-langdir-bad-1 rdf:type rdft:TestTurtleNegativeSyntax ; + mf:name "N-Triples 1.2 as Turtle 1.2 - undefined base direction" ; + mf:action ; + . + +trs:nt-ttl12-langdir-bad-2 rdf:type rdft:TestTurtleNegativeSyntax ; + mf:name "N-Triples 1.2 as Turtle 1.2 - upper case LTR" ; + mf:action ; + . + +## Version + +trs:turtle12-version-01 rdf:type rdft:TestTurtlePositiveSyntax ; + mf:name "Turtle 1.2 - VERSION" ; + mf:action ; + . + +trs:turtle12-version-02 rdf:type rdft:TestTurtlePositiveSyntax ; + mf:name "Turtle 1.2 - @version" ; + mf:action ; + . + +trs:turtle12-version-03 rdf:type rdft:TestTurtlePositiveSyntax ; + mf:name "Turtle 1.2 - VERSION in data" ; + mf:action ; + . + +trs:turtle12-version-04 rdf:type rdft:TestTurtlePositiveSyntax ; + mf:name "Turtle 1.2 - @version in data" ; + mf:action ; + . + +trs:turtle12-version-05 rdf:type rdft:TestTurtlePositiveSyntax ; + mf:name "Turtle 1.2 - VERSION other version string" ; + mf:action ; + . + +trs:turtle12-version-06 rdf:type rdft:TestTurtlePositiveSyntax ; + mf:name "Turtle 1.2 - @version other version string" ; + mf:action ; + . + +trs:turtle12-version-07 rdf:type rdft:TestTurtlePositiveSyntax ; + mf:name "Turtle 1.2 - mixed versions" ; + mf:action ; + . + +trs:turtle12-version-08 rdf:type rdft:TestTurtlePositiveSyntax ; + mf:name "Turtle 1.2 - many versions" ; + mf:action ; + . + +trs:turtle12-version-bad-01 rdf:type rdft:TestTurtleNegativeSyntax ; + mf:name "Turtle 1.2 - VERSION - not string" ; + mf:action ; + . + +trs:turtle12-version-bad-02 rdf:type rdft:TestTurtleNegativeSyntax ; + mf:name "Turtle 1.2 - VERSION - triple-'-quoted string" ; + mf:action ; + . + +trs:turtle12-version-bad-03 rdf:type rdft:TestTurtleNegativeSyntax ; + mf:name "Turtle 1.2 - VERSION - triple-\"-quoted string" ; + mf:action ; + . + +trs:turtle12-version-bad-04 rdf:type rdft:TestTurtleNegativeSyntax ; + mf:name "Turtle 1.2 - @version - not string" ; + mf:action ; + . + +trs:turtle12-version-bad-05 rdf:type rdft:TestTurtleNegativeSyntax ; + mf:name "Turtle 1.2 - @version - triple-'-quoted string" ; + mf:action ; + . + +trs:turtle12-version-bad-06 rdf:type rdft:TestTurtleNegativeSyntax ; + mf:name "Turtle 1.2 - @version - triple-\"-quoted string" ; + mf:action ; + . + +## Surrogates + + +trs:turtle12-surrogate-pair-bad-01 rdf:type rdft:TestTurtleNegativeSyntax ; + mf:name "Turtle 1.2 - Bad - Surrogate pair numeric escape sequence" ; + mf:action + . + +trs:turtle12-surrogate-pair-bad-02 rdf:type rdft:TestTurtleNegativeSyntax ; + mf:name "Turtle 1.2 - Bad - Surrogate pair via numeric escape sequence" ; + mf:action + . + +trs:turtle12-surrogates-bad-01 rdf:type rdft:TestTurtleNegativeSyntax ; + mf:name "Turtle 1.2 - Bad - Surrogates - wrong order" ; + mf:action ; + . + +trs:turtle12-surrogates-bad-02 rdf:type rdft:TestTurtleNegativeSyntax ; + mf:name "Turtle 1.2 - Bad - Surrogates - high-high" ; + mf:action ; + . + +trs:turtle12-surrogates-bad-03 rdf:type rdft:TestTurtleNegativeSyntax ; + mf:name "Turtle 1.2 - Bad - Surrogates - low-low" ; + mf:action ; + . + +trs:turtle12-surrogates-bad-04 rdf:type rdft:TestTurtleNegativeSyntax ; + mf:name "Turtle 1.2 - Bad - Surrogates - lone high surrogate" ; + mf:action ; + . + +trs:turtle12-surrogates-bad-05 rdf:type rdft:TestTurtleNegativeSyntax ; + mf:name "Turtle 1.2 - Bad - Surrogates - lone low surrogate" ; + mf:action ; + . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/syntax/nt-ttl12-bad-10.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/nt-ttl12-bad-10.ttl new file mode 100644 index 00000000..242d1825 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/nt-ttl12-bad-10.ttl @@ -0,0 +1 @@ +<<( )>> . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/syntax/nt-ttl12-bad-syntax-01.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/nt-ttl12-bad-syntax-01.ttl new file mode 100644 index 00000000..3719b81a --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/nt-ttl12-bad-syntax-01.ttl @@ -0,0 +1 @@ + <<( )>> . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/syntax/nt-ttl12-bad-syntax-02.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/nt-ttl12-bad-syntax-02.ttl new file mode 100644 index 00000000..1a0f3592 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/nt-ttl12-bad-syntax-02.ttl @@ -0,0 +1 @@ + <<( "XYZ" )>> . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/syntax/nt-ttl12-bad-syntax-03.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/nt-ttl12-bad-syntax-03.ttl new file mode 100644 index 00000000..11f5f18d --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/nt-ttl12-bad-syntax-03.ttl @@ -0,0 +1 @@ + <<( "XYZ" )>> . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/syntax/nt-ttl12-bad-syntax-04.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/nt-ttl12-bad-syntax-04.ttl new file mode 100644 index 00000000..e83c9600 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/nt-ttl12-bad-syntax-04.ttl @@ -0,0 +1 @@ + << _:label >> . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/syntax/nt-ttl12-bad-syntax-05.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/nt-ttl12-bad-syntax-05.ttl new file mode 100644 index 00000000..242d1825 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/nt-ttl12-bad-syntax-05.ttl @@ -0,0 +1 @@ +<<( )>> . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/syntax/nt-ttl12-bad-syntax-06.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/nt-ttl12-bad-syntax-06.ttl new file mode 100644 index 00000000..1ab848d7 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/nt-ttl12-bad-syntax-06.ttl @@ -0,0 +1 @@ + <<( )>> . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/syntax/nt-ttl12-bad-syntax-07.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/nt-ttl12-bad-syntax-07.ttl new file mode 100644 index 00000000..1e47b360 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/nt-ttl12-bad-syntax-07.ttl @@ -0,0 +1 @@ +<< "XYZ" >> . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/syntax/nt-ttl12-bad-syntax-08.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/nt-ttl12-bad-syntax-08.ttl new file mode 100644 index 00000000..eaeb6f2a --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/nt-ttl12-bad-syntax-08.ttl @@ -0,0 +1 @@ +<< "XYZ" >> . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/syntax/nt-ttl12-bad-syntax-09.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/nt-ttl12-bad-syntax-09.ttl new file mode 100644 index 00000000..af41d206 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/nt-ttl12-bad-syntax-09.ttl @@ -0,0 +1 @@ +<< _:label >> . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/syntax/nt-ttl12-bnode-1.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/nt-ttl12-bnode-1.ttl new file mode 100644 index 00000000..a5af9858 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/nt-ttl12-bnode-1.ttl @@ -0,0 +1,2 @@ +_:b0 . +_:b1 <<( _:b0 )>> . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/syntax/nt-ttl12-langdir-1.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/nt-ttl12-langdir-1.ttl new file mode 100644 index 00000000..a58e1092 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/nt-ttl12-langdir-1.ttl @@ -0,0 +1 @@ + "Hello"@en--ltr . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/syntax/nt-ttl12-langdir-2.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/nt-ttl12-langdir-2.ttl new file mode 100644 index 00000000..fe4bc9d5 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/nt-ttl12-langdir-2.ttl @@ -0,0 +1 @@ + "Hello"@en--rtl . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/syntax/nt-ttl12-langdir-bad-1.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/nt-ttl12-langdir-bad-1.ttl new file mode 100644 index 00000000..2c943ddc --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/nt-ttl12-langdir-bad-1.ttl @@ -0,0 +1 @@ + "Hello"@en--unk . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/syntax/nt-ttl12-langdir-bad-2.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/nt-ttl12-langdir-bad-2.ttl new file mode 100644 index 00000000..16dc8be6 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/nt-ttl12-langdir-bad-2.ttl @@ -0,0 +1 @@ + "Hello"@en--LTR . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/syntax/nt-ttl12-nested-1.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/nt-ttl12-nested-1.ttl new file mode 100644 index 00000000..bd89c0db --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/nt-ttl12-nested-1.ttl @@ -0,0 +1,3 @@ + . + <<( )>> . + <<( <<( )>> )>> . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/syntax/nt-ttl12-syntax-1.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/nt-ttl12-syntax-1.ttl new file mode 100644 index 00000000..0dd45a2a --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/nt-ttl12-syntax-1.ttl @@ -0,0 +1 @@ + <<( )>> . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/syntax/nt-ttl12-syntax-2.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/nt-ttl12-syntax-2.ttl new file mode 100644 index 00000000..90b85d63 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/nt-ttl12-syntax-2.ttl @@ -0,0 +1 @@ +<<()>>. diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/syntax/nt-ttl12-syntax-3.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/nt-ttl12-syntax-3.ttl new file mode 100644 index 00000000..6825c6b2 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/nt-ttl12-syntax-3.ttl @@ -0,0 +1 @@ +<<(<<()>>)>>. \ No newline at end of file diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-annotation-1.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-annotation-1.ttl new file mode 100644 index 00000000..fdba9df1 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-annotation-1.ttl @@ -0,0 +1,3 @@ +PREFIX : + +:s :p :o {| :r :z |} . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-annotation-2.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-annotation-2.ttl new file mode 100644 index 00000000..06ef8eaf --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-annotation-2.ttl @@ -0,0 +1,10 @@ +PREFIX : +PREFIX xsd: + +:s :p :o {| :source [ :graph ; + :date "2020-01-20"^^xsd:date + ] ; + :source [ :graph ; + :date "2020-12-31"^^xsd:date + ] + |} . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-annotation-3.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-annotation-3.ttl new file mode 100644 index 00000000..53a9f795 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-annotation-3.ttl @@ -0,0 +1,3 @@ +PREFIX : + +:s :p :o {| :q1 :r1 ; :q2 :r2 ; |} . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-annotation-4.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-annotation-4.ttl new file mode 100644 index 00000000..5a2b1f78 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-annotation-4.ttl @@ -0,0 +1,3 @@ +PREFIX : + +:s :p :o {| :x :y |} ; :q :r . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-annotation-5.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-annotation-5.ttl new file mode 100644 index 00000000..410180a0 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-annotation-5.ttl @@ -0,0 +1,3 @@ +PREFIX : + +:s :p :o ~:e . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-annotation-6.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-annotation-6.ttl new file mode 100644 index 00000000..26e28081 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-annotation-6.ttl @@ -0,0 +1,3 @@ +PREFIX : + +:s :p :o ~ . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-annotation-7.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-annotation-7.ttl new file mode 100644 index 00000000..a7b38996 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-annotation-7.ttl @@ -0,0 +1,3 @@ +PREFIX : + +:s :p :o ~:e {| :q :r |} . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-annotation-8.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-annotation-8.ttl new file mode 100644 index 00000000..c598d0af --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-annotation-8.ttl @@ -0,0 +1,3 @@ +PREFIX : + +:s :p :o ~ {| :q :r |} . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-surrogate-pair-bad-01.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-surrogate-pair-bad-01.ttl new file mode 100644 index 00000000..f5608af9 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-surrogate-pair-bad-01.ttl @@ -0,0 +1,2 @@ +PREFIX : +:s :p "\uD83C\uDCA1" . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-surrogate-pair-bad-02.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-surrogate-pair-bad-02.ttl new file mode 100644 index 00000000..d38d031c --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-surrogate-pair-bad-02.ttl @@ -0,0 +1,2 @@ +PREFIX : +:s :p 'Ace of spades : \uD83C\uDCA1' . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-surrogates-bad-01.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-surrogates-bad-01.ttl new file mode 100644 index 00000000..5965530a --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-surrogates-bad-01.ttl @@ -0,0 +1,3 @@ +PREFIX : +# Bad low-high, not high-low +:s :p "\uDCA1\uD83C" . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-surrogates-bad-02.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-surrogates-bad-02.ttl new file mode 100644 index 00000000..3431abce --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-surrogates-bad-02.ttl @@ -0,0 +1,3 @@ +PREFIX : +## Surrogates : high-high +:s :p "\uD83C\uD83D" . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-surrogates-bad-03.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-surrogates-bad-03.ttl new file mode 100644 index 00000000..5c536682 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-surrogates-bad-03.ttl @@ -0,0 +1,3 @@ +PREFIX : +## Surrogates : low-low +:s :p "\uDCA1\uDCA2" . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-surrogates-bad-04.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-surrogates-bad-04.ttl new file mode 100644 index 00000000..8a0c4000 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-surrogates-bad-04.ttl @@ -0,0 +1,2 @@ +PREFIX : +:s :p "Single high surrogate (\uD83C)" . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-surrogates-bad-05.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-surrogates-bad-05.ttl new file mode 100644 index 00000000..d1103ed9 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-surrogates-bad-05.ttl @@ -0,0 +1,2 @@ +PREFIX : +:s :p "Single low surrogate (\uDCA1)" . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-bad-01.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-bad-01.ttl new file mode 100644 index 00000000..4a41e436 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-bad-01.ttl @@ -0,0 +1,4 @@ +PREFIX : + +:s :p :o . +:x <<:s :p :o>> 123 . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-bad-02.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-bad-02.ttl new file mode 100644 index 00000000..a69b6469 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-bad-02.ttl @@ -0,0 +1,4 @@ +PREFIX : + +:s :p :o . +<<3 :p :o >> :q :z . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-bad-03.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-bad-03.ttl new file mode 100644 index 00000000..b1a45960 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-bad-03.ttl @@ -0,0 +1,3 @@ +PREFIX : + +<<:s [] :o>> :q 123 . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-bad-04.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-bad-04.ttl new file mode 100644 index 00000000..329e6d39 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-bad-04.ttl @@ -0,0 +1,3 @@ +PREFIX : + +:s :p << :p :r >> . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-bad-05.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-bad-05.ttl new file mode 100644 index 00000000..72ceff2e --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-bad-05.ttl @@ -0,0 +1,3 @@ +PREFIX : + +:s :p << :g :s :p :o >> . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-bad-06.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-bad-06.ttl new file mode 100644 index 00000000..3952b24b --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-bad-06.ttl @@ -0,0 +1,4 @@ +PREFIX : + +:s :p ("abc") . +<<:s :p ("abc") >> :q 123 . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-bad-07.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-bad-07.ttl new file mode 100644 index 00000000..b1665b48 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-bad-07.ttl @@ -0,0 +1,3 @@ +PREFIX : + +<<:s :p [ :p1 :o1 ] >> :q 123 . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-bad-ann-1.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-bad-ann-1.ttl new file mode 100644 index 00000000..7f654f4e --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-bad-ann-1.ttl @@ -0,0 +1,6 @@ +PREFIX : + +SELECT * { + :s :p :o {| |} . +} + diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-bad-ann-2.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-bad-ann-2.ttl new file mode 100644 index 00000000..1abed88f --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-bad-ann-2.ttl @@ -0,0 +1,3 @@ +PREFIX : + +:a :b :c {| :s :p :o |} . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-basic-01.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-basic-01.ttl new file mode 100644 index 00000000..3874f92e --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-basic-01.ttl @@ -0,0 +1,4 @@ +PREFIX : + +:s :p :o . +<<:s :p :o>> :q 123 . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-basic-02.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-basic-02.ttl new file mode 100644 index 00000000..a2b95e77 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-basic-02.ttl @@ -0,0 +1,4 @@ +PREFIX : + +:s :p :o . +:x :p <<:s :p :o>> . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-basic-03.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-basic-03.ttl new file mode 100644 index 00000000..f338c5fa --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-basic-03.ttl @@ -0,0 +1,3 @@ +PREFIX : + +:s :p <<(:s :p :o )>> . \ No newline at end of file diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-basic-04.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-basic-04.ttl new file mode 100644 index 00000000..8a1fbb38 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-basic-04.ttl @@ -0,0 +1,4 @@ +PREFIX : + +:s :p :o . +<<:s :p :o>> . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-basic-05.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-basic-05.ttl new file mode 100644 index 00000000..b23c537a --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-basic-05.ttl @@ -0,0 +1,4 @@ +PREFIX : + +:s1 :p "abc" . +<<:s1 :p "abc">> . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-basic-06.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-basic-06.ttl new file mode 100644 index 00000000..15d666ef --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-basic-06.ttl @@ -0,0 +1,4 @@ +PREFIX : + +:s1 :p true . +<<:s1 :p true>> . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-basic-07.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-basic-07.ttl new file mode 100644 index 00000000..6f813617 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-basic-07.ttl @@ -0,0 +1,3 @@ +PREFIX : + +:s :p <<( :x :q "abc" )>> . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-basic-08.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-basic-08.ttl new file mode 100644 index 00000000..016bea40 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-basic-08.ttl @@ -0,0 +1,4 @@ +PREFIX : + +:s1 :p true . +:s2 :p <<(:s1 :p true)>> . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-bnode-01.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-bnode-01.ttl new file mode 100644 index 00000000..6591a66e --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-bnode-01.ttl @@ -0,0 +1,4 @@ +PREFIX : + +_:a :p :o . +<<_:a :p :o >> :q 456 . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-bnode-02.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-bnode-02.ttl new file mode 100644 index 00000000..ac99ad73 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-bnode-02.ttl @@ -0,0 +1,4 @@ +PREFIX : + +:s :p _:a . +<<:s :p _:a >> :q 456 . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-bnode-03.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-bnode-03.ttl new file mode 100644 index 00000000..95f8cf5f --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-bnode-03.ttl @@ -0,0 +1,3 @@ +PREFIX : + +<<[] :p [] >> :q :z . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-compound.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-compound.ttl new file mode 100644 index 00000000..df83d970 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-compound.ttl @@ -0,0 +1,11 @@ +PREFIX : + + +:x :r :z . +:a :b :c . +<<:a :b :c>> :r :z . +<<:x :r :z >> :p <<:a :b :c>> . + +<< <<:x :r :z >> :p <<:a :b :c>> >> + :q +<< <<:x :r :z >> :p <<:a :b :c>> >> . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-inside-01.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-inside-01.ttl new file mode 100644 index 00000000..ff87a146 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-inside-01.ttl @@ -0,0 +1,4 @@ +PREFIX : + +:s :p :o . +[ :q <<:s :p :o>> ] :b :c . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-inside-02.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-inside-02.ttl new file mode 100644 index 00000000..28e2590e --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-inside-02.ttl @@ -0,0 +1,5 @@ +PREFIX : + +:s :p :o1 . +:s :p :o2 . +( <<:s :p :o1>> <<:s :p :o2>> ) :q 123 . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-inside-03.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-inside-03.ttl new file mode 100644 index 00000000..8544d367 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-inside-03.ttl @@ -0,0 +1,4 @@ +PREFIX : + +:s :p << :s :p :o1 ~ :id >> . +:id :q 123 . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-inside-04.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-inside-04.ttl new file mode 100644 index 00000000..7baee7db --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-inside-04.ttl @@ -0,0 +1,4 @@ +PREFIX : + +:s :p <<:s :p :o1 ~_:id>> . +_:id :q 123 . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-nested-01.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-nested-01.ttl new file mode 100644 index 00000000..93a936ca --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-nested-01.ttl @@ -0,0 +1,7 @@ +PREFIX : + +:s :p :o . + +<<:s :p :o >> :r :z . + +<< <<:s :p :o >> :r :z >> :q 1 . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-nested-02.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-nested-02.ttl new file mode 100644 index 00000000..aec49ef4 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-syntax-nested-02.ttl @@ -0,0 +1,5 @@ +PREFIX : + +:s :p :o . +:a :q <<:s :p :o >> . +<< :a :q <<:s :p :o >>>> :r :z . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-version-01.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-version-01.ttl new file mode 100644 index 00000000..0b902178 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-version-01.ttl @@ -0,0 +1,4 @@ +VERSION "1.2" +PREFIX : + +:s :p :o . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-version-02.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-version-02.ttl new file mode 100644 index 00000000..e870e5a9 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-version-02.ttl @@ -0,0 +1,4 @@ +@version "1.2" . +@prefix : . + +:s :p :o . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-version-03.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-version-03.ttl new file mode 100644 index 00000000..acce63b6 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-version-03.ttl @@ -0,0 +1,6 @@ +PREFIX : +:s :p :o . + +VERSION "1.2" + +:a :b :c . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-version-04.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-version-04.ttl new file mode 100644 index 00000000..39925bff --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-version-04.ttl @@ -0,0 +1,7 @@ +PREFIX : + +:s :p :o . + +@version "1.2" . + +:a :b :c . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-version-05.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-version-05.ttl new file mode 100644 index 00000000..5472bb1b --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-version-05.ttl @@ -0,0 +1,4 @@ +PREFIX : +VERSION "1.2-basic" + +:s :p :o . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-version-06.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-version-06.ttl new file mode 100644 index 00000000..381ddb1a --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-version-06.ttl @@ -0,0 +1,4 @@ +PREFIX : +@version '1.2-basic' . + +:s :p :o . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-version-07.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-version-07.ttl new file mode 100644 index 00000000..098123b7 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-version-07.ttl @@ -0,0 +1,5 @@ +@version '1.2-basic' . +PREFIX : +VERSION "1.2" + +:s :p :o . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-version-08.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-version-08.ttl new file mode 100644 index 00000000..0b7b5984 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-version-08.ttl @@ -0,0 +1,19 @@ +PREFIX : + +VERSION "1.2" +version "1.2" +@version "1.2" . + +:s :p 1 . + +VERSION '1.2' +version '1.2' +@version '1.2' . + +:s :p 2 . + +VERSION "1.2-basic" +version "1.2-basic" +@version "1.2-basic" . + +:s :p 3 . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-version-bad-01.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-version-bad-01.ttl new file mode 100644 index 00000000..31c59413 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-version-bad-01.ttl @@ -0,0 +1 @@ +VERSION 1.2 diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-version-bad-02.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-version-bad-02.ttl new file mode 100644 index 00000000..4a636ee1 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-version-bad-02.ttl @@ -0,0 +1 @@ +VERSION """1.2""" diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-version-bad-03.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-version-bad-03.ttl new file mode 100644 index 00000000..4d1f1648 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-version-bad-03.ttl @@ -0,0 +1 @@ +VERSION '''1.2''' diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-version-bad-04.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-version-bad-04.ttl new file mode 100644 index 00000000..af864124 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-version-bad-04.ttl @@ -0,0 +1 @@ +@version 1.2 . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-version-bad-05.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-version-bad-05.ttl new file mode 100644 index 00000000..ce7b5d34 --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-version-bad-05.ttl @@ -0,0 +1 @@ +@version """1.2""" . diff --git a/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-version-bad-06.ttl b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-version-bad-06.ttl new file mode 100644 index 00000000..fdfe6f1d --- /dev/null +++ b/src/test/resources/w3c/rdf12/rdf-turtle/syntax/turtle12-version-bad-06.ttl @@ -0,0 +1 @@ +@version '''1.2''' . From ebf35a8f86718b526f038e9444a34348c89e6d1f Mon Sep 17 00:00:00 2001 From: Erich Bremer Date: Thu, 16 Jul 2026 20:05:13 -0400 Subject: [PATCH 3/5] CDT Hardening --- RDF_1.1-compliance.md | 35 ++- README.md | 12 +- docs/INSTRUCTIONS.md | 5 +- .../java/com/ebremer/beakgraph/Params.java | 8 +- .../core/fuseki/DistinctNodeCounter.java | 8 + .../readers/MultiTypeDictionaryReader.java | 20 +- .../writers/MultiTypeDictionaryWriter.java | 31 ++- .../PositionalDictionaryWriterBuilder.java | 8 - .../hdf5/writers/ultra/UltraIngest.java | 8 - .../beakgraph/huge/HugeBuildPipeline.java | 20 +- .../com/ebremer/beakgraph/huge/NodeCodec.java | 31 ++- .../huge/StreamingDictionaryWriter.java | 30 ++- .../beakgraph/DirLangRoundTripTest.java | 94 ++++++++ .../beakgraph/RDF12ContainmentTest.java | 209 ------------------ .../ebremer/beakgraph/TermFidelityTest.java | 14 +- .../ebremer/beakgraph/cmdline/ExportTest.java | 37 ++++ .../beakgraph/huge/DirLangSpillCodecTest.java | 86 +++++++ .../beakgraph/huge/DirLangSpillGuardTest.java | 106 --------- .../beakgraph/w3c/W3CRdf12SuiteTest.java | 25 +-- 19 files changed, 380 insertions(+), 407 deletions(-) create mode 100644 src/test/java/com/ebremer/beakgraph/DirLangRoundTripTest.java delete mode 100644 src/test/java/com/ebremer/beakgraph/RDF12ContainmentTest.java create mode 100644 src/test/java/com/ebremer/beakgraph/huge/DirLangSpillCodecTest.java delete mode 100644 src/test/java/com/ebremer/beakgraph/huge/DirLangSpillGuardTest.java diff --git a/RDF_1.1-compliance.md b/RDF_1.1-compliance.md index 3bcb8bff..3c91f807 100644 --- a/RDF_1.1-compliance.md +++ b/RDF_1.1-compliance.md @@ -54,15 +54,33 @@ The stored dataset is a superset of the source: VoID/SD metadata (`urn:x-beakgra composite literals — whether or not the store supports them, so these terms arrive at the writers regardless. Policy: anything the format cannot represent fails the build loudly.* +> **Conformance claim: BeakGraph is RDF 1.2-basic conformant** (format v4). RDF 1.2 Concepts §2 +> defines basic conformance as supporting graphs/datasets whose triples contain only basic RDF +> terms — i.e. everything except triple terms. BeakGraph stores base-direction literals +> term-exactly, inherits RDF 1.2's case-insensitive language-tag identity from Jena, and rejects +> triple terms loudly (full conformance is planned; PLAN.md Phase 3). +> +> **Evidence:** the vendored W3C RDF 1.2 test suites (rdf-turtle, rdf-n-triples, rdf-n-quads, +> rdf-trig; `W3CRdf12SuiteTest`, suites at commit `d3e844a`): **301 tests — 213 executed, 0 +> failures**; 82 c14n tests skipped as out of scope (canonical serialization is a serializer +> property, not storage), 6 skipped as upstream Jena 6.1.0 lenient-parse divergences (listed in +> `src/test/resources/w3c/rdf12/README.md`). Every eval and positive-syntax test without triple +> terms round-trips through a real store isomorphically; every triple-term test aborts on a loud +> term-kind guard. + - **Triple terms** (`<<( s p o )>>`, and the reifier/annotation sugar that expands to them): rejected with an exception at ingest, as before. Storage is planned (PLAN.md Phase 3). -- **Base-direction literals** (`"x"@en--ltr`, `rdf:dirLangString`): rejected with an exception at - ingest in every writer engine, in both dictionary encoders, and in the disk writers' spill codec - (`RDF12ContainmentTest`, `DirLangSpillGuardTest`). **Versions ≤ 0.17.0 silently stored these as - plain lang-tagged terms** — `"x"@en`, a different RDF term, with nothing recording the change. - `-verify` cannot detect it retroactively (the file is internally consistent; it is just not what - the source said). Rebuilding an affected source under the guarded version fails loudly — that - failure is the detection mechanism. Storage is planned (PLAN.md Phase 2). +- **Base-direction literals** (`"x"@en--ltr`, `rdf:dirLangString`): **stored and matched + term-exactly** as of format v4 — a `langDirs` column (0=none, 1=ltr, 2=rtl) beside the existing + `langs`/`langTags` datasets, mirrored across all six writer engines, the disk writers' spill + codec, the HLL statistics hash, and the export fastpath (`DirLangRoundTripTest`, + `DirLangSpillCodecTest`, `TermFidelityTest`, `ExportTest`). v3 files read unchanged (no + directions); v4 files are rejected by older builds via the format-version gate. + **History: versions ≤ 0.17.0 silently stored these as plain lang-tagged terms** — `"x"@en`, a + different RDF term, with nothing recording the change. `-verify` cannot detect it retroactively + (the file is internally consistent; it is just not what the source said). Rebuilding an affected + source under a guarded or v4 build produces the correct terms — a diff against the old store is + the detection mechanism. - **Language tag case**: Jena 6 normalizes language tags case-insensitively per RDF 1.2 (`"chat"@FR` ≡ `"chat"@fr`); BeakGraph inherits this on both the write and query paths. - **Composite (cdt:) literals** (`cdt:List` / `cdt:Map`; SPARQL-CDT is an Unofficial Draft spec): @@ -91,7 +109,8 @@ regardless. Policy: anything the format cannot represent fails the build loudly. | Blank node semantics | Compliant (isomorphism) | | Datasets / named graphs | Compliant | | Generalized RDF / RDF-star | Rejected loudly (correct for 1.1) | -| RDF 1.2 base-direction literals | Rejected loudly at ingest (storage planned); ≤ 0.17.0 stored them silently corrupted | +| RDF 1.2 base-direction literals | Stored term-exactly (format v4, `langDirs`); ≤ 0.17.0 stored them silently corrupted — rebuild | +| RDF 1.2 conformance level | **Basic** (W3C suites: 213 executed, 0 failures); full pending triple terms | | SPARQL-CDT composite literals | Stored term-exact; lexical dictionary order (≤ 0.17.0 stores need rebuild); embedded blank nodes rejected | | Numeric literal term identity | **Deviation** — canonicalized at ingest | | Absolute-IRI requirement | **Deviation** — relative IRIs stored, resolved at serving time | diff --git a/README.md b/README.md index 9e909d80..ee20b6d2 100644 --- a/README.md +++ b/README.md @@ -87,11 +87,13 @@ Beakgraph's HDF5 design is heavily inspired by [RDF HDT](https://www.rdfhdt.org/ * Numeric literals typed `xsd:int`, `xsd:long`, `xsd:float` or `xsd:double` are stored by value and canonicalized at ingest: `"01"^^xsd:int` is stored - and matched - as `"1"^^xsd:int`. -* RDF 1.2 terms are rejected loudly rather than mis-stored: triple terms - (`<<( s p o )>>`, including the reifier/annotation sugar) and base-direction - literals (`"x"@en--ltr`) abort the build. Versions ≤ 0.17.0 silently stored - base-direction literals as plain `"x"@en` — rebuild affected stores under a - guarded version; the loud failure is the detector. +* RDF 1.2 support is at the spec's **basic conformance** level: base-direction + literals (`"x"@en--ltr`, `rdf:dirLangString`) are stored and matched + term-exactly (format v4 adds a `langDirs` column beside `langs`/`langTags`), + while triple terms (`<<( s p o )>>`, including the reifier/annotation sugar) + are still rejected loudly at ingest. Versions ≤ 0.17.0 silently stored + base-direction literals as plain `"x"@en` — rebuild affected stores; a + version that rejects or correctly stores them is the detector. * SPARQL-CDT composite literals (`cdt:List`/`cdt:Map`) are stored term-exactly and queryable with Jena's `cdt:` functions, `FOLD`, and `UNFOLD`. Caveats: the dictionary orders them lexically, so stores built by ≤ 0.17.0 that diff --git a/docs/INSTRUCTIONS.md b/docs/INSTRUCTIONS.md index 50bde409..20cd528b 100644 --- a/docs/INSTRUCTIONS.md +++ b/docs/INSTRUCTIONS.md @@ -226,7 +226,10 @@ them to validate any tuning against your own store shape. ## 9. Output guarantees -* One HDF5 format, one reader stack, for every method (format version 3). +* One HDF5 format, one reader stack, for every method (format version 4). + v4 adds the optional `langDirs` dataset for RDF 1.2 base-direction literals + (`"x"@en--ltr`); v3 files remain fully readable, while v4 files are rejected + by older builds with an "Upgrade BeakGraph" error. * Methods 0/2/3 produce **structurally identical** stores for the same single source (same datasets, sizes, attributes); methods 1/4 produce **isomorphic** stores (blank-node labels are rank-derived rather than relabelled). diff --git a/src/main/java/com/ebremer/beakgraph/Params.java b/src/main/java/com/ebremer/beakgraph/Params.java index 470b0762..56d3f886 100644 --- a/src/main/java/com/ebremer/beakgraph/Params.java +++ b/src/main/java/com/ebremer/beakgraph/Params.java @@ -22,7 +22,13 @@ public class Params { // ones-before-block-k) and widened the superblock entries to the bitmap length. // The query path now uses that directory for O(log n) select1, so files written // at v1/v2 (whose directory is incompatible) fall back to a linear select1 scan. - public static final int FORMAT_VERSION = 3; + // + // v4: added the optional langDirs dataset beside langs/langTags (per-node + // base direction for rdf:dirLangString literals; 0=none 1=ltr 2=rtl). + // Absence means "no directions", so v3 files read unchanged; v4 files are + // rejected by older builds via the gate above - without that, an old build + // would silently reconstruct "x"@en--ltr as "x"@en (a different RDF term). + public static final int FORMAT_VERSION = 4; // First format version whose rank/select directory is correct enough to drive // query navigation. Older files fall back to a linear select1 scan (slower but correct). public static final int RANK_DIRECTORY_MIN_VERSION = 3; diff --git a/src/main/java/com/ebremer/beakgraph/core/fuseki/DistinctNodeCounter.java b/src/main/java/com/ebremer/beakgraph/core/fuseki/DistinctNodeCounter.java index c77895b9..7a2783e5 100644 --- a/src/main/java/com/ebremer/beakgraph/core/fuseki/DistinctNodeCounter.java +++ b/src/main/java/com/ebremer/beakgraph/core/fuseki/DistinctNodeCounter.java @@ -4,6 +4,7 @@ import java.util.Set; import java.util.concurrent.ConcurrentHashMap; import org.apache.jena.graph.Node; +import org.apache.jena.graph.TextDirection; /** * Distinct-node counter with a bounded footprint: EXACT (a concurrent set of @@ -83,6 +84,13 @@ static long hash(Node n) { if (lang != null && !lang.isEmpty()) { h = h * 31 + poly(23, lang); } + // Base direction is part of term identity (rdf:dirLangString): + // without this, "x"@en--ltr and "x"@en--rtl hash together and the + // HLL undercounts distinct objects. + TextDirection dir = n.getLiteralBaseDirection(); + if (dir != null) { + h = h * 31 + (dir == TextDirection.LTR ? 37 : 41); + } } else { h = poly(29, n.toString()); } diff --git a/src/main/java/com/ebremer/beakgraph/hdf5/readers/MultiTypeDictionaryReader.java b/src/main/java/com/ebremer/beakgraph/hdf5/readers/MultiTypeDictionaryReader.java index 81a45f07..95714c53 100644 --- a/src/main/java/com/ebremer/beakgraph/hdf5/readers/MultiTypeDictionaryReader.java +++ b/src/main/java/com/ebremer/beakgraph/hdf5/readers/MultiTypeDictionaryReader.java @@ -14,6 +14,7 @@ import java.util.stream.Stream; import org.apache.jena.datatypes.TypeMapper; import org.apache.jena.graph.Node; +import org.apache.jena.graph.TextDirection; import org.apache.jena.graph.NodeFactory; import org.apache.jena.sparql.expr.NodeValue; @@ -44,6 +45,10 @@ public class MultiTypeDictionaryReader extends AbstractDictionary { // language-tag support, so those reconstruct exactly as before. private final FCDReader langs; private final BitPackedUnSignedLongBuffer langTags; + // rdf:dirLangString (format v4): per-node base direction, 0=none 1=ltr 2=rtl. + // Null for files written before direction support - those reconstruct + // exactly as before. + private final BitPackedUnSignedLongBuffer langDirs; private final long numEntries; private final String name; @@ -96,6 +101,8 @@ public MultiTypeDictionaryReader(Group d) { this.langs = (langsG != null) ? new FCDReader(langsG) : null; ContiguousDataset langTagsDS = (ContiguousDataset) d.getChild("langTags"); this.langTags = (langTagsDS != null) ? BitPackedUnSignedLongBuffer.readView(DatasetBytes.of(langTagsDS), (Long) langTagsDS.getAttribute("numEntries").getData(), (Integer) langTagsDS.getAttribute("width").getData()) : null; + ContiguousDataset langDirsDS = (ContiguousDataset) d.getChild("langDirs"); + this.langDirs = (langDirsDS != null) ? BitPackedUnSignedLongBuffer.readView(DatasetBytes.of(langDirsDS), (Long) langDirsDS.getAttribute("numEntries").getData(), (Integer) langDirsDS.getAttribute("width").getData()) : null; } private TieredIndex tieredIndex() { @@ -151,7 +158,18 @@ public Node extract(long id) { // as a lang-tagged literal (term-exact per RDF semantics). long langId = (langTags != null) ? langTags.get(idx) : 0; if (langId > 0 && langs != null) { - yield NodeFactory.createLiteralLang(strings.get(off), langs.get(langId - 1)); + String lex = strings.get(off); + String lang = langs.get(langId - 1); + // Base direction (format v4): one extra bit-packed read, only + // when the store has directional literals at all. A direction + // implies a language tag, so this stays inside the lang branch + // and the short-circuit past the datatype id is preserved. + long dirId = (langDirs != null) ? langDirs.get(idx) : 0; + if (dirId > 0) { + yield NodeFactory.createLiteralDirLang(lex, lang, + dirId == 1 ? TextDirection.LTR : TextDirection.RTL); + } + yield NodeFactory.createLiteralLang(lex, lang); } long dtId = typedLiterals.get(idx); if (dtId < 1) throw new RuntimeException("Corrupt HDF5: missing typed-literal datatype id at ID " + id); diff --git a/src/main/java/com/ebremer/beakgraph/hdf5/writers/MultiTypeDictionaryWriter.java b/src/main/java/com/ebremer/beakgraph/hdf5/writers/MultiTypeDictionaryWriter.java index 20151e02..460214a5 100644 --- a/src/main/java/com/ebremer/beakgraph/hdf5/writers/MultiTypeDictionaryWriter.java +++ b/src/main/java/com/ebremer/beakgraph/hdf5/writers/MultiTypeDictionaryWriter.java @@ -28,6 +28,7 @@ import org.slf4j.LoggerFactory; import static com.ebremer.beakgraph.utils.UTIL.isRelativeIRI; import org.apache.jena.graph.Node; +import org.apache.jena.graph.TextDirection; import org.apache.jena.vocabulary.XSD; /** @@ -54,6 +55,11 @@ public class MultiTypeDictionaryWriter implements DictionaryWriter, Dictionary, // Both are null when the source has no language-tagged literals. private final FCDWriter langs; private final BitPackedUnSignedLongBuffer langTags; + // rdf:dirLangString support (format v4): a per-node base-direction buffer + // (0 = none, 1 = ltr, 2 = rtl). The domain is closed, so no dictionary is + // needed. Null when the source has no base-direction literals - absence + // means "no directions", which is what keeps v3 files readable unchanged. + private final BitPackedUnSignedLongBuffer langDirs; private final HashMap langLookUp = new HashMap<>(); private String name; private final ArrayList sorted; @@ -109,6 +115,7 @@ protected MultiTypeDictionaryWriter(Builder builder) throws FileNotFoundExceptio FCDWriter tempStrings = null; FCDWriter tempLangs = null; BitPackedUnSignedLongBuffer tempLangTags = null; + BitPackedUnSignedLongBuffer tempLangDirs = null; try { this.doubles = (!et.contains(Types.DOUBLE) || (stats.numDouble == 0)) ? null : new DataOutputBuffer(Path.of("doubles")); this.floats = (!et.contains(Types.FLOAT) || (stats.numFloat == 0)) ? null : new DataOutputBuffer(Path.of("floats")); @@ -141,10 +148,12 @@ protected MultiTypeDictionaryWriter(Builder builder) throws FileNotFoundExceptio // without language-tagged strings carry no langs/langTags datasets. if (tempLiteralsPresent) { java.util.TreeSet langSet = new java.util.TreeSet<>(); + boolean anyDirection = false; for (Node n : sorted) { if (n.isLiteral()) { String lang = n.getLiteralLanguage(); if (lang != null && !lang.isEmpty()) langSet.add(lang); + if (n.getLiteralBaseDirection() != null) anyDirection = true; } } if (!langSet.isEmpty()) { @@ -155,6 +164,9 @@ protected MultiTypeDictionaryWriter(Builder builder) throws FileNotFoundExceptio } tempLangTags = new BitPackedUnSignedLongBuffer(Path.of("langTags"), null, 0, 1 + MinBits(langSet.size())); } + if (anyDirection) { + tempLangDirs = new BitPackedUnSignedLongBuffer(Path.of("langDirs"), null, 0, 1 + MinBits(2)); + } } } catch (IOException ex) { @@ -175,6 +187,7 @@ protected MultiTypeDictionaryWriter(Builder builder) throws FileNotFoundExceptio this.strings = tempStrings; this.langs = tempLangs; this.langTags = tempLangTags; + this.langDirs = tempLangDirs; // --- STEP 3: Encode Data --- this.sorted.forEach(this::addNodeInternal); @@ -201,6 +214,7 @@ private void addNodeInternal(Node node) { offsets.writeLong(0); if (literalsPresent) typedLiterals.writeLong(0); if (langTags != null) langTags.writeLong(0); + if (langDirs != null) langDirs.writeLong(0); } else if (node.isURI()) { try { @@ -210,6 +224,7 @@ else if (node.isURI()) { iri.add(node.getURI()); if (literalsPresent) typedLiterals.writeLong(0); if (langTags != null) langTags.writeLong(0); + if (langDirs != null) langDirs.writeLong(0); } catch (IOException ex) { // Continuing after a failed iri.add() would leave the offsets and // datatypes buffers one entry ahead of the IRI dictionary, silently @@ -218,16 +233,6 @@ else if (node.isURI()) { } } else if (node.isLiteral()) { - // Defence in depth behind the ingest guards: a base-direction literal - // ("x"@en--ltr, rdf:dirLangString) has no direction storage here and - // would silently encode as its plain lang-tagged counterpart - a - // different RDF term. Throw before any buffer write so no partial - // entry desynchronizes the parallel arrays. - if (node.getLiteralBaseDirection() != null) { - throw new IllegalStateException( - "Unsupported literal in dictionary '" + name - + "' (rdf:dirLangString base direction cannot be stored): " + node); - } String dt = node.getLiteralDatatypeURI(); long dtId = dataTypesLookUp.getOrDefault(dt, 0L); if (literalsPresent) typedLiterals.writeLong(dtId); @@ -235,6 +240,10 @@ else if (node.isLiteral()) { String lang = node.getLiteralLanguage(); langTags.writeLong((lang == null || lang.isEmpty()) ? 0L : langLookUp.getOrDefault(lang, 0L)); } + if (langDirs != null) { + TextDirection dir = node.getLiteralBaseDirection(); + langDirs.writeLong((dir == null) ? 0L : (dir == TextDirection.LTR ? 1L : 2L)); + } // An ill-typed literal ("abc"^^xsd:int) has no parseable value but is a // valid RDF term: route it to the strings branch below (term-exact, with // its datatype IRI) instead of aborting the build here. ProcessQuad @@ -328,6 +337,7 @@ public void close() throws Exception { if (strings != null) strings.close(); if (langs != null) langs.close(); if (langTags != null) langTags.prepareForReading(); + if (langDirs != null) langDirs.prepareForReading(); } @Override public long getNumberOfNodes() { return sorted.size(); } @@ -352,6 +362,7 @@ public void add(WritableGroup group) { if (strings != null) strings.add(subGroup); if (langs != null && langs.getNumEntries() > 0) langs.add(subGroup); if (langTags != null) langTags.add(subGroup); + if (langDirs != null) langDirs.add(subGroup); if (nativedatatypes.getNumEntries() > 0) nativedatatypes.add(subGroup); } diff --git a/src/main/java/com/ebremer/beakgraph/hdf5/writers/PositionalDictionaryWriterBuilder.java b/src/main/java/com/ebremer/beakgraph/hdf5/writers/PositionalDictionaryWriterBuilder.java index aeecc5b9..d11cf980 100644 --- a/src/main/java/com/ebremer/beakgraph/hdf5/writers/PositionalDictionaryWriterBuilder.java +++ b/src/main/java/com/ebremer/beakgraph/hdf5/writers/PositionalDictionaryWriterBuilder.java @@ -612,14 +612,6 @@ private void ProcessQuad(Quad quad) { predicates.add(p); } if (o.isLiteral()) { - // An RDF 1.2 base-direction literal ("x"@en--ltr, rdf:dirLangString): - // the format has nowhere to store the direction, so the term would be - // silently rewritten to "x"@en on read-back - a different RDF term. - // Fail the build loudly instead, same stance as the node-kind guards. - if (o.getLiteralBaseDirection() != null) { - throw new IllegalStateException( - "Unsupported object literal (rdf:dirLangString base direction cannot be stored): " + o); - } if (!literals.contains(o)) { // Blank nodes inside a composite (cdt:) literal: labels regenerate // from dictionary rank, so the label in the literal's text would diff --git a/src/main/java/com/ebremer/beakgraph/hdf5/writers/ultra/UltraIngest.java b/src/main/java/com/ebremer/beakgraph/hdf5/writers/ultra/UltraIngest.java index 829df8d7..edef1b6b 100644 --- a/src/main/java/com/ebremer/beakgraph/hdf5/writers/ultra/UltraIngest.java +++ b/src/main/java/com/ebremer/beakgraph/hdf5/writers/ultra/UltraIngest.java @@ -360,14 +360,6 @@ private void buildSets(ForkJoinPool pool) throws IOException { entities.add(s); predicates.add(p); if (o.isLiteral()) { - // Same guard as the sequential ProcessQuad: a base-direction - // literal ("x"@en--ltr, rdf:dirLangString) has nowhere to - // store its direction and would silently collapse onto the - // plain lang-tagged term. Abort the build loudly instead. - if (o.getLiteralBaseDirection() != null) { - throw new IllegalStateException( - "Unsupported object literal (rdf:dirLangString base direction cannot be stored): " + o); - } // Same guard as the sequential ProcessQuad: blank nodes inside a // composite (cdt:) literal would silently stop co-referring after // rank relabeling. add() gates the parse to once per distinct. diff --git a/src/main/java/com/ebremer/beakgraph/huge/HugeBuildPipeline.java b/src/main/java/com/ebremer/beakgraph/huge/HugeBuildPipeline.java index c1990aee..fc3bbf10 100644 --- a/src/main/java/com/ebremer/beakgraph/huge/HugeBuildPipeline.java +++ b/src/main/java/com/ebremer/beakgraph/huge/HugeBuildPipeline.java @@ -86,6 +86,9 @@ public final class HugeBuildPipeline implements AutoCloseable { private final Stats stats = new Stats(); private final TreeSet dataTypes = new TreeSet<>(); private final TreeSet langSet = new TreeSet<>(); + // True when any literal carries a base direction (rdf:dirLangString) - + // gates the langDirs column, exactly as langSet gates langs/langTags. + private boolean langDirSeen = false; // Predicates are the one population kept in RAM (real-world predicate counts // are tiny next to entities/literals); they get temp ids during the parse // and final rank ids once the set is complete. @@ -275,7 +278,7 @@ public void run(Path tmpH5) throws IOException { () -> { if (numEntities > 0) { dicts[0] = track(new StreamingDictionaryWriter(workDir, "entities", numEntities, stats, - Set.of(Types.IRI, Types.BNODE), new TreeSet<>(), new TreeSet<>())); + Set.of(Types.IRI, Types.BNODE), new TreeSet<>(), new TreeSet<>(), false)); try (var s = entFile.read()) { dicts[0].encode(s); } @@ -284,7 +287,7 @@ public void run(Path tmpH5) throws IOException { () -> { if (numPredicates > 0) { dicts[1] = track(new StreamingDictionaryWriter(workDir, "predicates", numPredicates, stats, - Set.of(Types.IRI), new TreeSet<>(), new TreeSet<>())); + Set.of(Types.IRI), new TreeSet<>(), new TreeSet<>(), false)); dicts[1].encode(Arrays.asList(sortedPreds).iterator()); } }, @@ -292,7 +295,7 @@ public void run(Path tmpH5) throws IOException { if (numLiterals > 0) { dicts[2] = track(new StreamingDictionaryWriter(workDir, "literals", numLiterals, stats, Set.of(Types.DOUBLE, Types.FLOAT, Types.LONG, Types.INTEGER, Types.STRING), - dataTypes, langSet)); + dataTypes, langSet, langDirSeen)); try (var s = litFile.read()) { dicts[2].encode(s); } @@ -584,14 +587,6 @@ private void countEntityKind(Node n, String position) { * and buffer-allocation gates consume. */ private void collectLiteralStats(Node o) { - // Same guard as ProcessQuad: a base-direction literal ("x"@en--ltr, - // rdf:dirLangString) has nowhere to store its direction here, and the - // spill codec (NodeCodec) would silently collapse it onto the plain - // lang-tagged term mid-build. Abort the build loudly instead. - if (o.getLiteralBaseDirection() != null) { - throw new IllegalStateException( - "Unsupported object literal (rdf:dirLangString base direction cannot be stored): " + o); - } // Same guard as ProcessQuad: blank nodes inside a composite (cdt:) literal // would silently stop co-referring after rank relabeling. This pipeline // has no distinct-literal set, so the check runs per occurrence - it @@ -605,6 +600,9 @@ private void collectLiteralStats(Node o) { String lang = o.getLiteralLanguage(); if (lang != null && !lang.isEmpty()) { langSet.add(lang); + if (o.getLiteralBaseDirection() != null) { + langDirSeen = true; + } } if (dt.equals(XSD.xlong.getURI())) { if (literalValueOrNull(o) instanceof Number n) { diff --git a/src/main/java/com/ebremer/beakgraph/huge/NodeCodec.java b/src/main/java/com/ebremer/beakgraph/huge/NodeCodec.java index e8ab0ea2..7117e7c9 100644 --- a/src/main/java/com/ebremer/beakgraph/huge/NodeCodec.java +++ b/src/main/java/com/ebremer/beakgraph/huge/NodeCodec.java @@ -6,6 +6,7 @@ import java.nio.charset.StandardCharsets; import org.apache.jena.datatypes.TypeMapper; import org.apache.jena.graph.Node; +import org.apache.jena.graph.TextDirection; import org.apache.jena.graph.NodeFactory; /** @@ -17,8 +18,7 @@ * parsed original. * *

Node kinds the BeakGraph format cannot store (RDF-star triple terms, - * variables, base-direction literals) fail loudly here, matching the RAM - * writer's ProcessQuad guards. + * variables) fail loudly here, matching the RAM writer's ProcessQuad guards. * * @author Erich Bremer */ @@ -31,6 +31,7 @@ public final class NodeCodec implements ExternalSorter.Codec { private static final byte T_BNODE = 1; private static final byte T_LITERAL_DT = 2; private static final byte T_LITERAL_LANG = 3; + private static final byte T_LITERAL_DIRLANG = 4; private NodeCodec() {} @@ -52,16 +53,14 @@ public static void writeNode(DataOutput out, Node n) throws IOException { out.writeByte(T_BNODE); writeString(out, n.getBlankNodeLabel()); } else if (n.isLiteral()) { - // A base-direction literal ("x"@en--ltr, rdf:dirLangString) would be - // serialized as its plain lang-tagged counterpart and deserialize to - // a DIFFERENT term - breaking this codec's round-trip contract and - // collapsing the two terms mid-build. Fail loudly before the tag byte. - if (n.getLiteralBaseDirection() != null) { - throw new IllegalStateException( - "Unsupported literal in huge writer spill (rdf:dirLangString base direction cannot be stored): " + n); - } + TextDirection dir = n.getLiteralBaseDirection(); String lang = n.getLiteralLanguage(); - if (lang != null && !lang.isEmpty()) { + if (dir != null) { + out.writeByte(T_LITERAL_DIRLANG); + writeString(out, n.getLiteralLexicalForm()); + writeString(out, lang); + out.writeByte(dir == TextDirection.LTR ? 1 : 2); + } else if (lang != null && !lang.isEmpty()) { out.writeByte(T_LITERAL_LANG); writeString(out, n.getLiteralLexicalForm()); writeString(out, lang); @@ -92,6 +91,16 @@ public static Node readNode(DataInput in) throws IOException { String lang = readString(in); yield NodeFactory.createLiteralLang(lex, lang); } + case T_LITERAL_DIRLANG -> { + String lex = readString(in); + String lang = readString(in); + byte dir = in.readByte(); + if (dir != 1 && dir != 2) { + throw new IOException("Corrupt spill record: base direction " + dir); + } + yield NodeFactory.createLiteralDirLang(lex, lang, + dir == 1 ? TextDirection.LTR : TextDirection.RTL); + } default -> throw new IOException("Corrupt spill record: unknown node tag " + tag); }; } diff --git a/src/main/java/com/ebremer/beakgraph/huge/StreamingDictionaryWriter.java b/src/main/java/com/ebremer/beakgraph/huge/StreamingDictionaryWriter.java index aa4016f7..9cc8f880 100644 --- a/src/main/java/com/ebremer/beakgraph/huge/StreamingDictionaryWriter.java +++ b/src/main/java/com/ebremer/beakgraph/huge/StreamingDictionaryWriter.java @@ -14,6 +14,7 @@ import java.util.Set; import java.util.SortedSet; import org.apache.jena.graph.Node; +import org.apache.jena.graph.TextDirection; import org.apache.jena.vocabulary.XSD; import org.slf4j.Logger; import org.slf4j.LoggerFactory; @@ -53,6 +54,10 @@ final class StreamingDictionaryWriter implements AutoCloseable { private final SpillFCDWriter typedLiteralsDictionary; private final SpillFCDWriter langs; private final SpillBitPackedBuffer langTags; + // rdf:dirLangString (format v4): per-node base direction, 0=none 1=ltr 2=rtl. + // Mirror of MultiTypeDictionaryWriter.langDirs; null when no directional + // literal exists, so v3-shaped files stay byte-identical. + private final SpillBitPackedBuffer langDirs; private final HashMap dataTypesLookUp = new HashMap<>(); private final HashMap langLookUp = new HashMap<>(); private final boolean literalsPresent; @@ -65,9 +70,12 @@ final class StreamingDictionaryWriter implements AutoCloseable { * @param dataTypes distinct literal datatype IRIs (natural String order), * empty for dictionaries without literals * @param langSet distinct language tags among the literals, natural order + * @param anyLangDir true when at least one literal carries a base direction + * (rdf:dirLangString); allocates the langDirs column */ StreamingDictionaryWriter(Path workDir, String name, long nodeCount, Stats stats, - Set et, SortedSet dataTypes, SortedSet langSet) + Set et, SortedSet dataTypes, SortedSet langSet, + boolean anyLangDir) throws IOException { this.name = name; this.nodeCount = nodeCount; @@ -131,6 +139,9 @@ final class StreamingDictionaryWriter implements AutoCloseable { this.langs = null; this.langTags = null; } + this.langDirs = (literalsPresent && anyLangDir) + ? new SpillBitPackedBuffer(dictDir.resolve("langDirs"), 1 + MinBits(2)) + : null; } /** Encodes the sorted distinct node stream; must deliver exactly {@code nodeCount} nodes. */ @@ -152,6 +163,7 @@ private void addNodeInternal(Node node) { offsets.writeLong(0); if (literalsPresent) typedLiterals.writeLong(0); if (langTags != null) langTags.writeLong(0); + if (langDirs != null) langDirs.writeLong(0); } else if (node.isURI()) { try { boolean relative = isRelativeIRI(node.getURI()); @@ -160,18 +172,11 @@ private void addNodeInternal(Node node) { iri.add(node.getURI()); if (literalsPresent) typedLiterals.writeLong(0); if (langTags != null) langTags.writeLong(0); + if (langDirs != null) langDirs.writeLong(0); } catch (IOException ex) { throw new UncheckedIOException("Failed to add IRI to dictionary: " + node, ex); } } else if (node.isLiteral()) { - // Mirror of MultiTypeDictionaryWriter: base-direction literals have no - // direction storage - throw before any buffer write (see that class - // for the full rationale). - if (node.getLiteralBaseDirection() != null) { - throw new IllegalStateException( - "Unsupported literal in dictionary '" + name - + "' (rdf:dirLangString base direction cannot be stored): " + node); - } String dt = node.getLiteralDatatypeURI(); long dtId = dataTypesLookUp.getOrDefault(dt, 0L); if (literalsPresent) typedLiterals.writeLong(dtId); @@ -179,6 +184,10 @@ private void addNodeInternal(Node node) { String lang = node.getLiteralLanguage(); langTags.writeLong((lang == null || lang.isEmpty()) ? 0L : langLookUp.getOrDefault(lang, 0L)); } + if (langDirs != null) { + TextDirection dir = node.getLiteralBaseDirection(); + langDirs.writeLong((dir == null) ? 0L : (dir == TextDirection.LTR ? 1L : 2L)); + } Object val; try { val = node.getLiteralValue(); @@ -241,6 +250,7 @@ private void completeAll() throws IOException { if (floats != null) floats.complete(); if (doubles != null) doubles.complete(); if (langTags != null) langTags.complete(); + if (langDirs != null) langDirs.complete(); } long getNumberOfNodes() { @@ -261,6 +271,7 @@ void transferTo(StreamingHdf5Group group) throws IOException { if (strings != null) strings.transferTo(subGroup); if (langs != null && langs.getNumEntries() > 0) langs.transferTo(subGroup); if (langTags != null) langTags.transferTo(subGroup, "langTags"); + if (langDirs != null) langDirs.transferTo(subGroup, "langDirs"); if (nativedatatypes.getNumEntries() > 0) nativedatatypes.transferTo(subGroup, "datatypes"); } @@ -278,5 +289,6 @@ public void close() throws IOException { if (typedLiteralsDictionary != null) typedLiteralsDictionary.close(); if (langs != null) langs.close(); if (langTags != null) langTags.close(); + if (langDirs != null) langDirs.close(); } } diff --git a/src/test/java/com/ebremer/beakgraph/DirLangRoundTripTest.java b/src/test/java/com/ebremer/beakgraph/DirLangRoundTripTest.java new file mode 100644 index 00000000..615ed8bb --- /dev/null +++ b/src/test/java/com/ebremer/beakgraph/DirLangRoundTripTest.java @@ -0,0 +1,94 @@ +package com.ebremer.beakgraph; + +import static org.junit.jupiter.api.Assertions.assertEquals; +import static org.junit.jupiter.api.Assertions.assertTrue; + +import com.ebremer.beakgraph.core.BeakGraph; +import java.io.File; +import java.nio.file.Files; +import java.nio.file.Path; +import java.util.Set; +import java.util.TreeSet; +import java.util.stream.Stream; +import org.apache.jena.graph.Node; +import org.apache.jena.graph.NodeFactory; +import org.apache.jena.graph.TextDirection; +import org.apache.jena.query.Dataset; +import org.junit.jupiter.api.io.TempDir; +import org.junit.jupiter.params.ParameterizedTest; +import org.junit.jupiter.params.provider.MethodSource; + +/** + * RDF 1.2 base-direction literals (rdf:dirLangString) round-trip term-exactly + * through every writer engine (format v4: the langDirs column beside + * langs/langTags). This REPLACES the Phase 0 containment test + * (RDF12ContainmentTest), per that test's stated lifecycle: rejection guards + * out, term-exact round-trip in. + * + *

The fixture is the exact trio from the original corruption finding - + * three distinct terms sharing one lexical form, which versions ≤ 0.17.0 + * silently collapsed onto plain "hello"@en (3 terms in, 1 term out). + */ +class DirLangRoundTripTest { + + private static final String TTL = """ + @prefix : . + :s :p "hello"@en--ltr . + :s :q "hello"@en--rtl . + :s :r "hello"@en . + :s :t "shalom"@he--rtl . + """; + + @TempDir + static Path dir; + + static Stream engines() { + return WriterEngines.all(); + } + + @ParameterizedTest(name = "{0}") + @MethodSource("engines") + void baseDirectionLiteralsRoundTripTermExactly(WriterEngines.Engine engine) throws Exception { + engine.assumeAvailable(); + Path src = dir.resolve(engine.name() + ".ttl"); + Files.writeString(src, TTL); + File dest = dir.resolve(engine.name() + ".h5").toFile(); + engine.buildStore(src.toFile(), dest); + + try (BeakGraph bg = BG.getBeakGraph(dest)) { + Dataset ds = bg.getDataset(); + + Set stored = new TreeSet<>(); + ds.getDefaultModel().listStatements().forEachRemaining(st -> { + Node n = st.getObject().asNode(); + stored.add(n.getLiteralLexicalForm() + "@" + n.getLiteralLanguage() + + "--" + n.getLiteralBaseDirection()); + }); + assertEquals(new TreeSet<>(Set.of( + "hello@en--ltr", + "hello@en--rtl", + "hello@en--null", + "shalom@he--rtl")), stored, + "the three same-lexical-form terms must stay distinct, with directions intact"); + + // Term lookup, not just enumeration: locate() must resolve the exact + // dirLangString term through the dictionary binary search. + Node ltr = NodeFactory.createLiteralDirLang("hello", "en", TextDirection.LTR); + Node rtl = NodeFactory.createLiteralDirLang("hello", "en", TextDirection.RTL); + Node plain = NodeFactory.createLiteralLang("hello", "en"); + var m = ds.getDefaultModel(); + var g = m.getGraph(); + assertTrue(g.contains(Node.ANY, + NodeFactory.createURI("http://ex.org/p"), ltr), "locate(hello@en--ltr)"); + assertTrue(g.contains(Node.ANY, + NodeFactory.createURI("http://ex.org/q"), rtl), "locate(hello@en--rtl)"); + assertTrue(g.contains(Node.ANY, + NodeFactory.createURI("http://ex.org/r"), plain), "locate(hello@en)"); + // And the cross-checks: the WRONG variant must not match. + assertTrue(!g.contains(Node.ANY, + NodeFactory.createURI("http://ex.org/p"), rtl), "p must not match the rtl term"); + assertTrue(!g.contains(Node.ANY, + NodeFactory.createURI("http://ex.org/r"), ltr), "r must not match the ltr term"); + } + } +} diff --git a/src/test/java/com/ebremer/beakgraph/RDF12ContainmentTest.java b/src/test/java/com/ebremer/beakgraph/RDF12ContainmentTest.java deleted file mode 100644 index d4807d04..00000000 --- a/src/test/java/com/ebremer/beakgraph/RDF12ContainmentTest.java +++ /dev/null @@ -1,209 +0,0 @@ -package com.ebremer.beakgraph; - -import static org.junit.jupiter.api.Assertions.assertEquals; -import static org.junit.jupiter.api.Assertions.assertNull; -import static org.junit.jupiter.api.Assertions.assertThrows; -import static org.junit.jupiter.api.Assertions.assertTrue; - -import com.ebremer.beakgraph.core.BeakGraph; -import com.ebremer.beakgraph.core.BeakGraphWriter; -import com.ebremer.beakgraph.core.lib.Stats; -import com.ebremer.beakgraph.hdf5.Types; -import com.ebremer.beakgraph.hdf5.writers.HDF5Writer; -import com.ebremer.beakgraph.hdf5.writers.MultiTypeDictionaryWriter; -import com.ebremer.beakgraph.hdf5.writers.hugeUltra.HugeUltraHDF5Writer; -import com.ebremer.beakgraph.hdf5.writers.parallel.ParallelHDF5Writer; -import com.ebremer.beakgraph.hdf5.writers.plaid.PlaidHDF5Writer; -import com.ebremer.beakgraph.hdf5.writers.ultra.UltraHDF5Writer; -import com.ebremer.beakgraph.huge.HugeHDF5Writer; -import com.ebremer.beakgraph.huge.NativeHdf5File; -import java.io.File; -import java.nio.file.Files; -import java.nio.file.Path; -import java.util.HashSet; -import java.util.List; -import java.util.Set; -import java.util.stream.Stream; -import org.apache.jena.graph.Node; -import org.apache.jena.graph.NodeFactory; -import org.apache.jena.query.Dataset; -import org.apache.jena.vocabulary.RDF; -import org.junit.jupiter.api.Assumptions; -import org.junit.jupiter.api.Test; -import org.junit.jupiter.api.io.TempDir; -import org.junit.jupiter.params.ParameterizedTest; -import org.junit.jupiter.params.provider.Arguments; -import org.junit.jupiter.params.provider.MethodSource; - -/** - * RDF 1.2 containment: Jena 6.x parses base-direction literals ("x"@en--ltr, - * rdf:dirLangString) by default, but the BeakGraph format has nowhere to store - * the direction - before the ingest guards, such a term was silently rewritten - * to "x"@en (a DIFFERENT RDF term; three distinct source terms collapsed onto - * one). These tests pin the containment stance: a source containing a - * base-direction literal must fail the build loudly, in every writer engine, - * and must not publish a store. - * - *

When real rdf:dirLangString storage lands (a langDirs column beside - * langs/langTags), the rejection guards are removed and these tests are - * REPLACED by term-exact round-trip tests - do not delete them without that - * replacement. - */ -class RDF12ContainmentTest { - - private static final String BAD_TTL = """ - @prefix : . - :s :p "x"@en--ltr . - :s :q "plain"@en . - """; - - private static final String GOOD_TTL = """ - @prefix : . - :s :q "plain"@en . - :s :r "untagged" . - """; - - private static final String GUARD_MESSAGE = "base direction cannot be stored"; - - @TempDir - static Path dir; - - @FunctionalInterface - interface Engine { - BeakGraphWriter create(File src, File dest) throws Exception; - } - - static Stream engines() { - return Stream.of( - Arguments.of("method0-HDF5Writer", false, (Engine) (src, dest) -> - HDF5Writer.Builder().setSource(src).setDestination(dest).build()), - Arguments.of("method1-Huge", true, (Engine) (src, dest) -> { - HugeHDF5Writer.Builder b = HugeHDF5Writer.Builder().setDestination(dest); - b.setSource(src); - return b.build(); - }), - Arguments.of("method2-Parallel", false, (Engine) (src, dest) -> { - ParallelHDF5Writer.Builder b = ParallelHDF5Writer.Builder() - .setDestination(dest).setCores(2); - b.setSource(src); - return b.build(); - }), - Arguments.of("method3-Ultra", false, (Engine) (src, dest) -> { - UltraHDF5Writer.Builder b = UltraHDF5Writer.Builder() - .setDestination(dest).setCores(2); - b.setSource(src); - return b.build(); - }), - Arguments.of("method4-HugeUltra", true, (Engine) (src, dest) -> { - HugeUltraHDF5Writer.Builder b = HugeUltraHDF5Writer.Builder() - .setDestination(dest).setCores(2); - b.setSource(src); - return b.build(); - }), - Arguments.of("method5-Plaid", true, (Engine) (src, dest) -> { - PlaidHDF5Writer.Builder b = PlaidHDF5Writer.Builder() - .setDestination(dest).setCores(2); - b.setSource(src); - return b.build(); - }) - ); - } - - @ParameterizedTest(name = "{0}") - @MethodSource("engines") - void baseDirectionLiteralAbortsTheBuild(String name, boolean needsNative, Engine engine) throws Exception { - Assumptions.assumeTrue(!needsNative || NativeHdf5File.isAvailable(), - "native HDF5 library unavailable"); - Path src = dir.resolve(name + "-bad.ttl"); - Files.writeString(src, BAD_TTL); - File dest = dir.resolve(name + "-bad.h5").toFile(); - - Exception ex = assertThrows(Exception.class, - () -> engine.create(src.toFile(), dest).write()); - assertTrue(chainMentionsGuard(ex), - "build failed, but not on the base-direction guard: " + ex); - assertNoUsableStore(dest); - } - - @Test - void plainLanguageTagsStillBuildAndRoundTrip() throws Exception { - Path src = dir.resolve("good.ttl"); - Files.writeString(src, GOOD_TTL); - File dest = dir.resolve("good.h5").toFile(); - HDF5Writer.Builder().setSource(src.toFile()).setDestination(dest).build().write(); - assertControlRoundTrips(dest); - } - - @Test - void plainLanguageTagsStillBuildAndRoundTripUltra() throws Exception { - Path src = dir.resolve("good-ultra.ttl"); - Files.writeString(src, GOOD_TTL); - File dest = dir.resolve("good-ultra.h5").toFile(); - UltraHDF5Writer.Builder b = UltraHDF5Writer.Builder().setDestination(dest).setCores(2); - b.setSource(src.toFile()); - b.build().write(); - assertControlRoundTrips(dest); - } - - /** The dictionary encoder's own guard, driven directly (bypasses the ingest guards). */ - @Test - void multiTypeDictionaryWriterRejectsBaseDirectionLiteral() { - Stats stats = new Stats(); - stats.numStrings = 1; - stats.longestStringLength = 5; - stats.shortestStringLength = 5; - Node bad = NodeFactory.createLiteralDirLang("hello", "en", "ltr"); - IllegalStateException ex = assertThrows(IllegalStateException.class, () -> - new MultiTypeDictionaryWriter.Builder() - .enable(Types.STRING, Types.INTEGER, Types.LONG, Types.FLOAT, Types.DOUBLE) - .setStats(stats) - .setNodes(new HashSet<>(Set.of(bad))) - .setDataTypes(Set.of(RDF.dirLangString.getURI())) - .setName("literals") - .build()); - assertTrue(ex.getMessage().contains(GUARD_MESSAGE), ex.getMessage()); - } - - // ---- helpers ---- - - private static boolean chainMentionsGuard(Throwable t) { - for (Throwable c = t; c != null; c = c.getCause()) { - if (c.getMessage() != null && c.getMessage().contains(GUARD_MESSAGE)) { - return true; - } - } - return false; - } - - /** - * "Not silently store": the aborted build must not publish a readable store. - * Writers build into a sibling *.tmp and publish by atomic rename, so the - * destination normally does not exist; if some engine left a file behind, - * it must at least not open as a BeakGraph. - */ - private static void assertNoUsableStore(File dest) { - if (!dest.exists()) { - return; - } - assertThrows(Exception.class, () -> { - try (BeakGraph bg = BG.getBeakGraph(dest)) { - bg.getDataset(); - } - }, "a store was published from a build that should have aborted"); - } - - private static void assertControlRoundTrips(File dest) throws Exception { - Node expected = NodeFactory.createLiteralLang("plain", "en"); - try (BeakGraph bg = BG.getBeakGraph(dest)) { - Dataset ds = bg.getDataset(); - List objects = ds.getDefaultModel() - .listObjectsOfProperty(ds.getDefaultModel() - .createProperty("http://ex.org/q")) - .mapWith(o -> o.asNode()).toList(); - assertEquals(1, objects.size()); - assertEquals(expected, objects.get(0)); - assertNull(objects.get(0).getLiteralBaseDirection(), - "a plain lang tag must carry no base direction"); - } - } -} diff --git a/src/test/java/com/ebremer/beakgraph/TermFidelityTest.java b/src/test/java/com/ebremer/beakgraph/TermFidelityTest.java index cbf202e3..d23cb1e7 100644 --- a/src/test/java/com/ebremer/beakgraph/TermFidelityTest.java +++ b/src/test/java/com/ebremer/beakgraph/TermFidelityTest.java @@ -34,12 +34,13 @@ * datatype (canonical spellings only - non-canonical spellings are a * documented deviation), the term-exact strings path (unbounded integers, * decimals, dates, booleans), value-equal-but-term-distinct pairs, unicode - * with surrogate pairs, a string past the zstd compression threshold, and - * composite (cdt:) literals. Named graphs use IRI and blank-node names. + * with surrogate pairs, a string past the zstd compression threshold, + * composite (cdt:) literals, and base-direction literals (rdf:dirLangString, + * format v4 - including the same-lexical-form ltr/rtl/absent trio). Named + * graphs use IRI and blank-node names. * - *

Phases 2 and 3 extend THIS fixture (base-direction literals, - * triple terms) - one place, six engines covered, instead of touching five - * parity tests. + *

Phase 3 extends THIS fixture (triple terms) - one place, six + * engines covered, instead of touching five parity tests. */ class TermFidelityTest { @@ -58,6 +59,9 @@ class TermFidelityTest { :s :lang "hello"@en . :s :lang "hello"@en-GB . :s :lang "bonjour"@fr . + :s :dl "hello"@en--ltr . + :s :dl "hello"@en--rtl . + :s :dl "shalom"@he--rtl . :s :int "42"^^xsd:int . :s :int "-7"^^xsd:int . :s :long2 "123456789012"^^xsd:long . diff --git a/src/test/java/com/ebremer/beakgraph/cmdline/ExportTest.java b/src/test/java/com/ebremer/beakgraph/cmdline/ExportTest.java index 0b3b4b6f..f2e0ca07 100644 --- a/src/test/java/com/ebremer/beakgraph/cmdline/ExportTest.java +++ b/src/test/java/com/ebremer/beakgraph/cmdline/ExportTest.java @@ -86,6 +86,43 @@ void ntExportRoundTripsAndExcludesInternalGraphs() throws Exception { "VoID/spatial metadata graphs must not leak into the export"); } + @Test + void ntExportPreservesBaseDirectionOnBothPaths() throws Exception { + // rdf:dirLangString (format v4): the fastpath's NodeFormatterNT and the + // generic StreamRDF writer must both emit the @lang--dir form, and stay + // byte-identical to each other (the fastpath's documented contract). + String dirTriples = + " \"hello\"@en--ltr .\n" + + " \"shalom\"@he--rtl .\n" + + " \"hello\"@en .\n"; + File h5 = buildStore("dirs", dirTriples); + Path out = dir.resolve("dirs.nt"); + + runExport(h5, "NT", false); + byte[] fastpath = Files.readAllBytes(out); + String text = new String(fastpath, StandardCharsets.UTF_8); + assertTrue(text.contains("\"hello\"@en--ltr") && text.contains("\"shalom\"@he--rtl"), + "fastpath export must emit base directions:\n" + text); + + Files.delete(out); + System.setProperty("beakgraph.export.fastpath", "false"); + try { + runExport(h5, "NT", false); + } finally { + System.clearProperty("beakgraph.export.fastpath"); + } + byte[] generic = Files.readAllBytes(out); + org.junit.jupiter.api.Assertions.assertArrayEquals(fastpath, generic, + "fastpath must stay byte-identical to the generic writer"); + + Dataset ds = parse(out, Lang.NTRIPLES, false); + Model expected = ModelFactory.createDefaultModel(); + RDFDataMgr.read(expected, new java.io.ByteArrayInputStream( + dirTriples.getBytes(StandardCharsets.UTF_8)), Lang.NTRIPLES); + assertTrue(ds.getDefaultModel().isIsomorphicWith(expected), + "exported base-direction literals must round-trip term-exactly"); + } + @Test void ntUpgradesToNqWhenNamedGraphsExist() throws Exception { File h5 = buildStore("upg", QUADS); diff --git a/src/test/java/com/ebremer/beakgraph/huge/DirLangSpillCodecTest.java b/src/test/java/com/ebremer/beakgraph/huge/DirLangSpillCodecTest.java new file mode 100644 index 00000000..73b9ca8f --- /dev/null +++ b/src/test/java/com/ebremer/beakgraph/huge/DirLangSpillCodecTest.java @@ -0,0 +1,86 @@ +package com.ebremer.beakgraph.huge; + +import static org.junit.jupiter.api.Assertions.assertEquals; + +import com.ebremer.beakgraph.core.lib.Stats; +import com.ebremer.beakgraph.hdf5.Types; +import java.io.ByteArrayInputStream; +import java.io.ByteArrayOutputStream; +import java.io.DataInputStream; +import java.io.DataOutputStream; +import java.io.IOException; +import java.nio.file.Path; +import java.util.List; +import java.util.Set; +import java.util.TreeSet; +import org.apache.jena.datatypes.TypeMapper; +import org.apache.jena.graph.Node; +import org.apache.jena.graph.NodeFactory; +import org.apache.jena.graph.TextDirection; +import org.apache.jena.vocabulary.RDF; +import org.junit.jupiter.api.Test; +import org.junit.jupiter.api.io.TempDir; + +/** + * The disk pipeline's handling of rdf:dirLangString, driven directly. This + * REPLACES DirLangSpillGuardTest per its stated lifecycle: with format v4 the + * spill codec carries the direction (tag T_LITERAL_DIRLANG) and the streaming + * dictionary encoder writes the langDirs column, so the former rejection + * assertions become exact round-trip assertions - the codec's "term identity + * is preserved" contract now genuinely covers base direction. + */ +class DirLangSpillCodecTest { + + @TempDir + static Path dir; + + private static Node roundTrip(Node n) throws IOException { + ByteArrayOutputStream bos = new ByteArrayOutputStream(); + NodeCodec.writeNode(new DataOutputStream(bos), n); + return NodeCodec.readNode(new DataInputStream(new ByteArrayInputStream(bos.toByteArray()))); + } + + private static Stats stringStats() { + Stats s = new Stats(); + s.numStrings = 1; + s.longestStringLength = 6; + s.shortestStringLength = 5; + return s; + } + + @Test + void nodeCodecRoundTripsBaseDirectionExactly() throws IOException { + Node ltr = NodeFactory.createLiteralDirLang("hello", "en", TextDirection.LTR); + Node rtl = NodeFactory.createLiteralDirLang("shalom", "he", TextDirection.RTL); + assertEquals(ltr, roundTrip(ltr)); + assertEquals(rtl, roundTrip(rtl)); + } + + @Test + void nodeCodecStillRoundTripsOrdinaryTermsExactly() throws IOException { + Node lang = NodeFactory.createLiteralLang("hello", "en"); + Node typed = NodeFactory.createLiteralDT("42", + TypeMapper.getInstance().getSafeTypeByName("http://www.w3.org/2001/XMLSchema#integer")); + Node uri = NodeFactory.createURI("http://ex.org/a"); + Node bnode = NodeFactory.createBlankNode("b1"); + assertEquals(lang, roundTrip(lang)); + assertEquals(typed, roundTrip(typed)); + assertEquals(uri, roundTrip(uri)); + assertEquals(bnode, roundTrip(bnode)); + } + + @Test + void streamingDictionaryWriterEncodesBaseDirectionLiterals() throws Exception { + Node ltr = NodeFactory.createLiteralDirLang("hello", "en", TextDirection.LTR); + Node plain = NodeFactory.createLiteralLang("hello", "en"); + // NodeComparator order within the language block: (lang, lex, direction), + // absent < ltr - so the plain term encodes first. + try (StreamingDictionaryWriter w = new StreamingDictionaryWriter( + dir.resolve("dirs"), "literals", 2, stringStats(), + Set.of(Types.STRING, Types.INTEGER, Types.LONG, Types.FLOAT, Types.DOUBLE), + new TreeSet<>(Set.of(RDF.dirLangString.getURI(), RDF.langString.getURI())), + new TreeSet<>(Set.of("en")), true)) { + w.encode(List.of(plain, ltr).iterator()); + } + } +} diff --git a/src/test/java/com/ebremer/beakgraph/huge/DirLangSpillGuardTest.java b/src/test/java/com/ebremer/beakgraph/huge/DirLangSpillGuardTest.java deleted file mode 100644 index 0e4ba356..00000000 --- a/src/test/java/com/ebremer/beakgraph/huge/DirLangSpillGuardTest.java +++ /dev/null @@ -1,106 +0,0 @@ -package com.ebremer.beakgraph.huge; - -import static org.junit.jupiter.api.Assertions.assertEquals; -import static org.junit.jupiter.api.Assertions.assertThrows; -import static org.junit.jupiter.api.Assertions.assertTrue; - -import com.ebremer.beakgraph.core.lib.Stats; -import com.ebremer.beakgraph.hdf5.Types; -import java.io.ByteArrayInputStream; -import java.io.ByteArrayOutputStream; -import java.io.DataInputStream; -import java.io.DataOutputStream; -import java.io.IOException; -import java.nio.file.Path; -import java.util.List; -import java.util.Set; -import java.util.TreeSet; -import org.apache.jena.datatypes.TypeMapper; -import org.apache.jena.graph.Node; -import org.apache.jena.graph.NodeFactory; -import org.apache.jena.vocabulary.RDF; -import org.junit.jupiter.api.Test; -import org.junit.jupiter.api.io.TempDir; - -/** - * The disk pipeline's guards against RDF 1.2 base-direction literals - * (rdf:dirLangString), driven directly - the ingest guards normally fire - * first, so these layers are unreachable end-to-end by design: - *

    - *
  • {@link NodeCodec}: before its guard, "x"@en--ltr serialized as - * {@code T_LITERAL_LANG (lex, lang)} and deserialized as "x"@en - two - * distinct terms collapsed inside the external sort, falsifying the - * codec's "term identity is preserved" contract.
  • - *
  • {@link StreamingDictionaryWriter}: same collapse at encode time - * (mirror of MultiTypeDictionaryWriter's guard).
  • - *
- */ -class DirLangSpillGuardTest { - - private static final String GUARD_MESSAGE = "base direction cannot be stored"; - - @TempDir - static Path dir; - - private static Node roundTrip(Node n) throws IOException { - ByteArrayOutputStream bos = new ByteArrayOutputStream(); - NodeCodec.writeNode(new DataOutputStream(bos), n); - return NodeCodec.readNode(new DataInputStream(new ByteArrayInputStream(bos.toByteArray()))); - } - - private static Stats stringStats() { - Stats s = new Stats(); - s.numStrings = 1; - s.longestStringLength = 5; - s.shortestStringLength = 5; - return s; - } - - @Test - void nodeCodecRejectsBaseDirectionLiteral() { - Node bad = NodeFactory.createLiteralDirLang("hello", "en", "ltr"); - IllegalStateException ex = assertThrows(IllegalStateException.class, () -> - NodeCodec.writeNode(new DataOutputStream(new ByteArrayOutputStream()), bad)); - assertTrue(ex.getMessage().contains(GUARD_MESSAGE), ex.getMessage()); - } - - @Test - void nodeCodecRoundTripsOrdinaryTermsExactly() throws IOException { - Node lang = NodeFactory.createLiteralLang("hello", "en"); - Node typed = NodeFactory.createLiteralDT("42", - TypeMapper.getInstance().getSafeTypeByName("http://www.w3.org/2001/XMLSchema#integer")); - Node uri = NodeFactory.createURI("http://ex.org/a"); - Node bnode = NodeFactory.createBlankNode("b1"); - assertEquals(lang, roundTrip(lang)); - assertEquals(typed, roundTrip(typed)); - assertEquals(uri, roundTrip(uri)); - assertEquals(bnode, roundTrip(bnode)); - } - - @Test - void streamingDictionaryWriterRejectsBaseDirectionLiteral() { - Node bad = NodeFactory.createLiteralDirLang("hello", "en", "ltr"); - IllegalStateException ex = assertThrows(IllegalStateException.class, () -> { - try (StreamingDictionaryWriter w = new StreamingDictionaryWriter( - dir.resolve("reject"), "literals", 1, stringStats(), - Set.of(Types.STRING, Types.INTEGER, Types.LONG, Types.FLOAT, Types.DOUBLE), - new TreeSet<>(Set.of(RDF.dirLangString.getURI())), - new TreeSet<>(Set.of("en")))) { - w.encode(List.of(bad).iterator()); - } - }); - assertTrue(ex.getMessage().contains(GUARD_MESSAGE), ex.getMessage()); - } - - @Test - void streamingDictionaryWriterEncodesPlainLangTag() throws Exception { - Node good = NodeFactory.createLiteralLang("hello", "en"); - try (StreamingDictionaryWriter w = new StreamingDictionaryWriter( - dir.resolve("control"), "literals", 1, stringStats(), - Set.of(Types.STRING, Types.INTEGER, Types.LONG, Types.FLOAT, Types.DOUBLE), - new TreeSet<>(Set.of(RDF.langString.getURI())), - new TreeSet<>(Set.of("en")))) { - w.encode(List.of(good).iterator()); - } - } -} diff --git a/src/test/java/com/ebremer/beakgraph/w3c/W3CRdf12SuiteTest.java b/src/test/java/com/ebremer/beakgraph/w3c/W3CRdf12SuiteTest.java index bdd19852..083c4ab9 100644 --- a/src/test/java/com/ebremer/beakgraph/w3c/W3CRdf12SuiteTest.java +++ b/src/test/java/com/ebremer/beakgraph/w3c/W3CRdf12SuiteTest.java @@ -36,13 +36,13 @@ * Manifest-driven runner for the vendored W3C RDF 1.2 test suites * (src/test/resources/w3c/rdf12 - see its README for provenance). * - *

BeakGraph currently rejects RDF 1.2 terms it cannot store (triple terms, - * base-direction literals), so the runner asserts CONTAINMENT semantics: a - * test input containing unsupported terms must abort the build loudly; inputs - * without them must build and round-trip isomorphically. When Phases 2/3 land - * real storage, {@link #containsUnsupportedTerms} shrinks and the same - * manifests become the conformance oracle - no test code changes needed for - * new manifest entries. + *

BeakGraph rejects the RDF 1.2 terms it cannot yet store (triple terms - + * base-direction literals are storable as of format v4), so the runner asserts + * CONTAINMENT semantics for those: a test input containing unsupported terms + * must abort the build loudly; everything else must build and round-trip + * isomorphically. When Phase 3 lands triple-term storage, + * {@link #containsUnsupportedTerms} empties and the same manifests become the + * conformance oracle - no test code changes needed for new manifest entries. * *

Per test type: *

    @@ -193,17 +193,14 @@ private static Lang resultLang(Path result) { } private static boolean containsUnsupportedTerms(DatasetGraph dsg) { + // Base-direction literals became storable in format v4 (Phase 2), so + // only triple terms remain unsupported; Phase 3 empties this method and + // the whole suite becomes a pure conformance oracle. Iterator it = dsg.find(Node.ANY, Node.ANY, Node.ANY, Node.ANY); while (it.hasNext()) { Quad q = it.next(); for (Node n : new Node[]{q.getGraph(), q.getSubject(), q.getPredicate(), q.getObject()}) { - if (n == null) { - continue; - } - if (n.isTripleTerm()) { - return true; - } - if (n.isLiteral() && n.getLiteralBaseDirection() != null) { + if (n != null && n.isTripleTerm()) { return true; } } From 05fe80d614383258debbda3ef27d4d9a12f33b99 Mon Sep 17 00:00:00 2001 From: Erich Bremer Date: Thu, 16 Jul 2026 20:32:22 -0400 Subject: [PATCH 4/5] CDT Hardening part 2 --- README.md | 19 +- docs/INSTRUCTIONS.md | 6 +- .../beakgraph/core/BGDatasetGraph.java | 4 + .../com/ebremer/beakgraph/core/BeakGraph.java | 6 + .../beakgraph/hdf5/jena/SimpleNodeTable.java | 23 +- .../beakgraph/hdf5/readers/HDF5Reader.java | 9 + .../readers/MultiTypeDictionaryReader.java | 7 +- .../readers/PositionalDictionaryReader.java | 34 +- .../ebremer/beakgraph/CdtHardeningTest.java | 166 + .../beakgraph/cdt/SparqlCdtSuiteTest.java | 279 ++ .../ebremer/beakgraph/cmdline/ExportTest.java | 37 + .../fuseki/DistinctNodeCounterCdtTest.java | 50 + src/test/resources/sparql-cdts/LICENSE | 175 + src/test/resources/sparql-cdts/NOTICE | 1 + src/test/resources/sparql-cdts/README.md | 13 + .../resources/sparql-cdts/tests/README.md | 12 + .../bnodes/bnodes-export-rdf-01-construct.rq | 10 + .../tests/bnodes/bnodes-export-rdf-01.rq | 8 + .../tests/bnodes/bnodes-export-service-01.rq | 11 + .../tests/bnodes/bnodes-sparql-01.rq | 13 + .../tests/bnodes/bnodes-sparql-02.rq | 13 + .../tests/bnodes/bnodes-sparql-03.rq | 13 + .../tests/bnodes/bnodes-sparql-04.rq | 13 + .../tests/bnodes/bnodes-sparql-05.rq | 14 + .../tests/bnodes/bnodes-sparql-06.rq | 14 + .../tests/bnodes/bnodes-sparql-07.rq | 14 + .../tests/bnodes/bnodes-sparql-08.rq | 14 + .../tests/bnodes/bnodes-sparql-09.rq | 14 + .../tests/bnodes/bnodes-sparql-11.rq | 14 + .../tests/bnodes/bnodes-sparql-12.rq | 14 + .../tests/bnodes/bnodes-sparql-13.rq | 14 + .../tests/bnodes/bnodes-sparql-14.rq | 14 + .../tests/bnodes/bnodes-sparql-15.rq | 15 + .../tests/bnodes/bnodes-sparql-16.rq | 15 + .../tests/bnodes/bnodes-sparql-17.rq | 15 + .../tests/bnodes/bnodes-sparql-18.rq | 15 + .../tests/bnodes/bnodes-sparql-21.rq | 14 + .../tests/bnodes/bnodes-sparql-22.rq | 14 + .../tests/bnodes/bnodes-sparql-23.rq | 14 + .../tests/bnodes/bnodes-sparql-24.rq | 14 + .../tests/bnodes/bnodes-sparql-25.rq | 15 + .../tests/bnodes/bnodes-sparql-26.rq | 15 + .../tests/bnodes/bnodes-sparql-27.rq | 15 + .../tests/bnodes/bnodes-sparql-28.rq | 15 + .../tests/bnodes/bnodes-turtle-01.rq | 13 + .../tests/bnodes/bnodes-turtle-01.ttl | 7 + .../tests/bnodes/bnodes-turtle-02.rq | 13 + .../tests/bnodes/bnodes-turtle-02.ttl | 7 + .../tests/bnodes/bnodes-turtle-03.rq | 13 + .../tests/bnodes/bnodes-turtle-03.ttl | 7 + .../tests/bnodes/bnodes-turtle-04.rq | 13 + .../tests/bnodes/bnodes-turtle-04.ttl | 7 + .../tests/bnodes/bnodes-turtle-05.rq | 12 + .../tests/bnodes/bnodes-turtle-05.ttl | 7 + .../tests/bnodes/bnodes-turtle-06.rq | 12 + .../tests/bnodes/bnodes-turtle-06.ttl | 7 + .../tests/bnodes/bnodes-turtle-07.rq | 12 + .../tests/bnodes/bnodes-turtle-07.ttl | 7 + .../tests/bnodes/bnodes-turtle-08.rq | 12 + .../tests/bnodes/bnodes-turtle-08.ttl | 7 + .../tests/bnodes/bnodes-turtle-09.rq | 14 + .../tests/bnodes/bnodes-turtle-09.ttl | 8 + .../tests/bnodes/bnodes-turtle-10.rq | 14 + .../tests/bnodes/bnodes-turtle-10.ttl | 8 + .../tests/bnodes/bnodes-turtle-11.rq | 14 + .../tests/bnodes/bnodes-turtle-11.ttl | 8 + .../tests/bnodes/bnodes-turtle-12.rq | 14 + .../tests/bnodes/bnodes-turtle-12.ttl | 8 + .../tests/bnodes/bnodes-turtle-13.rq | 14 + .../tests/bnodes/bnodes-turtle-13.ttl | 8 + .../tests/bnodes/bnodes-turtle-14.rq | 14 + .../tests/bnodes/bnodes-turtle-14.ttl | 8 + .../tests/bnodes/bnodes-turtle-15.rq | 14 + .../tests/bnodes/bnodes-turtle-15a.ttl | 7 + .../tests/bnodes/bnodes-turtle-15b.ttl | 7 + .../tests/bnodes/bnodes-turtle-16.rq | 14 + .../tests/bnodes/bnodes-turtle-16a.ttl | 7 + .../tests/bnodes/bnodes-turtle-16b.ttl | 7 + .../tests/bnodes/bnodes-turtle-17.rq | 13 + .../tests/bnodes/bnodes-turtle-17a.ttl | 7 + .../tests/bnodes/bnodes-turtle-17b.ttl | 7 + .../tests/bnodes/bnodes-turtle-18.rq | 13 + .../tests/bnodes/bnodes-turtle-18a.ttl | 7 + .../tests/bnodes/bnodes-turtle-18b.ttl | 7 + .../tests/bnodes/bnodes-turtle-19.rq | 14 + .../tests/bnodes/bnodes-turtle-19a.ttl | 7 + .../tests/bnodes/bnodes-turtle-19b.ttl | 7 + .../tests/bnodes/bnodes-turtle-21.rq | 14 + .../tests/bnodes/bnodes-turtle-21.ttl | 7 + .../tests/bnodes/bnodes-turtle-22.rq | 14 + .../tests/bnodes/bnodes-turtle-22.ttl | 7 + .../tests/bnodes/bnodes-turtle-23.rq | 14 + .../tests/bnodes/bnodes-turtle-23.ttl | 7 + .../tests/bnodes/bnodes-turtle-24.rq | 14 + .../tests/bnodes/bnodes-turtle-24.ttl | 7 + .../tests/bnodes/bnodes-turtle-25.rq | 13 + .../tests/bnodes/bnodes-turtle-25.ttl | 7 + .../tests/bnodes/bnodes-turtle-26.rq | 13 + .../tests/bnodes/bnodes-turtle-26.ttl | 7 + .../tests/bnodes/bnodes-turtle-27.rq | 13 + .../tests/bnodes/bnodes-turtle-27.ttl | 7 + .../tests/bnodes/bnodes-turtle-28.rq | 13 + .../tests/bnodes/bnodes-turtle-28.ttl | 7 + .../tests/bnodes/bnodes-turtle-29.rq | 15 + .../tests/bnodes/bnodes-turtle-29.ttl | 8 + .../tests/bnodes/bnodes-turtle-30.rq | 15 + .../tests/bnodes/bnodes-turtle-30.ttl | 8 + .../tests/bnodes/bnodes-turtle-31.rq | 15 + .../tests/bnodes/bnodes-turtle-31.ttl | 8 + .../tests/bnodes/bnodes-turtle-32.rq | 15 + .../tests/bnodes/bnodes-turtle-32.ttl | 8 + .../tests/bnodes/bnodes-turtle-41.ttl | 7 + .../tests/bnodes/bnodes-turtle-42.ttl | 7 + .../tests/bnodes/bnodes-turtle-43.ttl | 7 + .../tests/bnodes/bnodes-turtle-44.ttl | 7 + .../tests/bnodes/bnodes-turtle-45.ttl | 7 + .../tests/bnodes/bnodes-turtle-46.ttl | 7 + .../tests/bnodes/bnodes-turtle-47.ttl | 7 + .../tests/bnodes/bnodes-turtle-48.ttl | 7 + .../tests/bnodes/bnodes-turtle-49.ttl | 8 + .../tests/bnodes/bnodes-turtle-50.ttl | 8 + .../tests/bnodes/bnodes-turtle-51.ttl | 8 + .../tests/bnodes/bnodes-turtle-52.ttl | 8 + .../tests/bnodes/bnodes-turtle-sparql-01.rq | 14 + .../tests/bnodes/bnodes-turtle-sparql-01.ttl | 7 + .../tests/bnodes/bnodes-turtle-sparql-02.rq | 14 + .../tests/bnodes/bnodes-turtle-sparql-02.ttl | 7 + .../tests/bnodes/bnodes-turtle-sparql-03.rq | 13 + .../tests/bnodes/bnodes-turtle-sparql-03.ttl | 7 + .../tests/bnodes/bnodes-turtle-sparql-04.rq | 13 + .../tests/bnodes/bnodes-turtle-sparql-04.ttl | 7 + .../sparql-cdts/tests/bnodes/empty.ttl | 0 .../sparql-cdts/tests/bnodes/manifest.ttl | 803 ++++ .../sparql-cdts/tests/bnodes/true.srx | 5 + .../sparql-cdts/tests/fold/empty.ttl | 0 .../sparql-cdts/tests/fold/fold-list-01.rq | 11 + .../sparql-cdts/tests/fold/fold-list-02.rq | 11 + .../sparql-cdts/tests/fold/fold-list-03.rq | 15 + .../sparql-cdts/tests/fold/fold-list-04.rq | 21 + .../sparql-cdts/tests/fold/fold-list-05.rq | 24 + .../tests/fold/fold-list-distinct-01.rq | 11 + .../tests/fold/fold-list-distinct-02.rq | 18 + .../tests/fold/fold-list-distinct-03.rq | 18 + .../tests/fold/fold-list-distinct-04.rq | 21 + .../tests/fold/fold-list-distinct-05.rq | 21 + .../tests/fold/fold-list-distinct-06.rq | 21 + .../tests/fold/fold-list-distinct-07.rq | 22 + .../tests/fold/fold-list-distinct-08.rq | 22 + .../fold/fold-list-distinct-orderby-01.rq | 31 + .../fold/fold-list-distinct-orderby-02.rq | 22 + .../fold/fold-list-distinct-orderby-03.rq | 40 + .../tests/fold/fold-list-orderby-01.rq | 11 + .../tests/fold/fold-list-orderby-02.rq | 11 + .../tests/fold/fold-list-orderby-03.rq | 15 + .../tests/fold/fold-list-orderby-04.rq | 18 + .../tests/fold/fold-list-orderby-05.rq | 15 + .../tests/fold/fold-list-orderby-06.rq | 16 + .../sparql-cdts/tests/fold/fold-map-01.rq | 11 + .../sparql-cdts/tests/fold/fold-map-02.rq | 15 + .../sparql-cdts/tests/fold/fold-map-03.rq | 19 + .../sparql-cdts/tests/fold/fold-map-04.rq | 15 + .../sparql-cdts/tests/fold/fold-map-05.rq | 19 + .../sparql-cdts/tests/fold/fold-map-06.rq | 15 + .../tests/fold/fold-map-orderby-01.rq | 16 + .../tests/fold/fold-map-orderby-02.rq | 16 + .../sparql-cdts/tests/fold/manifest.ttl | 354 ++ .../resources/sparql-cdts/tests/fold/true.srx | 5 + .../tests/list-functions/concat-01.rq | 8 + .../tests/list-functions/concat-02.rq | 10 + .../tests/list-functions/concat-03.rq | 10 + .../tests/list-functions/concat-04.rq | 9 + .../tests/list-functions/concat-05.rq | 9 + .../tests/list-functions/concat-06.rq | 10 + .../tests/list-functions/concat-07.rq | 10 + .../tests/list-functions/concat-08.rq | 8 + .../tests/list-functions/concat-09.rq | 9 + .../tests/list-functions/concat-10.rq | 10 + .../tests/list-functions/concat-error-01.rq | 8 + .../tests/list-functions/concat-error-02.rq | 7 + .../tests/list-functions/concat-null-01.rq | 14 + .../tests/list-functions/contains-01.rq | 8 + .../tests/list-functions/contains-02.rq | 8 + .../tests/list-functions/contains-03.rq | 22 + .../tests/list-functions/contains-04.rq | 8 + .../tests/list-functions/contains-05.rq | 11 + .../tests/list-functions/contains-06.rq | 11 + .../tests/list-functions/contains-07.rq | 11 + .../tests/list-functions/contains-08.rq | 11 + .../tests/list-functions/contains-09.rq | 12 + .../tests/list-functions/contains-10.rq | 12 + .../tests/list-functions/contains-error-01.rq | 8 + .../tests/list-functions/contains-null-01.rq | 9 + .../tests/list-functions/empty.ttl | 0 .../tests/list-functions/get-01.rq | 7 + .../tests/list-functions/get-02.rq | 8 + .../tests/list-functions/get-03.rq | 7 + .../tests/list-functions/get-04.rq | 8 + .../tests/list-functions/get-05.rq | 8 + .../tests/list-functions/get-06.rq | 11 + .../tests/list-functions/get-07.rq | 9 + .../tests/list-functions/get-08.rq | 10 + .../tests/list-functions/get-09.rq | 9 + .../tests/list-functions/get-10.rq | 9 + .../tests/list-functions/get-11.rq | 12 + .../tests/list-functions/get-12.rq | 12 + .../tests/list-functions/get-13.rq | 12 + .../tests/list-functions/get-error-01.rq | 7 + .../tests/list-functions/get-error-02.rq | 7 + .../tests/list-functions/get-error-03.rq | 7 + .../tests/list-functions/get-error-04.rq | 7 + .../tests/list-functions/get-error-05.rq | 7 + .../tests/list-functions/get-error-06.rq | 7 + .../tests/list-functions/get-null-01.rq | 7 + .../tests/list-functions/get-null-02.rq | 7 + .../tests/list-functions/head-01.rq | 8 + .../tests/list-functions/head-02.rq | 7 + .../tests/list-functions/head-03.rq | 7 + .../tests/list-functions/head-04.rq | 7 + .../tests/list-functions/head-05.rq | 7 + .../tests/list-functions/head-06.rq | 7 + .../tests/list-functions/head-07.rq | 8 + .../tests/list-functions/head-08.rq | 7 + .../tests/list-functions/head-09.rq | 7 + .../tests/list-functions/head-10.rq | 8 + .../tests/list-functions/head-11.rq | 8 + .../tests/list-functions/head-12.rq | 11 + .../tests/list-functions/head-error-01.rq | 8 + .../tests/list-functions/head-null-01.rq | 7 + .../tests/list-functions/head-null-02.rq | 7 + .../list-functions/list-constructor-01.rq | 7 + .../list-functions/list-constructor-02.rq | 8 + .../list-functions/list-constructor-03.rq | 8 + .../list-functions/list-constructor-04.rq | 8 + .../list-functions/list-constructor-05.rq | 8 + .../list-functions/list-constructor-06.rq | 8 + .../list-functions/list-constructor-09.rq | 8 + .../list-functions/list-constructor-10.rq | 8 + .../list-functions/list-constructor-11.rq | 8 + .../list-functions/list-constructor-12.rq | 12 + .../list-functions/list-constructor-13.rq | 9 + .../list-functions/list-constructor-14.rq | 8 + .../list-functions/list-constructor-15.rq | 9 + .../list-functions/list-constructor-16.rq | 12 + .../list-constructor-null-01.rq | 12 + .../list-constructor-null-02.rq | 12 + .../tests/list-functions/list-equals-01.rq | 6 + .../tests/list-functions/list-equals-02.rq | 6 + .../tests/list-functions/list-equals-03.rq | 6 + .../tests/list-functions/list-equals-04.rq | 6 + .../tests/list-functions/list-equals-05.rq | 6 + .../tests/list-functions/list-equals-06.rq | 7 + .../tests/list-functions/list-equals-07.rq | 7 + .../tests/list-functions/list-equals-08.rq | 9 + .../tests/list-functions/list-equals-09.rq | 8 + .../list-functions/list-equals-null-01.rq | 7 + .../list-functions/list-equals-null-02.rq | 8 + .../list-functions/list-greater-equal-01.rq | 8 + .../list-functions/list-greater-equal-02.rq | 8 + .../list-functions/list-greater-equal-03.rq | 8 + .../list-functions/list-greater-equal-04.rq | 8 + .../list-functions/list-greater-equal-05.rq | 8 + .../list-functions/list-greater-equal-06.rq | 8 + .../list-functions/list-greater-equal-07.rq | 8 + .../list-functions/list-greater-equal-08.rq | 8 + .../list-functions/list-greater-equal-09.rq | 8 + .../list-functions/list-greater-equal-10.rq | 8 + .../list-functions/list-greater-equal-11.rq | 8 + .../list-functions/list-greater-equal-12.rq | 8 + .../list-functions/list-greater-equal-13.rq | 8 + .../list-functions/list-greater-equal-14.rq | 8 + .../list-functions/list-greater-equal-15.rq | 8 + .../list-functions/list-greater-equal-16.rq | 8 + .../list-functions/list-greater-equal-19.rq | 8 + .../list-functions/list-greater-equal-20.rq | 8 + .../list-functions/list-greater-equal-21.rq | 8 + .../list-functions/list-greater-equal-22.rq | 8 + .../list-functions/list-greater-equal-23.rq | 8 + .../list-functions/list-greater-equal-24.rq | 8 + .../list-functions/list-greater-equal-25.rq | 8 + .../list-functions/list-greater-equal-26.rq | 8 + .../list-functions/list-greater-equal-27.rq | 9 + .../list-functions/list-greater-equal-28.rq | 7 + .../list-functions/list-greater-equal-29.rq | 8 + .../list-functions/list-greater-equal-31.rq | 8 + .../list-greater-equal-error-03.rq | 8 + .../list-greater-equal-error-04.rq | 8 + .../list-greater-equal-null-01.rq | 8 + .../list-greater-equal-null-02.rq | 8 + .../list-greater-equal-null-03.rq | 7 + .../list-greater-equal-null-04.rq | 11 + .../list-greater-equal-null-05.rq | 8 + .../list-greater-equal-null-06.rq | 9 + .../list-functions/list-greater-than-01.rq | 8 + .../list-functions/list-greater-than-02.rq | 8 + .../list-functions/list-greater-than-03.rq | 8 + .../list-functions/list-greater-than-04.rq | 8 + .../list-functions/list-greater-than-05.rq | 8 + .../list-functions/list-greater-than-06.rq | 8 + .../list-functions/list-greater-than-07.rq | 8 + .../list-functions/list-greater-than-08.rq | 8 + .../list-functions/list-greater-than-09.rq | 8 + .../list-functions/list-greater-than-10.rq | 8 + .../list-functions/list-greater-than-11.rq | 8 + .../list-functions/list-greater-than-12.rq | 8 + .../list-functions/list-greater-than-13.rq | 8 + .../list-functions/list-greater-than-14.rq | 8 + .../list-functions/list-greater-than-15.rq | 8 + .../list-functions/list-greater-than-16.rq | 8 + .../list-functions/list-greater-than-19.rq | 8 + .../list-functions/list-greater-than-20.rq | 8 + .../list-functions/list-greater-than-21.rq | 8 + .../list-functions/list-greater-than-22.rq | 8 + .../list-functions/list-greater-than-23.rq | 8 + .../list-functions/list-greater-than-24.rq | 8 + .../list-functions/list-greater-than-25.rq | 8 + .../list-functions/list-greater-than-26.rq | 8 + .../list-functions/list-greater-than-27.rq | 9 + .../list-functions/list-greater-than-28.rq | 7 + .../list-functions/list-greater-than-29.rq | 8 + .../list-functions/list-greater-than-31.rq | 8 + .../list-greater-than-error-03.rq | 8 + .../list-greater-than-error-04.rq | 8 + .../list-greater-than-null-01.rq | 8 + .../list-greater-than-null-02.rq | 8 + .../list-greater-than-null-03.rq | 9 + .../list-greater-than-null-04.rq | 11 + .../list-greater-than-null-05.rq | 8 + .../list-greater-than-null-06.rq | 9 + .../list-functions/list-less-equal-01.rq | 8 + .../list-functions/list-less-equal-02.rq | 8 + .../list-functions/list-less-equal-03.rq | 8 + .../list-functions/list-less-equal-04.rq | 8 + .../list-functions/list-less-equal-05.rq | 8 + .../list-functions/list-less-equal-06.rq | 8 + .../list-functions/list-less-equal-07.rq | 8 + .../list-functions/list-less-equal-08.rq | 8 + .../list-functions/list-less-equal-09.rq | 8 + .../list-functions/list-less-equal-10.rq | 8 + .../list-functions/list-less-equal-11.rq | 8 + .../list-functions/list-less-equal-12.rq | 8 + .../list-functions/list-less-equal-13.rq | 8 + .../list-functions/list-less-equal-14.rq | 8 + .../list-functions/list-less-equal-15.rq | 8 + .../list-functions/list-less-equal-16.rq | 8 + .../list-functions/list-less-equal-19.rq | 8 + .../list-functions/list-less-equal-20.rq | 8 + .../list-functions/list-less-equal-21.rq | 8 + .../list-functions/list-less-equal-22.rq | 8 + .../list-functions/list-less-equal-23.rq | 8 + .../list-functions/list-less-equal-24.rq | 8 + .../list-functions/list-less-equal-25.rq | 8 + .../list-functions/list-less-equal-26.rq | 8 + .../list-functions/list-less-equal-27.rq | 9 + .../list-functions/list-less-equal-28.rq | 7 + .../list-functions/list-less-equal-29.rq | 8 + .../list-functions/list-less-equal-31.rq | 8 + .../list-less-equal-error-03.rq | 8 + .../list-less-equal-error-04.rq | 8 + .../list-functions/list-less-equal-null-01.rq | 8 + .../list-functions/list-less-equal-null-02.rq | 8 + .../list-functions/list-less-equal-null-03.rq | 9 + .../list-functions/list-less-equal-null-04.rq | 11 + .../list-functions/list-less-equal-null-05.rq | 8 + .../list-functions/list-less-equal-null-06.rq | 9 + .../tests/list-functions/list-less-than-01.rq | 8 + .../tests/list-functions/list-less-than-02.rq | 8 + .../tests/list-functions/list-less-than-03.rq | 8 + .../tests/list-functions/list-less-than-04.rq | 8 + .../tests/list-functions/list-less-than-05.rq | 8 + .../tests/list-functions/list-less-than-06.rq | 8 + .../tests/list-functions/list-less-than-07.rq | 8 + .../tests/list-functions/list-less-than-08.rq | 8 + .../tests/list-functions/list-less-than-09.rq | 8 + .../tests/list-functions/list-less-than-10.rq | 8 + .../tests/list-functions/list-less-than-11.rq | 8 + .../tests/list-functions/list-less-than-12.rq | 8 + .../tests/list-functions/list-less-than-13.rq | 8 + .../tests/list-functions/list-less-than-14.rq | 8 + .../tests/list-functions/list-less-than-15.rq | 8 + .../tests/list-functions/list-less-than-16.rq | 8 + .../tests/list-functions/list-less-than-19.rq | 8 + .../tests/list-functions/list-less-than-20.rq | 8 + .../tests/list-functions/list-less-than-21.rq | 8 + .../tests/list-functions/list-less-than-22.rq | 8 + .../tests/list-functions/list-less-than-23.rq | 8 + .../tests/list-functions/list-less-than-24.rq | 8 + .../tests/list-functions/list-less-than-25.rq | 8 + .../tests/list-functions/list-less-than-26.rq | 8 + .../tests/list-functions/list-less-than-27.rq | 9 + .../tests/list-functions/list-less-than-28.rq | 7 + .../tests/list-functions/list-less-than-29.rq | 8 + .../tests/list-functions/list-less-than-31.rq | 8 + .../list-functions/list-less-than-error-03.rq | 8 + .../list-functions/list-less-than-error-04.rq | 8 + .../list-functions/list-less-than-null-01.rq | 8 + .../list-functions/list-less-than-null-02.rq | 8 + .../list-functions/list-less-than-null-03.rq | 9 + .../list-functions/list-less-than-null-04.rq | 11 + .../list-functions/list-less-than-null-05.rq | 8 + .../list-functions/list-less-than-null-06.rq | 9 + .../tests/list-functions/manifest.ttl | 3226 +++++++++++++++++ .../tests/list-functions/reverse-01.rq | 7 + .../tests/list-functions/reverse-02.rq | 7 + .../tests/list-functions/reverse-03.rq | 7 + .../tests/list-functions/reverse-04.rq | 7 + .../tests/list-functions/reverse-05.rq | 7 + .../tests/list-functions/reverse-06.rq | 7 + .../tests/list-functions/reverse-07.rq | 9 + .../tests/list-functions/reverse-08.rq | 7 + .../tests/list-functions/reverse-09.rq | 7 + .../tests/list-functions/reverse-10.rq | 9 + .../tests/list-functions/reverse-error-01.rq | 8 + .../tests/list-functions/sameterm-01.rq | 8 + .../tests/list-functions/sameterm-02.rq | 8 + .../tests/list-functions/sameterm-03.rq | 7 + .../tests/list-functions/sameterm-04.rq | 7 + .../tests/list-functions/sameterm-null-01.rq | 8 + .../tests/list-functions/size-01.rq | 7 + .../tests/list-functions/size-02.rq | 7 + .../tests/list-functions/size-03.rq | 7 + .../tests/list-functions/size-04.rq | 7 + .../tests/list-functions/size-05.rq | 7 + .../tests/list-functions/size-06.rq | 7 + .../tests/list-functions/size-07.rq | 7 + .../tests/list-functions/size-08.rq | 7 + .../tests/list-functions/size-09.rq | 7 + .../tests/list-functions/size-10.rq | 7 + .../tests/list-functions/size-11.rq | 7 + .../tests/list-functions/size-12.rq | 7 + .../tests/list-functions/size-error-01.rq | 8 + .../tests/list-functions/subseq-01.rq | 7 + .../tests/list-functions/subseq-02.rq | 7 + .../tests/list-functions/subseq-03.rq | 7 + .../tests/list-functions/subseq-04.rq | 7 + .../tests/list-functions/subseq-05.rq | 7 + .../tests/list-functions/subseq-06.rq | 7 + .../tests/list-functions/subseq-07.rq | 7 + .../tests/list-functions/subseq-08.rq | 8 + .../tests/list-functions/subseq-09.rq | 8 + .../tests/list-functions/subseq-10.rq | 8 + .../tests/list-functions/subseq-11.rq | 8 + .../tests/list-functions/subseq-12.rq | 8 + .../tests/list-functions/subseq-13.rq | 8 + .../tests/list-functions/subseq-error-01.rq | 8 + .../tests/list-functions/subseq-error-02.rq | 8 + .../tests/list-functions/tail-01.rq | 8 + .../tests/list-functions/tail-02.rq | 7 + .../tests/list-functions/tail-03.rq | 7 + .../tests/list-functions/tail-04.rq | 7 + .../tests/list-functions/tail-05.rq | 7 + .../tests/list-functions/tail-06.rq | 7 + .../tests/list-functions/tail-07.rq | 7 + .../tests/list-functions/tail-08.rq | 7 + .../tests/list-functions/tail-09.rq | 7 + .../tests/list-functions/tail-10.rq | 7 + .../tests/list-functions/tail-error-01.rq | 8 + .../sparql-cdts/tests/list-functions/true.srx | 5 + .../sparql-cdts/tests/manifest-all.ttl | 16 + .../tests/map-functions/containsKey-01.rq | 9 + .../tests/map-functions/containsKey-02.rq | 9 + .../tests/map-functions/containsKey-03.rq | 11 + .../sparql-cdts/tests/map-functions/empty.ttl | 0 .../sparql-cdts/tests/map-functions/get-01.rq | 9 + .../sparql-cdts/tests/map-functions/get-02.rq | 9 + .../sparql-cdts/tests/map-functions/get-03.rq | 12 + .../sparql-cdts/tests/map-functions/get-04.rq | 12 + .../tests/map-functions/get-error-01.rq | 8 + .../tests/map-functions/get-null-01.rq | 8 + .../tests/map-functions/keys-01.rq | 7 + .../tests/map-functions/keys-02.rq | 7 + .../tests/map-functions/keys-03.rq | 10 + .../tests/map-functions/manifest.ttl | 2081 +++++++++++ .../tests/map-functions/map-constructor-01.rq | 7 + .../tests/map-functions/map-constructor-02.rq | 7 + .../tests/map-functions/map-constructor-03.rq | 7 + .../tests/map-functions/map-constructor-04.rq | 7 + .../tests/map-functions/map-constructor-05.rq | 7 + .../tests/map-functions/map-constructor-06.rq | 7 + .../tests/map-functions/map-constructor-07.rq | 7 + .../tests/map-functions/map-constructor-08.rq | 7 + .../tests/map-functions/map-constructor-09.rq | 7 + .../tests/map-functions/map-constructor-10.rq | 15 + .../tests/map-functions/map-constructor-11.rq | 17 + .../tests/map-functions/map-equals-01.rq | 6 + .../tests/map-functions/map-equals-02.rq | 6 + .../tests/map-functions/map-equals-03.rq | 6 + .../tests/map-functions/map-equals-04.rq | 8 + .../tests/map-functions/map-equals-05.rq | 6 + .../tests/map-functions/map-equals-06.rq | 7 + .../tests/map-functions/map-equals-07.rq | 7 + .../tests/map-functions/map-equals-08.rq | 9 + .../tests/map-functions/map-equals-09.rq | 8 + .../tests/map-functions/map-equals-null-01.rq | 9 + .../tests/map-functions/map-equals-null-02.rq | 10 + .../map-functions/map-greater-equal-01.rq | 8 + .../map-functions/map-greater-equal-02.rq | 8 + .../map-functions/map-greater-equal-03.rq | 8 + .../map-functions/map-greater-equal-04.rq | 8 + .../map-functions/map-greater-equal-05.rq | 8 + .../map-functions/map-greater-equal-06.rq | 8 + .../map-functions/map-greater-equal-07.rq | 8 + .../map-functions/map-greater-equal-08.rq | 8 + .../map-functions/map-greater-equal-09.rq | 8 + .../map-functions/map-greater-equal-10.rq | 8 + .../map-functions/map-greater-equal-11.rq | 8 + .../map-functions/map-greater-equal-12.rq | 8 + .../map-functions/map-greater-equal-13.rq | 8 + .../map-functions/map-greater-equal-14.rq | 8 + .../map-functions/map-greater-equal-15.rq | 10 + .../map-functions/map-greater-equal-16.rq | 10 + .../map-functions/map-greater-equal-17.rq | 10 + .../map-functions/map-greater-equal-18.rq | 10 + .../map-functions/map-greater-equal-19.rq | 10 + .../map-functions/map-greater-equal-20.rq | 10 + .../map-functions/map-greater-equal-21.rq | 10 + .../map-greater-equal-error-01.rq | 10 + .../map-greater-equal-error-02.rq | 10 + .../map-greater-equal-null-01.rq | 9 + .../map-greater-equal-null-02.rq | 8 + .../map-greater-equal-null-03.rq | 12 + .../map-greater-equal-null-04.rq | 9 + .../map-functions/map-greater-than-01.rq | 8 + .../map-functions/map-greater-than-02.rq | 8 + .../map-functions/map-greater-than-03.rq | 8 + .../map-functions/map-greater-than-04.rq | 8 + .../map-functions/map-greater-than-05.rq | 8 + .../map-functions/map-greater-than-06.rq | 8 + .../map-functions/map-greater-than-07.rq | 8 + .../map-functions/map-greater-than-08.rq | 8 + .../map-functions/map-greater-than-09.rq | 8 + .../map-functions/map-greater-than-10.rq | 8 + .../map-functions/map-greater-than-11.rq | 8 + .../map-functions/map-greater-than-12.rq | 8 + .../map-functions/map-greater-than-13.rq | 8 + .../map-functions/map-greater-than-14.rq | 8 + .../map-functions/map-greater-than-15.rq | 10 + .../map-functions/map-greater-than-16.rq | 10 + .../map-functions/map-greater-than-17.rq | 10 + .../map-functions/map-greater-than-18.rq | 10 + .../map-functions/map-greater-than-19.rq | 10 + .../map-functions/map-greater-than-20.rq | 10 + .../map-functions/map-greater-than-21.rq | 10 + .../map-greater-than-error-01.rq | 10 + .../map-greater-than-error-02.rq | 10 + .../map-functions/map-greater-than-null-01.rq | 8 + .../map-functions/map-greater-than-null-02.rq | 8 + .../map-functions/map-greater-than-null-03.rq | 10 + .../map-functions/map-greater-than-null-04.rq | 9 + .../tests/map-functions/map-less-equal-01.rq | 8 + .../tests/map-functions/map-less-equal-02.rq | 8 + .../tests/map-functions/map-less-equal-03.rq | 8 + .../tests/map-functions/map-less-equal-04.rq | 8 + .../tests/map-functions/map-less-equal-05.rq | 8 + .../tests/map-functions/map-less-equal-06.rq | 8 + .../tests/map-functions/map-less-equal-07.rq | 8 + .../tests/map-functions/map-less-equal-08.rq | 8 + .../tests/map-functions/map-less-equal-09.rq | 8 + .../tests/map-functions/map-less-equal-10.rq | 8 + .../tests/map-functions/map-less-equal-11.rq | 8 + .../tests/map-functions/map-less-equal-12.rq | 8 + .../tests/map-functions/map-less-equal-13.rq | 8 + .../tests/map-functions/map-less-equal-14.rq | 8 + .../tests/map-functions/map-less-equal-15.rq | 10 + .../tests/map-functions/map-less-equal-16.rq | 10 + .../tests/map-functions/map-less-equal-17.rq | 10 + .../tests/map-functions/map-less-equal-18.rq | 10 + .../tests/map-functions/map-less-equal-19.rq | 10 + .../tests/map-functions/map-less-equal-20.rq | 10 + .../tests/map-functions/map-less-equal-21.rq | 10 + .../map-functions/map-less-equal-error-01.rq | 10 + .../map-functions/map-less-equal-error-02.rq | 10 + .../map-functions/map-less-equal-null-01.rq | 8 + .../map-functions/map-less-equal-null-02.rq | 8 + .../map-functions/map-less-equal-null-03.rq | 10 + .../map-functions/map-less-equal-null-04.rq | 9 + .../tests/map-functions/map-less-than-01.rq | 8 + .../tests/map-functions/map-less-than-02.rq | 8 + .../tests/map-functions/map-less-than-03.rq | 8 + .../tests/map-functions/map-less-than-04.rq | 8 + .../tests/map-functions/map-less-than-05.rq | 8 + .../tests/map-functions/map-less-than-06.rq | 8 + .../tests/map-functions/map-less-than-07.rq | 8 + .../tests/map-functions/map-less-than-08.rq | 8 + .../tests/map-functions/map-less-than-09.rq | 8 + .../tests/map-functions/map-less-than-10.rq | 8 + .../tests/map-functions/map-less-than-11.rq | 8 + .../tests/map-functions/map-less-than-12.rq | 8 + .../tests/map-functions/map-less-than-13.rq | 8 + .../tests/map-functions/map-less-than-14.rq | 8 + .../tests/map-functions/map-less-than-15.rq | 10 + .../tests/map-functions/map-less-than-16.rq | 10 + .../tests/map-functions/map-less-than-17.rq | 10 + .../tests/map-functions/map-less-than-18.rq | 10 + .../tests/map-functions/map-less-than-19.rq | 10 + .../tests/map-functions/map-less-than-20.rq | 10 + .../tests/map-functions/map-less-than-21.rq | 10 + .../map-functions/map-less-than-error-01.rq | 10 + .../map-functions/map-less-than-error-02.rq | 10 + .../map-functions/map-less-than-null-01.rq | 8 + .../map-functions/map-less-than-null-02.rq | 8 + .../map-functions/map-less-than-null-03.rq | 10 + .../map-functions/map-less-than-null-04.rq | 9 + .../tests/map-functions/merge-01.rq | 10 + .../tests/map-functions/merge-02.rq | 10 + .../tests/map-functions/merge-03.rq | 10 + .../tests/map-functions/merge-04.rq | 10 + .../tests/map-functions/merge-05.rq | 10 + .../tests/map-functions/merge-06.rq | 10 + .../tests/map-functions/merge-07.rq | 10 + .../tests/map-functions/merge-08.rq | 10 + .../tests/map-functions/merge-null-01.rq | 18 + .../tests/map-functions/merge-null-02.rq | 18 + .../tests/map-functions/merge-null-03.rq | 14 + .../tests/map-functions/merge-null-04.rq | 10 + .../sparql-cdts/tests/map-functions/put-01.rq | 9 + .../sparql-cdts/tests/map-functions/put-02.rq | 12 + .../sparql-cdts/tests/map-functions/put-03.rq | 12 + .../sparql-cdts/tests/map-functions/put-04.rq | 9 + .../sparql-cdts/tests/map-functions/put-05.rq | 9 + .../sparql-cdts/tests/map-functions/put-06.rq | 9 + .../sparql-cdts/tests/map-functions/put-07.rq | 15 + .../sparql-cdts/tests/map-functions/put-08.rq | 15 + .../sparql-cdts/tests/map-functions/put-09.rq | 9 + .../sparql-cdts/tests/map-functions/put-10.rq | 15 + .../sparql-cdts/tests/map-functions/put-11.rq | 15 + .../sparql-cdts/tests/map-functions/put-12.rq | 10 + .../sparql-cdts/tests/map-functions/put-13.rq | 9 + .../sparql-cdts/tests/map-functions/put-14.rq | 9 + .../sparql-cdts/tests/map-functions/put-15.rq | 9 + .../tests/map-functions/put-error-01.rq | 8 + .../tests/map-functions/put-error-02.rq | 8 + .../tests/map-functions/put-error-03.rq | 8 + .../tests/map-functions/put-error-04.rq | 8 + .../tests/map-functions/put-error-05.rq | 7 + .../tests/map-functions/remove-01.rq | 11 + .../tests/map-functions/remove-02.rq | 9 + .../tests/map-functions/remove-03.rq | 9 + .../tests/map-functions/remove-04.rq | 9 + .../tests/map-functions/remove-05.rq | 10 + .../tests/map-functions/remove-06.rq | 10 + .../tests/map-functions/remove-07.rq | 10 + .../tests/map-functions/remove-08.rq | 9 + .../tests/map-functions/remove-09.rq | 9 + .../tests/map-functions/remove-10.rq | 9 + .../tests/map-functions/remove-11.rq | 9 + .../tests/map-functions/sameterm-01.rq | 8 + .../tests/map-functions/sameterm-02.rq | 8 + .../tests/map-functions/sameterm-03.rq | 7 + .../tests/map-functions/sameterm-04.rq | 7 + .../tests/map-functions/sameterm-05.rq | 9 + .../tests/map-functions/sameterm-null-01.rq | 8 + .../tests/map-functions/size-01.rq | 7 + .../tests/map-functions/size-02.rq | 7 + .../tests/map-functions/size-03.rq | 7 + .../tests/map-functions/size-04.rq | 7 + .../tests/map-functions/size-05.rq | 7 + .../sparql-cdts/tests/map-functions/true.srx | 5 + .../sparql-cdts/tests/orderby/empty.ttl | 0 .../sparql-cdts/tests/orderby/manifest.ttl | 291 ++ .../tests/orderby/order-list-03.rq | 15 + .../tests/orderby/order-list-04.rq | 15 + .../tests/orderby/order-list-05.rq | 18 + .../tests/orderby/order-list-06.rq | 15 + .../tests/orderby/order-list-07.rq | 15 + .../tests/orderby/order-list-08.rq | 15 + .../tests/orderby/order-list-09.rq | 15 + .../tests/orderby/order-list-10.rq | 15 + .../tests/orderby/order-list-null-01.rq | 15 + .../tests/orderby/order-list-null-02.rq | 16 + .../sparql-cdts/tests/orderby/order-map-03.rq | 15 + .../sparql-cdts/tests/orderby/order-map-04.rq | 15 + .../sparql-cdts/tests/orderby/order-map-05.rq | 15 + .../sparql-cdts/tests/orderby/order-map-06.rq | 15 + .../sparql-cdts/tests/orderby/order-map-07.rq | 15 + .../sparql-cdts/tests/orderby/order-map-08.rq | 15 + .../sparql-cdts/tests/orderby/order-map-09.rq | 17 + .../sparql-cdts/tests/orderby/order-map-10.rq | 15 + .../sparql-cdts/tests/orderby/order-map-11.rq | 15 + .../sparql-cdts/tests/orderby/order-map-12.rq | 18 + .../sparql-cdts/tests/orderby/order-map-13.rq | 15 + .../sparql-cdts/tests/orderby/order-map-14.rq | 15 + .../sparql-cdts/tests/orderby/order-map-15.rq | 15 + .../sparql-cdts/tests/orderby/order-map-16.rq | 15 + .../sparql-cdts/tests/orderby/order-map-17.rq | 15 + .../tests/orderby/order-map-null-01.rq | 15 + .../tests/orderby/order-map-null-02.rq | 16 + .../sparql-cdts/tests/orderby/true.srx | 5 + .../sparql-cdts/tests/unfold/empty.ttl | 0 .../sparql-cdts/tests/unfold/manifest.ttl | 483 +++ .../sparql-cdts/tests/unfold/true.srx | 5 + .../tests/unfold/unfold-get-list-1var-01.rq | 7 + .../tests/unfold/unfold-get-list-1var-02.rq | 7 + .../tests/unfold/unfold-get-list-1var-03.rq | 9 + .../tests/unfold/unfold-get-list-1var-04.rq | 9 + .../tests/unfold/unfold-get-list-2vars-01.rq | 7 + .../tests/unfold/unfold-get-list-2vars-02.rq | 7 + .../tests/unfold/unfold-get-list-2vars-03.rq | 9 + .../tests/unfold/unfold-get-list-2vars-04.rq | 9 + .../tests/unfold/unfold-get-list-2vars-05.rq | 7 + .../tests/unfold/unfold-get-list-2vars-06.rq | 10 + .../tests/unfold/unfold-list-1var-01.rq | 6 + .../tests/unfold/unfold-list-1var-01.srj | 14 + .../tests/unfold/unfold-list-1var-02.rq | 6 + .../tests/unfold/unfold-list-1var-02.srj | 17 + .../tests/unfold/unfold-list-1var-03.rq | 6 + .../tests/unfold/unfold-list-1var-03.srj | 14 + .../tests/unfold/unfold-list-1var-04.rq | 6 + .../tests/unfold/unfold-list-1var-04.srj | 14 + .../tests/unfold/unfold-list-1var-05.rq | 6 + .../tests/unfold/unfold-list-1var-05.srj | 14 + .../tests/unfold/unfold-list-1var-06.rq | 6 + .../tests/unfold/unfold-list-1var-06.srj | 14 + .../tests/unfold/unfold-list-1var-07.rq | 6 + .../tests/unfold/unfold-list-1var-07.srj | 17 + .../tests/unfold/unfold-list-1var-08.rq | 6 + .../tests/unfold/unfold-list-1var-08.srj | 17 + .../tests/unfold/unfold-list-1var-09.rq | 6 + .../tests/unfold/unfold-list-1var-09.srj | 13 + .../tests/unfold/unfold-list-1var-10.rq | 6 + .../tests/unfold/unfold-list-1var-10.srj | 15 + .../tests/unfold/unfold-list-2vars-01.rq | 6 + .../tests/unfold/unfold-list-2vars-01.srj | 16 + .../tests/unfold/unfold-list-2vars-02.rq | 6 + .../tests/unfold/unfold-list-2vars-02.srj | 20 + .../tests/unfold/unfold-list-2vars-03.rq | 6 + .../tests/unfold/unfold-list-2vars-03.srj | 16 + .../tests/unfold/unfold-list-2vars-04.rq | 6 + .../tests/unfold/unfold-list-2vars-04.srj | 16 + .../tests/unfold/unfold-list-2vars-05.rq | 6 + .../tests/unfold/unfold-list-2vars-05.srj | 16 + .../tests/unfold/unfold-list-2vars-06.rq | 6 + .../tests/unfold/unfold-list-2vars-06.srj | 16 + .../tests/unfold/unfold-list-2vars-07.rq | 6 + .../tests/unfold/unfold-list-2vars-07.srj | 20 + .../tests/unfold/unfold-list-2vars-08.rq | 6 + .../tests/unfold/unfold-list-2vars-08.srj | 20 + .../tests/unfold/unfold-list-2vars-09.rq | 6 + .../tests/unfold/unfold-list-2vars-09.srj | 15 + .../tests/unfold/unfold-list-2vars-10.rq | 6 + .../tests/unfold/unfold-list-2vars-10.srj | 18 + .../tests/unfold/unfold-map-1var-01.rq | 6 + .../tests/unfold/unfold-map-1var-01.srj | 14 + .../tests/unfold/unfold-map-1var-02.rq | 6 + .../tests/unfold/unfold-map-1var-02.srj | 14 + .../tests/unfold/unfold-map-1var-03.rq | 6 + .../tests/unfold/unfold-map-1var-03.srj | 14 + .../tests/unfold/unfold-map-1var-04.rq | 6 + .../tests/unfold/unfold-map-1var-04.srj | 14 + .../tests/unfold/unfold-map-2vars-01.rq | 6 + .../tests/unfold/unfold-map-2vars-01.srj | 16 + .../tests/unfold/unfold-map-2vars-02.rq | 6 + .../tests/unfold/unfold-map-2vars-02.srj | 16 + .../tests/unfold/unfold-map-2vars-03.rq | 6 + .../tests/unfold/unfold-map-2vars-03.srj | 16 + .../tests/unfold/unfold-map-2vars-04.rq | 6 + .../tests/unfold/unfold-map-2vars-04.srj | 16 + .../tests/unfold/unfold-map-2vars-05.rq | 6 + .../tests/unfold/unfold-map-2vars-05.srj | 16 + .../tests/unfold/unfold-map-2vars-06.rq | 6 + .../tests/unfold/unfold-map-2vars-06.srj | 16 + .../tests/unfold/unfold-map-2vars-07.rq | 6 + .../tests/unfold/unfold-map-2vars-07.srj | 16 + .../tests/unfold/unfold-map-2vars-08.rq | 6 + .../tests/unfold/unfold-map-2vars-08.srj | 15 + 764 files changed, 15187 insertions(+), 17 deletions(-) create mode 100644 src/test/java/com/ebremer/beakgraph/CdtHardeningTest.java create mode 100644 src/test/java/com/ebremer/beakgraph/cdt/SparqlCdtSuiteTest.java create mode 100644 src/test/java/com/ebremer/beakgraph/core/fuseki/DistinctNodeCounterCdtTest.java create mode 100644 src/test/resources/sparql-cdts/LICENSE create mode 100644 src/test/resources/sparql-cdts/NOTICE create mode 100644 src/test/resources/sparql-cdts/README.md create mode 100644 src/test/resources/sparql-cdts/tests/README.md create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-export-rdf-01-construct.rq create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-export-rdf-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-export-service-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-02.rq create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-03.rq create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-04.rq create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-05.rq create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-06.rq create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-07.rq create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-08.rq create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-09.rq create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-11.rq create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-12.rq create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-13.rq create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-14.rq create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-15.rq create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-16.rq create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-17.rq create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-18.rq create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-21.rq create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-22.rq create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-23.rq create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-24.rq create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-25.rq create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-26.rq create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-27.rq create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-28.rq create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-01.ttl create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-02.rq create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-02.ttl create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-03.rq create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-03.ttl create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-04.rq create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-04.ttl create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-05.rq create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-05.ttl create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-06.rq create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-06.ttl create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-07.rq create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-07.ttl create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-08.rq create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-08.ttl create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-09.rq create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-09.ttl create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-10.rq create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-10.ttl create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-11.rq create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-11.ttl create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-12.rq create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-12.ttl create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-13.rq create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-13.ttl create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-14.rq create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-14.ttl create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-15.rq create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-15a.ttl create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-15b.ttl create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-16.rq create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-16a.ttl create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-16b.ttl create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-17.rq create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-17a.ttl create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-17b.ttl create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-18.rq create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-18a.ttl create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-18b.ttl create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-19.rq create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-19a.ttl create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-19b.ttl create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-21.rq create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-21.ttl create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-22.rq create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-22.ttl create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-23.rq create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-23.ttl create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-24.rq create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-24.ttl create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-25.rq create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-25.ttl create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-26.rq create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-26.ttl create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-27.rq create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-27.ttl create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-28.rq create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-28.ttl create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-29.rq create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-29.ttl create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-30.rq create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-30.ttl create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-31.rq create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-31.ttl create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-32.rq create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-32.ttl create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-41.ttl create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-42.ttl create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-43.ttl create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-44.ttl create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-45.ttl create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-46.ttl create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-47.ttl create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-48.ttl create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-49.ttl create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-50.ttl create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-51.ttl create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-52.ttl create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-sparql-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-sparql-01.ttl create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-sparql-02.rq create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-sparql-02.ttl create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-sparql-03.rq create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-sparql-03.ttl create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-sparql-04.rq create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-sparql-04.ttl create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/empty.ttl create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/manifest.ttl create mode 100644 src/test/resources/sparql-cdts/tests/bnodes/true.srx create mode 100644 src/test/resources/sparql-cdts/tests/fold/empty.ttl create mode 100644 src/test/resources/sparql-cdts/tests/fold/fold-list-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/fold/fold-list-02.rq create mode 100644 src/test/resources/sparql-cdts/tests/fold/fold-list-03.rq create mode 100644 src/test/resources/sparql-cdts/tests/fold/fold-list-04.rq create mode 100644 src/test/resources/sparql-cdts/tests/fold/fold-list-05.rq create mode 100644 src/test/resources/sparql-cdts/tests/fold/fold-list-distinct-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/fold/fold-list-distinct-02.rq create mode 100644 src/test/resources/sparql-cdts/tests/fold/fold-list-distinct-03.rq create mode 100644 src/test/resources/sparql-cdts/tests/fold/fold-list-distinct-04.rq create mode 100644 src/test/resources/sparql-cdts/tests/fold/fold-list-distinct-05.rq create mode 100644 src/test/resources/sparql-cdts/tests/fold/fold-list-distinct-06.rq create mode 100644 src/test/resources/sparql-cdts/tests/fold/fold-list-distinct-07.rq create mode 100644 src/test/resources/sparql-cdts/tests/fold/fold-list-distinct-08.rq create mode 100644 src/test/resources/sparql-cdts/tests/fold/fold-list-distinct-orderby-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/fold/fold-list-distinct-orderby-02.rq create mode 100644 src/test/resources/sparql-cdts/tests/fold/fold-list-distinct-orderby-03.rq create mode 100644 src/test/resources/sparql-cdts/tests/fold/fold-list-orderby-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/fold/fold-list-orderby-02.rq create mode 100644 src/test/resources/sparql-cdts/tests/fold/fold-list-orderby-03.rq create mode 100644 src/test/resources/sparql-cdts/tests/fold/fold-list-orderby-04.rq create mode 100644 src/test/resources/sparql-cdts/tests/fold/fold-list-orderby-05.rq create mode 100644 src/test/resources/sparql-cdts/tests/fold/fold-list-orderby-06.rq create mode 100644 src/test/resources/sparql-cdts/tests/fold/fold-map-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/fold/fold-map-02.rq create mode 100644 src/test/resources/sparql-cdts/tests/fold/fold-map-03.rq create mode 100644 src/test/resources/sparql-cdts/tests/fold/fold-map-04.rq create mode 100644 src/test/resources/sparql-cdts/tests/fold/fold-map-05.rq create mode 100644 src/test/resources/sparql-cdts/tests/fold/fold-map-06.rq create mode 100644 src/test/resources/sparql-cdts/tests/fold/fold-map-orderby-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/fold/fold-map-orderby-02.rq create mode 100644 src/test/resources/sparql-cdts/tests/fold/manifest.ttl create mode 100644 src/test/resources/sparql-cdts/tests/fold/true.srx create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/concat-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/concat-02.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/concat-03.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/concat-04.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/concat-05.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/concat-06.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/concat-07.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/concat-08.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/concat-09.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/concat-10.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/concat-error-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/concat-error-02.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/concat-null-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/contains-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/contains-02.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/contains-03.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/contains-04.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/contains-05.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/contains-06.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/contains-07.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/contains-08.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/contains-09.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/contains-10.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/contains-error-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/contains-null-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/empty.ttl create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/get-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/get-02.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/get-03.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/get-04.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/get-05.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/get-06.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/get-07.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/get-08.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/get-09.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/get-10.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/get-11.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/get-12.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/get-13.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/get-error-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/get-error-02.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/get-error-03.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/get-error-04.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/get-error-05.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/get-error-06.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/get-null-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/get-null-02.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/head-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/head-02.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/head-03.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/head-04.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/head-05.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/head-06.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/head-07.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/head-08.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/head-09.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/head-10.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/head-11.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/head-12.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/head-error-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/head-null-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/head-null-02.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-constructor-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-constructor-02.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-constructor-03.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-constructor-04.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-constructor-05.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-constructor-06.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-constructor-09.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-constructor-10.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-constructor-11.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-constructor-12.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-constructor-13.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-constructor-14.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-constructor-15.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-constructor-16.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-constructor-null-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-constructor-null-02.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-equals-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-equals-02.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-equals-03.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-equals-04.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-equals-05.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-equals-06.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-equals-07.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-equals-08.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-equals-09.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-equals-null-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-equals-null-02.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-02.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-03.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-04.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-05.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-06.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-07.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-08.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-09.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-10.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-11.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-12.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-13.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-14.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-15.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-16.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-19.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-20.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-21.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-22.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-23.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-24.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-25.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-26.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-27.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-28.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-29.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-31.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-error-03.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-error-04.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-null-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-null-02.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-null-03.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-null-04.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-null-05.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-null-06.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-02.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-03.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-04.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-05.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-06.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-07.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-08.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-09.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-10.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-11.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-12.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-13.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-14.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-15.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-16.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-19.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-20.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-21.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-22.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-23.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-24.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-25.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-26.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-27.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-28.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-29.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-31.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-error-03.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-error-04.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-null-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-null-02.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-null-03.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-null-04.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-null-05.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-null-06.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-02.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-03.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-04.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-05.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-06.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-07.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-08.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-09.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-10.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-11.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-12.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-13.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-14.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-15.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-16.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-19.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-20.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-21.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-22.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-23.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-24.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-25.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-26.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-27.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-28.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-29.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-31.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-error-03.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-error-04.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-null-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-null-02.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-null-03.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-null-04.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-null-05.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-null-06.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-less-than-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-less-than-02.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-less-than-03.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-less-than-04.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-less-than-05.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-less-than-06.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-less-than-07.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-less-than-08.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-less-than-09.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-less-than-10.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-less-than-11.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-less-than-12.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-less-than-13.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-less-than-14.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-less-than-15.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-less-than-16.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-less-than-19.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-less-than-20.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-less-than-21.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-less-than-22.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-less-than-23.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-less-than-24.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-less-than-25.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-less-than-26.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-less-than-27.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-less-than-28.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-less-than-29.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-less-than-31.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-less-than-error-03.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-less-than-error-04.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-less-than-null-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-less-than-null-02.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-less-than-null-03.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-less-than-null-04.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-less-than-null-05.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/list-less-than-null-06.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/manifest.ttl create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/reverse-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/reverse-02.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/reverse-03.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/reverse-04.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/reverse-05.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/reverse-06.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/reverse-07.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/reverse-08.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/reverse-09.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/reverse-10.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/reverse-error-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/sameterm-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/sameterm-02.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/sameterm-03.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/sameterm-04.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/sameterm-null-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/size-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/size-02.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/size-03.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/size-04.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/size-05.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/size-06.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/size-07.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/size-08.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/size-09.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/size-10.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/size-11.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/size-12.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/size-error-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/subseq-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/subseq-02.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/subseq-03.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/subseq-04.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/subseq-05.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/subseq-06.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/subseq-07.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/subseq-08.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/subseq-09.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/subseq-10.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/subseq-11.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/subseq-12.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/subseq-13.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/subseq-error-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/subseq-error-02.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/tail-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/tail-02.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/tail-03.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/tail-04.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/tail-05.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/tail-06.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/tail-07.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/tail-08.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/tail-09.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/tail-10.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/tail-error-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/list-functions/true.srx create mode 100644 src/test/resources/sparql-cdts/tests/manifest-all.ttl create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/containsKey-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/containsKey-02.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/containsKey-03.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/empty.ttl create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/get-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/get-02.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/get-03.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/get-04.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/get-error-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/get-null-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/keys-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/keys-02.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/keys-03.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/manifest.ttl create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-constructor-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-constructor-02.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-constructor-03.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-constructor-04.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-constructor-05.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-constructor-06.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-constructor-07.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-constructor-08.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-constructor-09.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-constructor-10.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-constructor-11.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-equals-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-equals-02.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-equals-03.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-equals-04.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-equals-05.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-equals-06.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-equals-07.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-equals-08.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-equals-09.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-equals-null-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-equals-null-02.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-02.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-03.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-04.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-05.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-06.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-07.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-08.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-09.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-10.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-11.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-12.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-13.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-14.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-15.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-16.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-17.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-18.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-19.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-20.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-21.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-error-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-error-02.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-null-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-null-02.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-null-03.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-null-04.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-02.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-03.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-04.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-05.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-06.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-07.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-08.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-09.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-10.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-11.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-12.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-13.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-14.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-15.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-16.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-17.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-18.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-19.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-20.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-21.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-error-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-error-02.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-null-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-null-02.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-null-03.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-null-04.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-02.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-03.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-04.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-05.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-06.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-07.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-08.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-09.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-10.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-11.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-12.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-13.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-14.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-15.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-16.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-17.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-18.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-19.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-20.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-21.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-error-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-error-02.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-null-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-null-02.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-null-03.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-null-04.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-less-than-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-less-than-02.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-less-than-03.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-less-than-04.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-less-than-05.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-less-than-06.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-less-than-07.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-less-than-08.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-less-than-09.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-less-than-10.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-less-than-11.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-less-than-12.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-less-than-13.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-less-than-14.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-less-than-15.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-less-than-16.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-less-than-17.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-less-than-18.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-less-than-19.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-less-than-20.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-less-than-21.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-less-than-error-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-less-than-error-02.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-less-than-null-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-less-than-null-02.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-less-than-null-03.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/map-less-than-null-04.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/merge-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/merge-02.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/merge-03.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/merge-04.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/merge-05.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/merge-06.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/merge-07.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/merge-08.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/merge-null-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/merge-null-02.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/merge-null-03.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/merge-null-04.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/put-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/put-02.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/put-03.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/put-04.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/put-05.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/put-06.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/put-07.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/put-08.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/put-09.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/put-10.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/put-11.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/put-12.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/put-13.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/put-14.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/put-15.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/put-error-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/put-error-02.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/put-error-03.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/put-error-04.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/put-error-05.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/remove-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/remove-02.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/remove-03.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/remove-04.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/remove-05.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/remove-06.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/remove-07.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/remove-08.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/remove-09.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/remove-10.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/remove-11.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/sameterm-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/sameterm-02.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/sameterm-03.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/sameterm-04.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/sameterm-05.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/sameterm-null-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/size-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/size-02.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/size-03.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/size-04.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/size-05.rq create mode 100644 src/test/resources/sparql-cdts/tests/map-functions/true.srx create mode 100644 src/test/resources/sparql-cdts/tests/orderby/empty.ttl create mode 100644 src/test/resources/sparql-cdts/tests/orderby/manifest.ttl create mode 100644 src/test/resources/sparql-cdts/tests/orderby/order-list-03.rq create mode 100644 src/test/resources/sparql-cdts/tests/orderby/order-list-04.rq create mode 100644 src/test/resources/sparql-cdts/tests/orderby/order-list-05.rq create mode 100644 src/test/resources/sparql-cdts/tests/orderby/order-list-06.rq create mode 100644 src/test/resources/sparql-cdts/tests/orderby/order-list-07.rq create mode 100644 src/test/resources/sparql-cdts/tests/orderby/order-list-08.rq create mode 100644 src/test/resources/sparql-cdts/tests/orderby/order-list-09.rq create mode 100644 src/test/resources/sparql-cdts/tests/orderby/order-list-10.rq create mode 100644 src/test/resources/sparql-cdts/tests/orderby/order-list-null-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/orderby/order-list-null-02.rq create mode 100644 src/test/resources/sparql-cdts/tests/orderby/order-map-03.rq create mode 100644 src/test/resources/sparql-cdts/tests/orderby/order-map-04.rq create mode 100644 src/test/resources/sparql-cdts/tests/orderby/order-map-05.rq create mode 100644 src/test/resources/sparql-cdts/tests/orderby/order-map-06.rq create mode 100644 src/test/resources/sparql-cdts/tests/orderby/order-map-07.rq create mode 100644 src/test/resources/sparql-cdts/tests/orderby/order-map-08.rq create mode 100644 src/test/resources/sparql-cdts/tests/orderby/order-map-09.rq create mode 100644 src/test/resources/sparql-cdts/tests/orderby/order-map-10.rq create mode 100644 src/test/resources/sparql-cdts/tests/orderby/order-map-11.rq create mode 100644 src/test/resources/sparql-cdts/tests/orderby/order-map-12.rq create mode 100644 src/test/resources/sparql-cdts/tests/orderby/order-map-13.rq create mode 100644 src/test/resources/sparql-cdts/tests/orderby/order-map-14.rq create mode 100644 src/test/resources/sparql-cdts/tests/orderby/order-map-15.rq create mode 100644 src/test/resources/sparql-cdts/tests/orderby/order-map-16.rq create mode 100644 src/test/resources/sparql-cdts/tests/orderby/order-map-17.rq create mode 100644 src/test/resources/sparql-cdts/tests/orderby/order-map-null-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/orderby/order-map-null-02.rq create mode 100644 src/test/resources/sparql-cdts/tests/orderby/true.srx create mode 100644 src/test/resources/sparql-cdts/tests/unfold/empty.ttl create mode 100644 src/test/resources/sparql-cdts/tests/unfold/manifest.ttl create mode 100644 src/test/resources/sparql-cdts/tests/unfold/true.srx create mode 100644 src/test/resources/sparql-cdts/tests/unfold/unfold-get-list-1var-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/unfold/unfold-get-list-1var-02.rq create mode 100644 src/test/resources/sparql-cdts/tests/unfold/unfold-get-list-1var-03.rq create mode 100644 src/test/resources/sparql-cdts/tests/unfold/unfold-get-list-1var-04.rq create mode 100644 src/test/resources/sparql-cdts/tests/unfold/unfold-get-list-2vars-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/unfold/unfold-get-list-2vars-02.rq create mode 100644 src/test/resources/sparql-cdts/tests/unfold/unfold-get-list-2vars-03.rq create mode 100644 src/test/resources/sparql-cdts/tests/unfold/unfold-get-list-2vars-04.rq create mode 100644 src/test/resources/sparql-cdts/tests/unfold/unfold-get-list-2vars-05.rq create mode 100644 src/test/resources/sparql-cdts/tests/unfold/unfold-get-list-2vars-06.rq create mode 100644 src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-01.srj create mode 100644 src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-02.rq create mode 100644 src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-02.srj create mode 100644 src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-03.rq create mode 100644 src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-03.srj create mode 100644 src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-04.rq create mode 100644 src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-04.srj create mode 100644 src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-05.rq create mode 100644 src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-05.srj create mode 100644 src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-06.rq create mode 100644 src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-06.srj create mode 100644 src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-07.rq create mode 100644 src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-07.srj create mode 100644 src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-08.rq create mode 100644 src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-08.srj create mode 100644 src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-09.rq create mode 100644 src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-09.srj create mode 100644 src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-10.rq create mode 100644 src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-10.srj create mode 100644 src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-01.srj create mode 100644 src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-02.rq create mode 100644 src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-02.srj create mode 100644 src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-03.rq create mode 100644 src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-03.srj create mode 100644 src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-04.rq create mode 100644 src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-04.srj create mode 100644 src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-05.rq create mode 100644 src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-05.srj create mode 100644 src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-06.rq create mode 100644 src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-06.srj create mode 100644 src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-07.rq create mode 100644 src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-07.srj create mode 100644 src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-08.rq create mode 100644 src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-08.srj create mode 100644 src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-09.rq create mode 100644 src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-09.srj create mode 100644 src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-10.rq create mode 100644 src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-10.srj create mode 100644 src/test/resources/sparql-cdts/tests/unfold/unfold-map-1var-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/unfold/unfold-map-1var-01.srj create mode 100644 src/test/resources/sparql-cdts/tests/unfold/unfold-map-1var-02.rq create mode 100644 src/test/resources/sparql-cdts/tests/unfold/unfold-map-1var-02.srj create mode 100644 src/test/resources/sparql-cdts/tests/unfold/unfold-map-1var-03.rq create mode 100644 src/test/resources/sparql-cdts/tests/unfold/unfold-map-1var-03.srj create mode 100644 src/test/resources/sparql-cdts/tests/unfold/unfold-map-1var-04.rq create mode 100644 src/test/resources/sparql-cdts/tests/unfold/unfold-map-1var-04.srj create mode 100644 src/test/resources/sparql-cdts/tests/unfold/unfold-map-2vars-01.rq create mode 100644 src/test/resources/sparql-cdts/tests/unfold/unfold-map-2vars-01.srj create mode 100644 src/test/resources/sparql-cdts/tests/unfold/unfold-map-2vars-02.rq create mode 100644 src/test/resources/sparql-cdts/tests/unfold/unfold-map-2vars-02.srj create mode 100644 src/test/resources/sparql-cdts/tests/unfold/unfold-map-2vars-03.rq create mode 100644 src/test/resources/sparql-cdts/tests/unfold/unfold-map-2vars-03.srj create mode 100644 src/test/resources/sparql-cdts/tests/unfold/unfold-map-2vars-04.rq create mode 100644 src/test/resources/sparql-cdts/tests/unfold/unfold-map-2vars-04.srj create mode 100644 src/test/resources/sparql-cdts/tests/unfold/unfold-map-2vars-05.rq create mode 100644 src/test/resources/sparql-cdts/tests/unfold/unfold-map-2vars-05.srj create mode 100644 src/test/resources/sparql-cdts/tests/unfold/unfold-map-2vars-06.rq create mode 100644 src/test/resources/sparql-cdts/tests/unfold/unfold-map-2vars-06.srj create mode 100644 src/test/resources/sparql-cdts/tests/unfold/unfold-map-2vars-07.rq create mode 100644 src/test/resources/sparql-cdts/tests/unfold/unfold-map-2vars-07.srj create mode 100644 src/test/resources/sparql-cdts/tests/unfold/unfold-map-2vars-08.rq create mode 100644 src/test/resources/sparql-cdts/tests/unfold/unfold-map-2vars-08.srj diff --git a/README.md b/README.md index ee20b6d2..ad88f6b6 100644 --- a/README.md +++ b/README.md @@ -94,13 +94,18 @@ Beakgraph's HDF5 design is heavily inspired by [RDF HDT](https://www.rdfhdt.org/ are still rejected loudly at ingest. Versions ≤ 0.17.0 silently stored base-direction literals as plain `"x"@en` — rebuild affected stores; a version that rejects or correctly stores them is the detector. -* SPARQL-CDT composite literals (`cdt:List`/`cdt:Map`) are stored term-exactly - and queryable with Jena's `cdt:` functions, `FOLD`, and `UNFOLD`. Caveats: - the dictionary orders them lexically, so stores built by ≤ 0.17.0 that - contain composite literals must be rebuilt; blank nodes inside composite - literals are rejected at ingest (labels regenerate from rank, which would - silently sever their co-reference); and composite elements are opaque to the - index — filtering or joining inside a list/map parses the whole value in RAM. +* SPARQL-CDT composite literals (`cdt:List`/`cdt:Map`; the + [spec](https://awslabs.github.io/SPARQL-CDTs/spec/latest.html) is an + **Unofficial Draft**) are stored term-exactly and queryable with Jena's + `cdt:` functions, `FOLD`, and `UNFOLD` — the spec's own 658-test suite runs + against BeakGraph stores in CI (`SparqlCdtSuiteTest`). Caveats: the + dictionary orders composite literals lexically, so stores built by ≤ 0.17.0 + that contain them must be rebuilt; blank nodes inside composite literals are + rejected at ingest (labels regenerate from rank, which would silently sever + their co-reference); and composite elements are **opaque to the index** — + filtering or joining inside a list/map parses the whole value in RAM, so + model data as triples when you need to query it and as composite literals + when you need compact, exact round-tripping. ### Author's notes The first iteration of BeakGraph was backed by Apache Arrow instead of [HDF5](https://www.hdfgroup.org/solutions/hdf5/). An Apache Arrow version will return. Reasons for this are varied with some of these reasons being just experimentation. diff --git a/docs/INSTRUCTIONS.md b/docs/INSTRUCTIONS.md index 20cd528b..5ba7a5df 100644 --- a/docs/INSTRUCTIONS.md +++ b/docs/INSTRUCTIONS.md @@ -72,7 +72,7 @@ java -jar BeakGraph.jar -endpoint out/example.h5 -port 8888 | `-status` | off | Progress bar (per-file mode) and end-of-run counters. | | `-endpoint ` | — | Serve the store as a SPARQL endpoint instead of converting. | | `-port ` | `8888` | HTTP port for `-endpoint`. | -| `-timeout ` | `30` | Per-query wall-clock limit in seconds for `-endpoint`; a query over the limit is cancelled and answered with HTTP 503. `0` disables the limit. | +| `-timeout ` | `30` | Per-query wall-clock limit in seconds for `-endpoint`; a query over the limit is cancelled and answered with HTTP 503. `0` disables the limit. Note: queries that expand large composite (`cdt:`) literals with `UNFOLD`, or compare them by value, parse the whole literal in RAM (~1 µs per element) and can hit this limit — raise it for CDT-heavy workloads. | | `-version` / `-v` | — | Print version and exit. | | `-help` | — | Usage text. | @@ -213,8 +213,8 @@ workloads, and each knob trades heap for repeated-lookup speed: | Property | Default | What it bounds | |---|---|---| -| `beakgraph.nodetable.cache.size` | `1000000` | Node ⇄ NodeId entries per direction, per open reader (query bind/materialize path). | -| `beakgraph.dict.search.cache.size` | `65536` | Term → dictionary-position entries per dictionary section (locate/search results, hits and misses). | +| `beakgraph.nodetable.cache.size` | `1000000` | Node ⇄ NodeId **entry-equivalents** per direction, per open reader (query bind/materialize path). Ordinary terms cost 1; an oversized literal costs 1 per 256 chars of lexical form, so composite (`cdt:`) literals — whose cached nodes retain their parsed values (~4.5× the text) — cannot silently pin unbounded heap. | +| `beakgraph.dict.search.cache.size` | `65536` | Term → dictionary-position **entry-equivalents** per dictionary section (locate/search results, hits and misses; same oversized-literal weighting as above). | | `beakgraph.fcd.cache.blocks` | `4096` | Decoded front-coded string blocks per FCD section (each block holds `blockSize`, typically 16, strings). | | `beakgraph.ffm.threshold` | `2147483647` | Dataset size in bytes above which BeakGraph FFM-maps the region itself instead of using jHDF's ByteBuffer. | | `beakgraph.scan.parallel.threshold` | `65536` | Minimum index position range for a scan-shaped first pattern (`?s ?p ?o`, or `?s

    ?o`) to run as a chunked PARALLEL scan on the shared worker pool. `0` (or negative) disables parallel scanning. Chunks stop on query timeout/cancel and on early close (LIMIT). | diff --git a/src/main/java/com/ebremer/beakgraph/core/BGDatasetGraph.java b/src/main/java/com/ebremer/beakgraph/core/BGDatasetGraph.java index 11a7229e..47d70816 100644 --- a/src/main/java/com/ebremer/beakgraph/core/BGDatasetGraph.java +++ b/src/main/java/com/ebremer/beakgraph/core/BGDatasetGraph.java @@ -63,6 +63,10 @@ public BGDatasetGraph(BeakGraph g) { this.bg = g; QC.setFactory(context, OpExecutorBG.opExecFactoryBG); PropertyFunctionRegistry.set(context, BGPropertyFunctions.INSTANCE); + // Re-pin CDT support for each dataset: a later ARQ.setStrictMode() call + // elsewhere in the JVM flips the global off, and BeakGraph's stored + // cdt: literals need composite semantics to query correctly. + org.apache.jena.sparql.SystemARQ.EnableCDTs = true; } @Override diff --git a/src/main/java/com/ebremer/beakgraph/core/BeakGraph.java b/src/main/java/com/ebremer/beakgraph/core/BeakGraph.java index 5b9e79a0..4abfcc30 100644 --- a/src/main/java/com/ebremer/beakgraph/core/BeakGraph.java +++ b/src/main/java/com/ebremer/beakgraph/core/BeakGraph.java @@ -95,6 +95,12 @@ private static void init() { // because it dispatches on the active graph's type and delegates // everything that is not a BeakGraph. wireIntoExecution() ; + // Pin CDT support on: BeakGraph stores cdt:List/cdt:Map literals and + // its comparator/guards assume their datatypes behave as composites. + // Jena defaults this to true, but ARQ.setStrictMode() anywhere in the + // JVM silently flips it off; BGDatasetGraph re-pins per dataset for + // the strictMode-after-init case. + org.apache.jena.sparql.SystemARQ.EnableCDTs = true; // Publish only after wiring succeeded, so a failure here is retried by // the next caller instead of leaving the JVM half-wired forever. initialized = true ; diff --git a/src/main/java/com/ebremer/beakgraph/hdf5/jena/SimpleNodeTable.java b/src/main/java/com/ebremer/beakgraph/hdf5/jena/SimpleNodeTable.java index 021f1336..2099ddea 100644 --- a/src/main/java/com/ebremer/beakgraph/hdf5/jena/SimpleNodeTable.java +++ b/src/main/java/com/ebremer/beakgraph/hdf5/jena/SimpleNodeTable.java @@ -13,17 +13,34 @@ public class SimpleNodeTable implements NodeTable { private final PositionalDictionaryReader dict; - /** Entries per direction; override with -Dbeakgraph.nodetable.cache.size. */ + /** Entry-equivalents per direction; override with -Dbeakgraph.nodetable.cache.size. */ private static final long CACHE_SIZE = Long.getLong("beakgraph.nodetable.cache.size", 1_000_000L); + /** + * Cache weight of a node. The cache bound was sized assuming small terms + * (IRIs, ordinary literals ~ weight 1), but a cached composite (cdt:) + * literal retains its parsed value - measured ~4.5x its lexical form - so + * a count-based bound could silently pin gigabytes. Oversized literals + * count as one entry-equivalent per 256 chars of lexical form instead; + * typical terms keep the historical one-entry cost. + */ + static int weightOf(Node n) { + if (n.isLiteral()) { + return 1 + (n.getLiteralLexicalForm().length() >>> 8); + } + return 1; + } + // Caffeine LRU Caches for extreme high-performance concurrent caching. // Keys/values are packed NodeId longs (boxed at the cache boundary only). private final Cache nodeId2nodemap = Caffeine.newBuilder() - .maximumSize(CACHE_SIZE) + .maximumWeight(CACHE_SIZE) + .weigher((Long id, Node n) -> weightOf(n)) .build(); private final Cache node2nodeIdmap = Caffeine.newBuilder() - .maximumSize(CACHE_SIZE) + .maximumWeight(CACHE_SIZE) + .weigher((Node n, Long id) -> weightOf(n)) .build(); public SimpleNodeTable(PositionalDictionaryReader dict) { diff --git a/src/main/java/com/ebremer/beakgraph/hdf5/readers/HDF5Reader.java b/src/main/java/com/ebremer/beakgraph/hdf5/readers/HDF5Reader.java index 68f30fd4..bf18a124 100644 --- a/src/main/java/com/ebremer/beakgraph/hdf5/readers/HDF5Reader.java +++ b/src/main/java/com/ebremer/beakgraph/hdf5/readers/HDF5Reader.java @@ -173,6 +173,15 @@ public IndexReader getIndexReader(Index indexType) { @Override public Iterator read(Node ng, BindingNodeId bnid, Triple triple, ExprList filter, NodeTable nodeTable) { + // An EMPTY store (built from an empty source - legal) has no dictionary + // or index datasets at all; every pattern answers no solutions rather + // than each downstream layer having to tolerate absent structures. + // Deliberately keyed on dictionary absence, NOT numQuads: that attribute + // counts SOURCE quads only, and a -void build of an empty source has + // zero source quads but real stored metadata quads. + if (dict.isEmpty()) { + return Collections.emptyIterator(); + } // A pattern variable already bound to a node that does not exist in this store // (e.g. a VALUES/BIND term not present here) cannot match anything, so the pattern // yields no solutions - rather than failing to resolve the missing id. diff --git a/src/main/java/com/ebremer/beakgraph/hdf5/readers/MultiTypeDictionaryReader.java b/src/main/java/com/ebremer/beakgraph/hdf5/readers/MultiTypeDictionaryReader.java index 95714c53..ae0e63ef 100644 --- a/src/main/java/com/ebremer/beakgraph/hdf5/readers/MultiTypeDictionaryReader.java +++ b/src/main/java/com/ebremer/beakgraph/hdf5/readers/MultiTypeDictionaryReader.java @@ -59,9 +59,14 @@ public class MultiTypeDictionaryReader extends AbstractDictionary { // race builds identical content over immutable data. private volatile TieredIndex tiered; + // Weight mirrors SimpleNodeTable.weightOf: probe keys are caller-supplied + // nodes, and a composite (cdt:) literal key retains its parsed value, so a + // count-based bound could pin far more heap than the entry count implies. private final com.github.benmanes.caffeine.cache.Cache searchCache = com.github.benmanes.caffeine.cache.Caffeine.newBuilder() - .maximumSize(SEARCH_CACHE_SIZE) + .maximumWeight(SEARCH_CACHE_SIZE) + .weigher((Node n, Long pos) -> + n.isLiteral() ? 1 + (n.getLiteralLexicalForm().length() >>> 8) : 1) .build(); private record TieredIndex(long[] ids, Node[] nodes) {} diff --git a/src/main/java/com/ebremer/beakgraph/hdf5/readers/PositionalDictionaryReader.java b/src/main/java/com/ebremer/beakgraph/hdf5/readers/PositionalDictionaryReader.java index 2599d286..8fea67e9 100644 --- a/src/main/java/com/ebremer/beakgraph/hdf5/readers/PositionalDictionaryReader.java +++ b/src/main/java/com/ebremer/beakgraph/hdf5/readers/PositionalDictionaryReader.java @@ -51,19 +51,47 @@ private Optional getDataSet(Group g, String name) { return (g.getChild(name) != null) ? Optional.of((ContiguousDataset) g.getChild(name)) : Optional.empty(); } + /** + * Stand-in for an ABSENT dictionary section (a store built from an empty + * source has no entities/predicates groups at all - legal per the format's + * presence-sniffing evolution). Every lookup answers "not here" instead of + * the callers NPE-ing: before this, ANY scan-shaped query over an empty + * store died in ScanChunks/SimpleNodeTable on a null dictionary (found by + * the vendored SPARQL-CDTs suite's constructDataFile tests). + */ + private static final Dictionary EMPTY = new Dictionary() { + @Override public long locate(Node element) { return -1; } + @Override public long search(Node element) { return -1; } // insertion point 0, nothing stored + @Override public Node extract(long id) { + throw new IllegalArgumentException("empty dictionary holds no id " + id); + } + @Override public long getNumberOfNodes() { return 0; } + @Override public java.util.stream.Stream streamNodes() { return java.util.stream.Stream.empty(); } + }; + + /** + * True when NO dictionary section exists - a store built from an empty + * source with no injected metadata. Note this is not "numQuads == 0": the + * numQuads attribute counts SOURCE quads only, and a -void build of an + * empty source has zero source quads but real stored metadata quads. + */ + public boolean isEmpty() { + return entities == null && predicates == null && literals == null; + } + @Override public Dictionary getGraphs() { - return entities; // Graphs share the universal Entity ID space + return (entities != null) ? entities : EMPTY; // Graphs share the universal Entity ID space } @Override public Dictionary getSubjects() { - return entities; // Subjects share the universal Entity ID space + return (entities != null) ? entities : EMPTY; // Subjects share the universal Entity ID space } @Override public Dictionary getPredicates() { - return predicates; // Predicates are isolated to save bit-width + return (predicates != null) ? predicates : EMPTY; // Predicates are isolated to save bit-width } @Override diff --git a/src/test/java/com/ebremer/beakgraph/CdtHardeningTest.java b/src/test/java/com/ebremer/beakgraph/CdtHardeningTest.java new file mode 100644 index 00000000..bda9f4c2 --- /dev/null +++ b/src/test/java/com/ebremer/beakgraph/CdtHardeningTest.java @@ -0,0 +1,166 @@ +package com.ebremer.beakgraph; + +import static org.junit.jupiter.api.Assertions.assertEquals; +import static org.junit.jupiter.api.Assertions.assertFalse; +import static org.junit.jupiter.api.Assertions.assertTrue; + +import com.ebremer.beakgraph.core.BeakGraph; +import com.ebremer.beakgraph.hdf5.writers.HDF5Writer; +import java.io.File; +import java.nio.file.Files; +import java.nio.file.Path; +import java.util.ArrayList; +import java.util.List; +import java.util.Set; +import java.util.TreeSet; +import org.apache.jena.query.ARQ; +import org.apache.jena.query.Dataset; +import org.apache.jena.query.QueryExecution; +import org.apache.jena.query.QueryFactory; +import org.apache.jena.sparql.SystemARQ; +import org.junit.jupiter.api.AfterAll; +import org.junit.jupiter.api.BeforeAll; +import org.junit.jupiter.api.Test; +import org.junit.jupiter.api.io.TempDir; + +/** + * CDT hardening over a real store (PLAN Part II C.5/C.8/C.10), plus the + * empty-store regression the SPARQL-CDTs suite exposed. + */ +class CdtHardeningTest { + + private static final String PRE = + "PREFIX cdt: PREFIX : "; + + private static final String TTL = """ + @prefix : . + @prefix cdt: . + @prefix xsd: . + :s :list "[9]"^^cdt:List . + :s :list "[10]"^^cdt:List . + :s :list "[2]"^^cdt:List . + :a :val "1"^^xsd:int . + :b :val "7"^^xsd:int . + :c :val "9"^^xsd:int . + """; + + @TempDir + static Path dir; + static BeakGraph bg; + static Dataset ds; + + @BeforeAll + static void build() throws Exception { + Path src = dir.resolve("hardening.ttl"); + Files.writeString(src, TTL); + File dest = dir.resolve("hardening.h5").toFile(); + HDF5Writer.Builder().setSource(src.toFile()).setDestination(dest).build().write(); + bg = BG.getBeakGraph(dest); + ds = bg.getDataset(); + } + + @AfterAll + static void close() throws Exception { + if (bg != null) { + bg.close(); + } + } + + /** + * C.5: ORDER BY over composite literals must use ARQ's value-based relative + * order, not the dictionary's. The two disagree by construction here: the + * dictionary ranks lexically ("[10]" < "[2]" < "[9]"), ARQ ranks by value + * ([2] < [9] < [10]) - if index order leaked through ORDER BY, the result + * order would be lexical. + */ + @Test + void orderByUsesValueOrderNotDictionaryOrder() { + List got = new ArrayList<>(); + try (QueryExecution qe = QueryExecution.dataset(ds) + .query(QueryFactory.create(PRE + "SELECT ?l WHERE { :s :list ?l } ORDER BY ?l")).build()) { + qe.execSelect().forEachRemaining(sol -> + got.add(sol.getLiteral("l").getLexicalForm())); + } + assertEquals(List.of("[2]", "[9]", "[10]"), got, + "ORDER BY must follow ARQ's value order, not the dictionary's lexical order"); + } + + /** + * C.8: numeric range FILTERs must stay exact in a store whose literals + * dictionary ALSO holds composite literals (the ValueCluster pushdown walks + * that dictionary; a composite literal mis-entering a numeric cluster would + * add or drop rows). + */ + @Test + void rangeFiltersStayExactWithCompositeLiteralsPresent() { + assertEquals(Set.of("http://ex.org/b", "http://ex.org/c"), + selectSubjects("SELECT ?s WHERE { ?s :val ?v FILTER(?v > 5) }")); + assertEquals(Set.of("http://ex.org/a"), + selectSubjects("SELECT ?s WHERE { ?s :val ?v FILTER(?v < 5) }")); + assertEquals(Set.of("http://ex.org/s"), + selectSubjects("SELECT ?s WHERE { ?s :list ?l FILTER(?l = \"[9]\"^^cdt:List) }")); + } + + /** + * C.10: {@code ARQ.setStrictMode()} anywhere in the JVM silently flips + * {@code SystemARQ.EnableCDTs} off; opening a BeakGraph dataset must re-pin + * it, because stored cdt: literals need composite semantics to query. + */ + @Test + void enableCdtsIsRePinnedByDatasetCreation() { + try { + ARQ.setStrictMode(); + assertFalse(SystemARQ.EnableCDTs, "strict mode should have flipped the flag off"); + Dataset fresh = bg.getDataset(); // BGDatasetGraph ctor re-pins + assertTrue(SystemARQ.EnableCDTs, "opening a BeakGraph dataset must re-pin EnableCDTs"); + try (QueryExecution qe = QueryExecution.dataset(fresh) + .query(QueryFactory.create(PRE + + "SELECT (cdt:size(\"[1, 2]\"^^cdt:List) AS ?n) WHERE {}")).build()) { + assertEquals(2, qe.execSelect().next().getLiteral("n").getInt()); + } + } finally { + ARQ.setNormalMode(); + } + assertTrue(SystemARQ.EnableCDTs); + } + + /** + * The empty-store regression found by the SPARQL-CDTs suite: a store built + * from an empty source has no dictionary groups at all, and scan-shaped + * queries NPE'd in ScanChunks/SimpleNodeTable on the null dictionaries. + * Every query shape must answer empty instead. + */ + @Test + void emptyStoreAnswersEmptyNotNpe() throws Exception { + Path src = dir.resolve("empty.ttl"); + Files.writeString(src, ""); + File dest = dir.resolve("empty.h5").toFile(); + HDF5Writer.Builder().setSource(src.toFile()).setDestination(dest).build().write(); + try (BeakGraph empty = BG.getBeakGraph(dest)) { + Dataset eds = empty.getDataset(); + for (String q : new String[]{ + "SELECT * WHERE { ?s ?p ?o }", + "SELECT * WHERE { GRAPH ?g { ?s ?p ?o } }", + "SELECT * WHERE { ?p ?o }", + "ASK { ?s ?p ?o }"}) { + try (QueryExecution qe = QueryExecution.dataset(eds) + .query(QueryFactory.create(q)).build()) { + if (qe.getQuery().isAskType()) { + assertFalse(qe.execAsk(), q); + } else { + assertFalse(qe.execSelect().hasNext(), q + " must answer zero rows"); + } + } + } + } + } + + private Set selectSubjects(String query) { + Set out = new TreeSet<>(); + try (QueryExecution qe = QueryExecution.dataset(ds) + .query(QueryFactory.create(PRE + query)).build()) { + qe.execSelect().forEachRemaining(sol -> out.add(sol.getResource("s").getURI())); + } + return out; + } +} diff --git a/src/test/java/com/ebremer/beakgraph/cdt/SparqlCdtSuiteTest.java b/src/test/java/com/ebremer/beakgraph/cdt/SparqlCdtSuiteTest.java new file mode 100644 index 00000000..f38a527b --- /dev/null +++ b/src/test/java/com/ebremer/beakgraph/cdt/SparqlCdtSuiteTest.java @@ -0,0 +1,279 @@ +package com.ebremer.beakgraph.cdt; + +import static org.junit.jupiter.api.Assertions.assertEquals; +import static org.junit.jupiter.api.Assertions.assertThrows; +import static org.junit.jupiter.api.Assertions.assertTrue; +import static org.junit.jupiter.api.Assertions.fail; + +import com.ebremer.beakgraph.BG; +import com.ebremer.beakgraph.core.BeakGraph; +import com.ebremer.beakgraph.core.lib.CdtTerms; +import com.ebremer.beakgraph.hdf5.writers.HDF5Writer; +import java.io.File; +import java.nio.file.Files; +import java.nio.file.Path; +import java.nio.file.Paths; +import java.util.ArrayList; +import java.util.HashMap; +import java.util.Iterator; +import java.util.List; +import java.util.Map; +import java.util.Optional; +import java.util.stream.Stream; +import org.apache.jena.query.Query; +import org.apache.jena.query.QueryExecution; +import org.apache.jena.query.QueryFactory; +import org.apache.jena.query.ResultSetFactory; +import org.apache.jena.query.ResultSetRewindable; +import org.apache.jena.rdf.model.Model; +import org.apache.jena.rdf.model.RDFNode; +import org.apache.jena.rdf.model.Resource; +import org.apache.jena.riot.RDFDataMgr; +import org.apache.jena.sparql.resultset.ResultsCompare; +import org.apache.jena.sparql.resultset.SPARQLResult; +import org.junit.jupiter.api.DynamicContainer; +import org.junit.jupiter.api.DynamicNode; +import org.junit.jupiter.api.DynamicTest; +import org.junit.jupiter.api.TestFactory; +import org.junit.jupiter.api.io.TempDir; + +/** + * Manifest-driven runner for the vendored SPARQL-CDTs test suite + * (src/test/resources/sparql-cdts - see its README for provenance): 658 + * mf:QueryEvaluationTest entries, each executed over a REAL BeakGraph store + * built from the test's data file (stores cached per distinct data file). + * + *

    Two policy carve-outs, both asserted rather than ignored: + *

      + *
    • Tests whose DATA contains blank nodes inside composite literals assert + * BeakGraph's documented reject-at-ingest guard instead of evaluating - + * BeakGraph regenerates blank-node labels from dictionary rank, so the + * spec's import co-reference (its section 5.2) cannot be preserved.
    • + *
    • Queries using SERVICE abort: they need a remote endpoint.
    • + *
    + */ +class SparqlCdtSuiteTest { + + private static final String MF = "http://www.w3.org/2001/sw/DataAccess/tests/test-manifest#"; + private static final String QT = "http://www.w3.org/2001/sw/DataAccess/tests/test-query#"; + + @TempDir + static Path tmp; + + /** data file -> built store; empty Optional = rejected by the CDT blank-node policy. */ + private static final Map> STORES = new HashMap<>(); + + @TestFactory + Stream sparqlCdts() { + Path root = resourcePath("/sparql-cdts/tests/manifest-all.ttl"); + Model top = RDFDataMgr.loadModel(root.toUri().toString()); + Resource manifest = top.listResourcesWithProperty( + top.createProperty(MF, "include")).nextResource(); + List containers = new ArrayList<>(); + Iterator includes = manifest.getProperty(top.createProperty(MF, "include")) + .getObject().as(org.apache.jena.rdf.model.RDFList.class).iterator(); + while (includes.hasNext()) { + containers.add(subManifest(toPath(includes.next().asResource().getURI()))); + } + return containers.stream(); + } + + private DynamicContainer subManifest(Path manifestPath) { + Model m = RDFDataMgr.loadModel(manifestPath.toUri().toString()); + Resource manifest = m.listResourcesWithProperty( + m.createProperty(MF, "entries")).nextResource(); + List tests = new ArrayList<>(); + Iterator entries = manifest.getProperty(m.createProperty(MF, "entries")) + .getObject().as(org.apache.jena.rdf.model.RDFList.class).iterator(); + while (entries.hasNext()) { + Resource entry = entries.next().asResource(); + String name = entry.getProperty(m.createProperty(MF, "name")).getString(); + Resource action = entry.getProperty(m.createProperty(MF, "action")) + .getObject().asResource(); + Path query = toPath(action.getProperty(m.createProperty(QT, "query")) + .getObject().asResource().getURI()); + // A test's dataset is either one-or-more qt:data files, or (the + // bnodes export tests) a qt:constructDataFile: a CONSTRUCT query + // whose serialization, in the given format, becomes the data. + List data = new ArrayList<>(); + action.listProperties(m.createProperty(QT, "data")).forEachRemaining(st -> + data.add(toPath(st.getObject().asResource().getURI()))); + Resource constructData = action.hasProperty(m.createProperty(QT, "constructDataFile")) + ? action.getProperty(m.createProperty(QT, "constructDataFile")).getObject().asResource() + : null; + Path constructQuery = (constructData != null) + ? toPath(constructData.getProperty(m.createProperty(QT, "query")) + .getObject().asResource().getURI()) + : null; + String constructFormat = (constructData != null) + ? constructData.getProperty(m.createProperty(QT, "format")).getString() + : null; + Path result = toPath(entry.getProperty(m.createProperty(MF, "result")) + .getObject().asResource().getURI()); + tests.add(DynamicTest.dynamicTest(name, + () -> runEntry(query, data, constructQuery, constructFormat, result))); + } + String label = manifestPath.getParent().getFileName() + " (" + tests.size() + ")"; + return DynamicContainer.dynamicContainer(label, tests); + } + + private void runEntry(Path queryFile, List dataFiles, Path constructQuery, + String constructFormat, Path resultFile) throws Exception { + String queryText = Files.readString(queryFile); + if (queryText.matches("(?s).*\\bSERVICE\\b.*")) { + org.junit.jupiter.api.Assumptions.abort("requires a remote SPARQL endpoint (SERVICE)"); + } + if (constructQuery != null) { + // Materialize the constructed dataset exactly as the manifest asks + // (run the CONSTRUCT, serialize in the requested format), then treat + // it as ordinary data - if it carries blank nodes inside composite + // literals (these tests exist to check exactly that export scoping), + // it lands in the policy-rejection branch below like any other data. + dataFiles = List.of(materializeConstructedData(constructQuery, constructFormat)); + } + + Optional store = storeFor(dataFiles); + if (store.isEmpty()) { + // Data carries a blank node inside a composite literal: BeakGraph's + // documented policy is loud rejection at ingest (the co-reference the + // spec requires cannot survive rank-derived relabeling). The build + // failure IS the expected behavior; assert it fired on the guard. + List rejected = dataFiles; + Exception ex = assertThrows(Exception.class, () -> build(rejected)); + assertTrue(chainMentions(ex, "blank node inside cdt: composite literal"), + "build failed, but not on the CDT blank-node guard: " + ex); + return; + } + + Query query = QueryFactory.create(queryText, queryFile.toUri().toString()); + SPARQLResult expected = ResultSetFactory.result(resultFile.toString()); + try (BeakGraph bg = BG.getBeakGraph(store.get()); + QueryExecution qe = QueryExecution.dataset(bg.getDataset()).query(query).build()) { + if (query.isAskType()) { + assertEquals(expected.getBooleanResult(), qe.execAsk(), + "ASK result mismatch"); + } else if (query.isSelectType()) { + ResultSetRewindable act = ResultSetFactory.makeRewindable(qe.execSelect()); + ResultSetRewindable exp = ResultSetFactory.makeRewindable(expected.getResultSet()); + boolean ordered = query.hasOrderBy(); + boolean ok = ordered + ? ResultsCompare.equalsByTermAndOrder(exp, act) + : ResultsCompare.equalsByTerm(exp, act); + if (!ok) { + exp.reset(); + act.reset(); + ok = ordered + ? ResultsCompare.equalsByValueAndOrder(exp, act) + : ResultsCompare.equalsByValue(exp, act); + } + if (!ok) { + exp.reset(); + act.reset(); + fail("SELECT results differ" + (ordered ? " (order-sensitive)" : "") + "\n--- expected:\n" + + org.apache.jena.query.ResultSetFormatter.asText(exp) + + "--- actual:\n" + + org.apache.jena.query.ResultSetFormatter.asText(act)); + } + } else if (query.isConstructType()) { + Model act = qe.execConstruct(); + assertTrue(act.isIsomorphicWith(expected.getModel()), + "CONSTRUCT result not isomorphic to expected"); + } else { + fail("unhandled query type in test suite: " + queryFile.getFileName()); + } + } + } + + private static synchronized Optional storeFor(List dataFiles) throws Exception { + String key = dataFiles.isEmpty() ? "" + : String.join("|", dataFiles.stream().map(Path::toString).toList()); + Optional cached = STORES.get(key); + if (cached != null) { + return cached; + } + Optional value; + if (dataFiles.isEmpty()) { + Path empty = tmp.resolve("no-data.ttl"); + if (!Files.exists(empty)) { + Files.writeString(empty, ""); + } + value = Optional.of(build(List.of(empty))); + } else if (dataFiles.stream().anyMatch(SparqlCdtSuiteTest::dataContainsCdtBlankNode)) { + value = Optional.empty(); + } else { + value = Optional.of(build(dataFiles)); + } + STORES.put(key, value); + return value; + } + + private static boolean dataContainsCdtBlankNode(Path dataFile) { + Model m = RDFDataMgr.loadModel(dataFile.toUri().toString()); + var it = m.listStatements(); + while (it.hasNext()) { + if (CdtTerms.containsBlankNode(it.nextStatement().getObject().asNode())) { + return true; + } + } + return false; + } + + private static File build(List srcs) throws Exception { + String stem = srcs.get(0).getFileName().toString().replaceAll("[^A-Za-z0-9.-]", "_"); + File dest = tmp.resolve(stem + "-" + Math.abs(String.join("|", + srcs.stream().map(Path::toString).toList()).hashCode()) + ".h5").toFile(); + HDF5Writer.Builder b = HDF5Writer.Builder().setDestination(dest); + if (srcs.size() == 1) { + b.setSource(srcs.get(0).toFile()); + } else { + // Multi-file tests check cross-document blank-node scoping; the merge + // path keeps blank nodes distinct per source document, as they require. + b.setSources(srcs.stream().map(Path::toFile).toList()); + } + b.build().write(); + return dest; + } + + private Path materializeConstructedData(Path constructQuery, String format) throws Exception { + Query q = QueryFactory.create(Files.readString(constructQuery), + constructQuery.toUri().toString()); + Model constructed; + try (QueryExecution qe = QueryExecution.dataset( + org.apache.jena.query.DatasetFactory.create()).query(q).build()) { + constructed = qe.execConstruct(); + } + boolean turtle = format.contains("turtle"); + Path out = tmp.resolve("constructed-" + Math.abs(constructQuery.hashCode()) + + (turtle ? ".ttl" : ".nt")); + try (var os = Files.newOutputStream(out)) { + RDFDataMgr.write(os, constructed, + turtle ? org.apache.jena.riot.Lang.TURTLE : org.apache.jena.riot.Lang.NTRIPLES); + } + return out; + } + + private static boolean chainMentions(Throwable t, String marker) { + for (Throwable c = t; c != null; c = c.getCause()) { + if (c.getMessage() != null && c.getMessage().contains(marker)) { + return true; + } + } + return false; + } + + private static Path resourcePath(String resource) { + try { + var url = SparqlCdtSuiteTest.class.getResource(resource); + if (url == null) { + throw new IllegalStateException("vendored suite missing: " + resource); + } + return Paths.get(url.toURI()); + } catch (java.net.URISyntaxException e) { + throw new IllegalStateException(e); + } + } + + private static Path toPath(String fileUri) { + return Paths.get(java.net.URI.create(fileUri)); + } +} diff --git a/src/test/java/com/ebremer/beakgraph/cmdline/ExportTest.java b/src/test/java/com/ebremer/beakgraph/cmdline/ExportTest.java index f2e0ca07..6440164a 100644 --- a/src/test/java/com/ebremer/beakgraph/cmdline/ExportTest.java +++ b/src/test/java/com/ebremer/beakgraph/cmdline/ExportTest.java @@ -123,6 +123,43 @@ void ntExportPreservesBaseDirectionOnBothPaths() throws Exception { "exported base-direction literals must round-trip term-exactly"); } + @Test + void ntExportRoundTripsCompositeLiteralsOnBothPaths() throws Exception { + // Composite (cdt:) literals stress the term formatter: the map's lexical + // form embeds quotes that must be escaped in N-Triples. Fastpath and + // generic writer must agree byte-for-byte and round-trip term-exactly. + String cdtTriples = + " \"[1, 2, 3]\"^^ .\n" + + " \"{\\\"k\\\": 5}\"^^ .\n" + + " \"[[1, 2], [3]]\"^^ .\n"; + File h5 = buildStore("cdt", cdtTriples); + Path out = dir.resolve("cdt.nt"); + + runExport(h5, "NT", false); + byte[] fastpath = Files.readAllBytes(out); + String text = new String(fastpath, StandardCharsets.UTF_8); + assertTrue(text.contains("{\\\"k\\\": 5}"), + "map literal quotes must be NT-escaped:\n" + text); + + Files.delete(out); + System.setProperty("beakgraph.export.fastpath", "false"); + try { + runExport(h5, "NT", false); + } finally { + System.clearProperty("beakgraph.export.fastpath"); + } + byte[] generic = Files.readAllBytes(out); + org.junit.jupiter.api.Assertions.assertArrayEquals(fastpath, generic, + "fastpath must stay byte-identical to the generic writer"); + + Dataset ds = parse(out, Lang.NTRIPLES, false); + Model expected = ModelFactory.createDefaultModel(); + RDFDataMgr.read(expected, new java.io.ByteArrayInputStream( + cdtTriples.getBytes(StandardCharsets.UTF_8)), Lang.NTRIPLES); + assertTrue(ds.getDefaultModel().isIsomorphicWith(expected), + "exported composite literals must round-trip term-exactly"); + } + @Test void ntUpgradesToNqWhenNamedGraphsExist() throws Exception { File h5 = buildStore("upg", QUADS); diff --git a/src/test/java/com/ebremer/beakgraph/core/fuseki/DistinctNodeCounterCdtTest.java b/src/test/java/com/ebremer/beakgraph/core/fuseki/DistinctNodeCounterCdtTest.java new file mode 100644 index 00000000..e1834a80 --- /dev/null +++ b/src/test/java/com/ebremer/beakgraph/core/fuseki/DistinctNodeCounterCdtTest.java @@ -0,0 +1,50 @@ +package com.ebremer.beakgraph.core.fuseki; + +import static org.junit.jupiter.api.Assertions.assertEquals; +import static org.junit.jupiter.api.Assertions.assertTrue; + +import org.apache.jena.datatypes.TypeMapper; +import org.apache.jena.graph.Node; +import org.apache.jena.graph.NodeFactory; +import org.apache.jena.graph.TextDirection; +import org.junit.jupiter.api.BeforeAll; +import org.junit.jupiter.api.Test; + +/** + * The VoID HyperLogLog hash must be TERM-distinct (PLAN C.7 / 2.6): composite + * (cdt:) literals have no canonical form, so value-equal lexically-distinct + * literals are distinct terms; and rdf:dirLangString terms differing only in + * base direction are distinct terms. Hash collisions here would make the + * statistics graph undercount distinct objects. + */ +class DistinctNodeCounterCdtTest { + + private static final String LIST = "http://w3id.org/awslabs/neptune/SPARQL-CDTs/List"; + + @BeforeAll + static void initJena() { + org.apache.jena.sys.JenaSystem.init(); + } + + private static Node list(String lex) { + return NodeFactory.createLiteralDT(lex, TypeMapper.getInstance().getSafeTypeByName(LIST)); + } + + @Test + void compositeLiteralHashIsTermDistinct() { + assertTrue(DistinctNodeCounter.hash(list("[1, 2]")) != DistinctNodeCounter.hash(list("[1,2]")), + "value-equal but lexically distinct composite literals are distinct terms"); + assertEquals(DistinctNodeCounter.hash(list("[1, 2]")), DistinctNodeCounter.hash(list("[1, 2]"))); + } + + @Test + void baseDirectionIsPartOfTheHash() { + Node plain = NodeFactory.createLiteralLang("x", "en"); + Node ltr = NodeFactory.createLiteralDirLang("x", "en", TextDirection.LTR); + Node rtl = NodeFactory.createLiteralDirLang("x", "en", TextDirection.RTL); + assertTrue(DistinctNodeCounter.hash(plain) != DistinctNodeCounter.hash(ltr)); + assertTrue(DistinctNodeCounter.hash(ltr) != DistinctNodeCounter.hash(rtl)); + assertEquals(DistinctNodeCounter.hash(ltr), + DistinctNodeCounter.hash(NodeFactory.createLiteralDirLang("x", "en", TextDirection.LTR))); + } +} diff --git a/src/test/resources/sparql-cdts/LICENSE b/src/test/resources/sparql-cdts/LICENSE new file mode 100644 index 00000000..67db8588 --- /dev/null +++ b/src/test/resources/sparql-cdts/LICENSE @@ -0,0 +1,175 @@ + + Apache License + Version 2.0, January 2004 + http://www.apache.org/licenses/ + + TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION + + 1. Definitions. + + "License" shall mean the terms and conditions for use, reproduction, + and distribution as defined by Sections 1 through 9 of this document. + + "Licensor" shall mean the copyright owner or entity authorized by + the copyright owner that is granting the License. + + "Legal Entity" shall mean the union of the acting entity and all + other entities that control, are controlled by, or are under common + control with that entity. For the purposes of this definition, + "control" means (i) the power, direct or indirect, to cause the + direction or management of such entity, whether by contract or + otherwise, or (ii) ownership of fifty percent (50%) or more of the + outstanding shares, or (iii) beneficial ownership of such entity. + + "You" (or "Your") shall mean an individual or Legal Entity + exercising permissions granted by this License. + + "Source" form shall mean the preferred form for making modifications, + including but not limited to software source code, documentation + source, and configuration files. + + "Object" form shall mean any form resulting from mechanical + transformation or translation of a Source form, including but + not limited to compiled object code, generated documentation, + and conversions to other media types. + + "Work" shall mean the work of authorship, whether in Source or + Object form, made available under the License, as indicated by a + copyright notice that is included in or attached to the work + (an example is provided in the Appendix below). + + "Derivative Works" shall mean any work, whether in Source or Object + form, that is based on (or derived from) the Work and for which the + editorial revisions, annotations, elaborations, or other modifications + represent, as a whole, an original work of authorship. For the purposes + of this License, Derivative Works shall not include works that remain + separable from, or merely link (or bind by name) to the interfaces of, + the Work and Derivative Works thereof. + + "Contribution" shall mean any work of authorship, including + the original version of the Work and any modifications or additions + to that Work or Derivative Works thereof, that is intentionally + submitted to Licensor for inclusion in the Work by the copyright owner + or by an individual or Legal Entity authorized to submit on behalf of + the copyright owner. For the purposes of this definition, "submitted" + means any form of electronic, verbal, or written communication sent + to the Licensor or its representatives, including but not limited to + communication on electronic mailing lists, source code control systems, + and issue tracking systems that are managed by, or on behalf of, the + Licensor for the purpose of discussing and improving the Work, but + excluding communication that is conspicuously marked or otherwise + designated in writing by the copyright owner as "Not a Contribution." + + "Contributor" shall mean Licensor and any individual or Legal Entity + on behalf of whom a Contribution has been received by Licensor and + subsequently incorporated within the Work. + + 2. Grant of Copyright License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + copyright license to reproduce, prepare Derivative Works of, + publicly display, publicly perform, sublicense, and distribute the + Work and such Derivative Works in Source or Object form. + + 3. Grant of Patent License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + (except as stated in this section) patent license to make, have made, + use, offer to sell, sell, import, and otherwise transfer the Work, + where such license applies only to those patent claims licensable + by such Contributor that are necessarily infringed by their + Contribution(s) alone or by combination of their Contribution(s) + with the Work to which such Contribution(s) was submitted. If You + institute patent litigation against any entity (including a + cross-claim or counterclaim in a lawsuit) alleging that the Work + or a Contribution incorporated within the Work constitutes direct + or contributory patent infringement, then any patent licenses + granted to You under this License for that Work shall terminate + as of the date such litigation is filed. + + 4. Redistribution. You may reproduce and distribute copies of the + Work or Derivative Works thereof in any medium, with or without + modifications, and in Source or Object form, provided that You + meet the following conditions: + + (a) You must give any other recipients of the Work or + Derivative Works a copy of this License; and + + (b) You must cause any modified files to carry prominent notices + stating that You changed the files; and + + (c) You must retain, in the Source form of any Derivative Works + that You distribute, all copyright, patent, trademark, and + attribution notices from the Source form of the Work, + excluding those notices that do not pertain to any part of + the Derivative Works; and + + (d) If the Work includes a "NOTICE" text file as part of its + distribution, then any Derivative Works that You distribute must + include a readable copy of the attribution notices contained + within such NOTICE file, excluding those notices that do not + pertain to any part of the Derivative Works, in at least one + of the following places: within a NOTICE text file distributed + as part of the Derivative Works; within the Source form or + documentation, if provided along with the Derivative Works; or, + within a display generated by the Derivative Works, if and + wherever such third-party notices normally appear. The contents + of the NOTICE file are for informational purposes only and + do not modify the License. You may add Your own attribution + notices within Derivative Works that You distribute, alongside + or as an addendum to the NOTICE text from the Work, provided + that such additional attribution notices cannot be construed + as modifying the License. + + You may add Your own copyright statement to Your modifications and + may provide additional or different license terms and conditions + for use, reproduction, or distribution of Your modifications, or + for any such Derivative Works as a whole, provided Your use, + reproduction, and distribution of the Work otherwise complies with + the conditions stated in this License. + + 5. Submission of Contributions. Unless You explicitly state otherwise, + any Contribution intentionally submitted for inclusion in the Work + by You to the Licensor shall be under the terms and conditions of + this License, without any additional terms or conditions. + Notwithstanding the above, nothing herein shall supersede or modify + the terms of any separate license agreement you may have executed + with Licensor regarding such Contributions. + + 6. Trademarks. This License does not grant permission to use the trade + names, trademarks, service marks, or product names of the Licensor, + except as required for reasonable and customary use in describing the + origin of the Work and reproducing the content of the NOTICE file. + + 7. Disclaimer of Warranty. Unless required by applicable law or + agreed to in writing, Licensor provides the Work (and each + Contributor provides its Contributions) on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or + implied, including, without limitation, any warranties or conditions + of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A + PARTICULAR PURPOSE. You are solely responsible for determining the + appropriateness of using or redistributing the Work and assume any + risks associated with Your exercise of permissions under this License. + + 8. Limitation of Liability. In no event and under no legal theory, + whether in tort (including negligence), contract, or otherwise, + unless required by applicable law (such as deliberate and grossly + negligent acts) or agreed to in writing, shall any Contributor be + liable to You for damages, including any direct, indirect, special, + incidental, or consequential damages of any character arising as a + result of this License or out of the use or inability to use the + Work (including but not limited to damages for loss of goodwill, + work stoppage, computer failure or malfunction, or any and all + other commercial damages or losses), even if such Contributor + has been advised of the possibility of such damages. + + 9. Accepting Warranty or Additional Liability. While redistributing + the Work or Derivative Works thereof, You may choose to offer, + and charge a fee for, acceptance of support, warranty, indemnity, + or other liability obligations and/or rights consistent with this + License. However, in accepting such obligations, You may act only + on Your own behalf and on Your sole responsibility, not on behalf + of any other Contributor, and only if You agree to indemnify, + defend, and hold each Contributor harmless for any liability + incurred by, or claims asserted against, such Contributor by reason + of your accepting any such warranty or additional liability. diff --git a/src/test/resources/sparql-cdts/NOTICE b/src/test/resources/sparql-cdts/NOTICE new file mode 100644 index 00000000..616fc588 --- /dev/null +++ b/src/test/resources/sparql-cdts/NOTICE @@ -0,0 +1 @@ +Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. diff --git a/src/test/resources/sparql-cdts/README.md b/src/test/resources/sparql-cdts/README.md new file mode 100644 index 00000000..40740810 --- /dev/null +++ b/src/test/resources/sparql-cdts/README.md @@ -0,0 +1,13 @@ +# SPARQL-CDTs test suite (vendored) + +Vendored from https://github.com/awslabs/SPARQL-CDTs (path `tests/`), +commit `bc8fe1a560038ce75c32b8f529216a94fef23116`, on 2026-07-16. Apache-2.0 (see LICENSE, NOTICE). + +658 mf:QueryEvaluationTest entries across unfold, fold, list-functions, +map-functions, orderby, and bnodes sub-manifests. + +Runner: `com.ebremer.beakgraph.cdt.SparqlCdtSuiteTest` — each test's data +builds a real BeakGraph store (cached per distinct data file) and the query +runs over it. Tests whose DATA contains blank nodes inside composite literals +assert BeakGraph's documented rejection instead (the reject-at-ingest policy; +see RDF_1.1-compliance.md). diff --git a/src/test/resources/sparql-cdts/tests/README.md b/src/test/resources/sparql-cdts/tests/README.md new file mode 100644 index 00000000..19e03f6c --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/README.md @@ -0,0 +1,12 @@ +# Test Suite for the SPARQL-CDT Approach +This directory contains contains a test suite with a comprehensive collection of tests that developers of RDF and SPARQL systems can use to check whether their implementation of the different features of the SPARQL-CDTs approach is correct. The test suite includes tests: +* for [the FOLD aggregate](https://w3id.org/awslabs/neptune/SPARQL-CDTs/spec/latest.html#fold) (these tests are in the [fold](https://github.com/awslabs/SPARQL-CDTs/tree/main/tests/fold) directory), +* for [the UNFOLD operator](https://w3id.org/awslabs/neptune/SPARQL-CDTs/spec/latest.html#unfold) (these tests are in the [unfold](https://github.com/awslabs/SPARQL-CDTs/tree/main/tests/unfold) directory), +* for [the functions for cdt:List literals](https://w3id.org/awslabs/neptune/SPARQL-CDTs/spec/latest.html#list-functions) (these tests are in the [list-functions](https://github.com/awslabs/SPARQL-CDTs/tree/main/tests/list-functions) directory), +* for [the functions for cdt:Map literals](https://w3id.org/awslabs/neptune/SPARQL-CDTs/spec/latest.html#map-functions) (these tests are in the [map-functions](https://github.com/awslabs/SPARQL-CDTs/tree/main/tests/map-functions) directory), and +* for [the corresponding extension of the ORDER BY operator](https://w3id.org/awslabs/neptune/SPARQL-CDTs/spec/latest.html#extension-of-order-by) (these tests are in the [orderby](https://github.com/awslabs/SPARQL-CDTs/tree/main/tests/orderby) directory). + +The test suite is described in RDF using the [framework](https://www.w3.org/2001/sw/DataAccess/tests/README.html) that was defined by the +[RDF Data Access Working Group](https://www.w3.org/2001/sw/DataAccess/homepage-20080115) of the [W3C](https://www.w3.org/). Since this framework is integrated into the test harnesses of many RDF and SPARQL systems, providing the test suite in this form should make it easy for implementers to use these tests if they want to extend their systems with support for the SPARQL-CDTs approach. + +To run the complete test suite (i.e., the tests in all of the subdirectories) use the `manifest-all.ttl` file in this directory. To run an individual set of tests use the `manifest.ttl` file in the corresponding subdirectory (as listed above). diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-export-rdf-01-construct.rq b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-export-rdf-01-construct.rq new file mode 100644 index 00000000..2e3355b4 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-export-rdf-01-construct.rq @@ -0,0 +1,10 @@ +PREFIX cdt: +PREFIX ex: + +CONSTRUCT { + ?b ex:list ?list +} +WHERE { + BIND(BNODE() AS ?b) + BIND(cdt:List(?b) AS ?list) +} diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-export-rdf-01.rq b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-export-rdf-01.rq new file mode 100644 index 00000000..3c54f9db --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-export-rdf-01.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX ex: + +ASK { + ?b ex:list ?list . + BIND(cdt:get(?list, 1) AS ?e) + FILTER(SAMETERM(?b, ?e)) +} diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-export-service-01.rq b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-export-service-01.rq new file mode 100644 index 00000000..b4ac70ab --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-export-service-01.rq @@ -0,0 +1,11 @@ +PREFIX cdt: +PREFIX ex: + +ASK { + SERVICE { + BIND(BNODE() AS ?b) + BIND(cdt:List(?b) AS ?list) + } + BIND(cdt:get(?list, 1) AS ?e) + FILTER(SAMETERM(?b, ?e)) +} diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-01.rq b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-01.rq new file mode 100644 index 00000000..e4d9c2bd --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-01.rq @@ -0,0 +1,13 @@ +PREFIX cdt: +PREFIX ex: + +ASK { + BIND( "[_:b, 42, _:b]"^^cdt:List AS ?list ) + + BIND( cdt:get(?list,1) AS ?e1 ) + BIND( cdt:get(?list,3) AS ?e3 ) + + FILTER( isBLANK(?e1) ) + FILTER( isBLANK(?e3) ) + FILTER( ?e1 = ?e3 ) +} diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-02.rq b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-02.rq new file mode 100644 index 00000000..8e8be35e --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-02.rq @@ -0,0 +1,13 @@ +PREFIX cdt: +PREFIX ex: + +ASK { + BIND( "{ '1': _:b, '2': 42, '3': _:b }"^^cdt:Map AS ?map ) + + BIND( cdt:get(?map,'1') AS ?e1 ) + BIND( cdt:get(?map,'3') AS ?e3 ) + + FILTER( isBLANK(?e1) ) + FILTER( isBLANK(?e3) ) + FILTER( ?e1 = ?e3 ) +} diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-03.rq b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-03.rq new file mode 100644 index 00000000..93ebd566 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-03.rq @@ -0,0 +1,13 @@ +PREFIX cdt: +PREFIX ex: + +ASK { + BIND( "[_:b1, 42, _:b2]"^^cdt:List AS ?list ) + + BIND( cdt:get(?list,1) AS ?e1 ) + BIND( cdt:get(?list,3) AS ?e3 ) + + FILTER( isBLANK(?e1) ) + FILTER( isBLANK(?e3) ) + FILTER( ?e1 != ?e3 ) +} diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-04.rq b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-04.rq new file mode 100644 index 00000000..f2ce31b6 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-04.rq @@ -0,0 +1,13 @@ +PREFIX cdt: +PREFIX ex: + +ASK { + BIND( "{ '1': _:b1, '2': 42, '3': _:b2 }"^^cdt:Map AS ?map ) + + BIND( cdt:get(?map,'1') AS ?e1 ) + BIND( cdt:get(?map,'3') AS ?e3 ) + + FILTER( isBLANK(?e1) ) + FILTER( isBLANK(?e3) ) + FILTER( ?e1 != ?e3 ) +} diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-05.rq b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-05.rq new file mode 100644 index 00000000..d2b344da --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-05.rq @@ -0,0 +1,14 @@ +PREFIX cdt: +PREFIX ex: + +ASK { + BIND( "[_:b, 42]"^^cdt:List AS ?list1 ) + BIND( "[_:b, 43]"^^cdt:List AS ?list2 ) + + BIND( cdt:get(?list1,1) AS ?e1 ) + BIND( cdt:get(?list2,1) AS ?e2 ) + + FILTER( isBLANK(?e1) ) + FILTER( isBLANK(?e2) ) + FILTER( ?e1 = ?e2 ) +} diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-06.rq b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-06.rq new file mode 100644 index 00000000..c850d8e4 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-06.rq @@ -0,0 +1,14 @@ +PREFIX cdt: +PREFIX ex: + +ASK { + BIND( "{ '1': _:b, '2': 42 }"^^cdt:Map AS ?map1 ) + BIND( "{ '1': _:b, '2': 43 }"^^cdt:Map AS ?map2 ) + + BIND( cdt:get(?map1,'1') AS ?e1 ) + BIND( cdt:get(?map2,'1') AS ?e2 ) + + FILTER( isBLANK(?e1) ) + FILTER( isBLANK(?e2) ) + FILTER( ?e1 = ?e2 ) +} diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-07.rq b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-07.rq new file mode 100644 index 00000000..61386dbb --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-07.rq @@ -0,0 +1,14 @@ +PREFIX cdt: +PREFIX ex: + +ASK { + BIND( "[_:b1, 42]"^^cdt:List AS ?list1 ) + BIND( "[_:b2, 43]"^^cdt:List AS ?list2 ) + + BIND( cdt:get(?list1,1) AS ?e1 ) + BIND( cdt:get(?list2,1) AS ?e2 ) + + FILTER( isBLANK(?e1) ) + FILTER( isBLANK(?e2) ) + FILTER( ?e1 != ?e2 ) +} diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-08.rq b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-08.rq new file mode 100644 index 00000000..918c6429 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-08.rq @@ -0,0 +1,14 @@ +PREFIX cdt: +PREFIX ex: + +ASK { + BIND( "{ '1': _:b1, '2': 42 }"^^cdt:Map AS ?map1 ) + BIND( "{ '1': _:b2, '2': 43 }"^^cdt:Map AS ?map2 ) + + BIND( cdt:get(?map1,'1') AS ?e1 ) + BIND( cdt:get(?map2,'1') AS ?e2 ) + + FILTER( isBLANK(?e1) ) + FILTER( isBLANK(?e2) ) + FILTER( ?e1 != ?e2 ) +} diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-09.rq b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-09.rq new file mode 100644 index 00000000..5b95fe6d --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-09.rq @@ -0,0 +1,14 @@ +PREFIX cdt: +PREFIX ex: + +ASK { + BIND( "[ _:b, 42 ]"^^cdt:List AS ?list ) + BIND( "{ '1': _:b, '2': 43 }"^^cdt:Map AS ?map ) + + BIND( cdt:get(?list,1) AS ?e1 ) + BIND( cdt:get(?map,'1') AS ?e2 ) + + FILTER( isBLANK(?e1) ) + FILTER( isBLANK(?e2) ) + FILTER( ?e1 = ?e2 ) +} diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-11.rq b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-11.rq new file mode 100644 index 00000000..422c6aaa --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-11.rq @@ -0,0 +1,14 @@ +PREFIX cdt: +PREFIX ex: + +ASK { + BIND( "[_:b, 42, [_:b] ]"^^cdt:List AS ?list ) + + BIND( cdt:get(?list,1) AS ?e1 ) + BIND( cdt:get(?list,3) AS ?innerlist ) + BIND( cdt:get(?innerlist,1) AS ?e3 ) + + FILTER( isBLANK(?e1) ) + FILTER( isBLANK(?e3) ) + FILTER( ?e1 = ?e3 ) +} diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-12.rq b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-12.rq new file mode 100644 index 00000000..a4f54282 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-12.rq @@ -0,0 +1,14 @@ +PREFIX cdt: +PREFIX ex: + +ASK { + BIND( "{ '1': _:b, '2': 42, '3': {'4': _:b} }"^^cdt:Map AS ?map ) + + BIND( cdt:get(?map,'1') AS ?e1 ) + BIND( cdt:get(?map,'3') AS ?innermap ) + BIND( cdt:get(?innermap,'4') AS ?e3 ) + + FILTER( isBLANK(?e1) ) + FILTER( isBLANK(?e3) ) + FILTER( ?e1 = ?e3 ) +} diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-13.rq b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-13.rq new file mode 100644 index 00000000..4d15b0ba --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-13.rq @@ -0,0 +1,14 @@ +PREFIX cdt: +PREFIX ex: + +ASK { + BIND( "[_:b1, 42, [_:b2] ]"^^cdt:List AS ?list ) + + BIND( cdt:get(?list,1) AS ?e1 ) + BIND( cdt:get(?list,3) AS ?innerlist ) + BIND( cdt:get(?innerlist,1) AS ?e3 ) + + FILTER( isBLANK(?e1) ) + FILTER( isBLANK(?e3) ) + FILTER( ?e1 != ?e3 ) +} diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-14.rq b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-14.rq new file mode 100644 index 00000000..dd785407 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-14.rq @@ -0,0 +1,14 @@ +PREFIX cdt: +PREFIX ex: + +ASK { + BIND( "{ '1': _:b1, '2': 42, '3': {'4': _:b2} }"^^cdt:Map AS ?map ) + + BIND( cdt:get(?map,'1') AS ?e1 ) + BIND( cdt:get(?map,'3') AS ?innermap ) + BIND( cdt:get(?innermap,'4') AS ?e3 ) + + FILTER( isBLANK(?e1) ) + FILTER( isBLANK(?e3) ) + FILTER( ?e1 != ?e3 ) +} diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-15.rq b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-15.rq new file mode 100644 index 00000000..b9eb1238 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-15.rq @@ -0,0 +1,15 @@ +PREFIX cdt: +PREFIX ex: + +ASK { + BIND( "[_:b, 42]"^^cdt:List AS ?list1 ) + BIND( "[ [_:b], 43]"^^cdt:List AS ?list2 ) + + BIND( cdt:get(?list1,1) AS ?e1 ) + BIND( cdt:get(?list2,1) AS ?innerlist ) + BIND( cdt:get(?innerlist,1) AS ?e2 ) + + FILTER( isBLANK(?e1) ) + FILTER( isBLANK(?e2) ) + FILTER( ?e1 = ?e2 ) +} diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-16.rq b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-16.rq new file mode 100644 index 00000000..945ee890 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-16.rq @@ -0,0 +1,15 @@ +PREFIX cdt: +PREFIX ex: + +ASK { + BIND( "{ '1': _:b, '2': 42 }"^^cdt:Map AS ?map1 ) + BIND( "{ '1': {'3': _:b}, '2': 43 }"^^cdt:Map AS ?map2 ) + + BIND( cdt:get(?map1,'1') AS ?e1 ) + BIND( cdt:get(?map2,'1') AS ?innermap ) + BIND( cdt:get(?innermap,'3') AS ?e2 ) + + FILTER( isBLANK(?e1) ) + FILTER( isBLANK(?e2) ) + FILTER( ?e1 = ?e2 ) +} diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-17.rq b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-17.rq new file mode 100644 index 00000000..cdfef2ed --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-17.rq @@ -0,0 +1,15 @@ +PREFIX cdt: +PREFIX ex: + +ASK { + BIND( "[_:b1, 42]"^^cdt:List AS ?list1 ) + BIND( "[ [_:b2], 43]"^^cdt:List AS ?list2 ) + + BIND( cdt:get(?list1,1) AS ?e1 ) + BIND( cdt:get(?list2,1) AS ?innerlist ) + BIND( cdt:get(?innerlist,1) AS ?e2 ) + + FILTER( isBLANK(?e1) ) + FILTER( isBLANK(?e2) ) + FILTER( ?e1 != ?e2 ) +} diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-18.rq b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-18.rq new file mode 100644 index 00000000..307e0313 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-18.rq @@ -0,0 +1,15 @@ +PREFIX cdt: +PREFIX ex: + +ASK { + BIND( "{ '1': _:b1, '2': 42 }"^^cdt:Map AS ?map1 ) + BIND( "{ '1': {'3': _:b2}, '2': 43 }"^^cdt:Map AS ?map2 ) + + BIND( cdt:get(?map1,'1') AS ?e1 ) + BIND( cdt:get(?map2,'1') AS ?innermap ) + BIND( cdt:get(?innermap,'3') AS ?e2 ) + + FILTER( isBLANK(?e1) ) + FILTER( isBLANK(?e2) ) + FILTER( ?e1 != ?e2 ) +} diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-21.rq b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-21.rq new file mode 100644 index 00000000..c53b1c70 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-21.rq @@ -0,0 +1,14 @@ +PREFIX cdt: +PREFIX ex: + +ASK { + BIND( "[_:b, 42, '[_:b]'^^ ]"^^cdt:List AS ?list ) + + BIND( cdt:get(?list,1) AS ?e1 ) + BIND( cdt:get(?list,3) AS ?innerlist ) + BIND( cdt:get(?innerlist,1) AS ?e3 ) + + FILTER( isBLANK(?e1) ) + FILTER( isBLANK(?e3) ) + FILTER( ?e1 = ?e3 ) +} diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-22.rq b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-22.rq new file mode 100644 index 00000000..cc2e538d --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-22.rq @@ -0,0 +1,14 @@ +PREFIX cdt: +PREFIX ex: + +ASK { + BIND( """{ '1': _:b, '2': 42, '3': "{'4': _:b}"^^ }"""^^cdt:Map AS ?map ) + + BIND( cdt:get(?map,'1') AS ?e1 ) + BIND( cdt:get(?map,'3') AS ?innermap ) + BIND( cdt:get(?innermap,'4') AS ?e3 ) + + FILTER( isBLANK(?e1) ) + FILTER( isBLANK(?e3) ) + FILTER( ?e1 = ?e3 ) +} diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-23.rq b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-23.rq new file mode 100644 index 00000000..6aec1c7e --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-23.rq @@ -0,0 +1,14 @@ +PREFIX cdt: +PREFIX ex: + +ASK { + BIND( "[_:b1, 42, '[_:b2]'^^ ]"^^cdt:List AS ?list ) + + BIND( cdt:get(?list,1) AS ?e1 ) + BIND( cdt:get(?list,3) AS ?innerlist ) + BIND( cdt:get(?innerlist,1) AS ?e3 ) + + FILTER( isBLANK(?e1) ) + FILTER( isBLANK(?e3) ) + FILTER( ?e1 != ?e3 ) +} diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-24.rq b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-24.rq new file mode 100644 index 00000000..c1ed49d4 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-24.rq @@ -0,0 +1,14 @@ +PREFIX cdt: +PREFIX ex: + +ASK { + BIND( """{ '1': _:b1, '2': 42, '3': "{'4': _:b2}"^^ }"""^^cdt:Map AS ?map ) + + BIND( cdt:get(?map,'1') AS ?e1 ) + BIND( cdt:get(?map,'3') AS ?innermap ) + BIND( cdt:get(?innermap,'4') AS ?e3 ) + + FILTER( isBLANK(?e1) ) + FILTER( isBLANK(?e3) ) + FILTER( ?e1 != ?e3 ) +} diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-25.rq b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-25.rq new file mode 100644 index 00000000..4a92c370 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-25.rq @@ -0,0 +1,15 @@ +PREFIX cdt: +PREFIX ex: + +ASK { + BIND( "[_:b, 42]"^^cdt:List AS ?list1 ) + BIND( "[ '[_:b]'^^, 43]"^^cdt:List AS ?list2 ) + + BIND( cdt:get(?list1,1) AS ?e1 ) + BIND( cdt:get(?list2,1) AS ?innerlist ) + BIND( cdt:get(?innerlist,1) AS ?e2 ) + + FILTER( isBLANK(?e1) ) + FILTER( isBLANK(?e2) ) + FILTER( ?e1 = ?e2 ) +} diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-26.rq b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-26.rq new file mode 100644 index 00000000..9b72d62f --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-26.rq @@ -0,0 +1,15 @@ +PREFIX cdt: +PREFIX ex: + +ASK { + BIND( "{ '1': _:b, '2': 42 }"^^cdt:Map AS ?map1 ) + BIND( """{ '1': "{'3': _:b}"^^, '2': 43 }"""^^cdt:Map AS ?map2 ) + + BIND( cdt:get(?map1,'1') AS ?e1 ) + BIND( cdt:get(?map2,'1') AS ?innermap ) + BIND( cdt:get(?innermap,'3') AS ?e2 ) + + FILTER( isBLANK(?e1) ) + FILTER( isBLANK(?e2) ) + FILTER( ?e1 = ?e2 ) +} diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-27.rq b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-27.rq new file mode 100644 index 00000000..cd1b9ab2 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-27.rq @@ -0,0 +1,15 @@ +PREFIX cdt: +PREFIX ex: + +ASK { + BIND( "[_:b1, 42]"^^cdt:List AS ?list1 ) + BIND( "[ '[_:b2]'^^, 43]"^^cdt:List AS ?list2 ) + + BIND( cdt:get(?list1,1) AS ?e1 ) + BIND( cdt:get(?list2,1) AS ?innerlist ) + BIND( cdt:get(?innerlist,1) AS ?e2 ) + + FILTER( isBLANK(?e1) ) + FILTER( isBLANK(?e2) ) + FILTER( ?e1 != ?e2 ) +} diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-28.rq b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-28.rq new file mode 100644 index 00000000..84308d2a --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-sparql-28.rq @@ -0,0 +1,15 @@ +PREFIX cdt: +PREFIX ex: + +ASK { + BIND( "{ '1': _:b1, '2': 42 }"^^cdt:Map AS ?map1 ) + BIND( """{ '1': "{'3': _:b2}"^^, '2': 43 }"""^^cdt:Map AS ?map2 ) + + BIND( cdt:get(?map1,'1') AS ?e1 ) + BIND( cdt:get(?map2,'1') AS ?innermap ) + BIND( cdt:get(?innermap,'3') AS ?e2 ) + + FILTER( isBLANK(?e1) ) + FILTER( isBLANK(?e2) ) + FILTER( ?e1 != ?e2 ) +} diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-01.rq b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-01.rq new file mode 100644 index 00000000..0ee93c7b --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-01.rq @@ -0,0 +1,13 @@ +PREFIX cdt: +PREFIX ex: + +ASK { + ex:s ex:p ?list . + + BIND( cdt:get(?list,1) AS ?e1 ) + BIND( cdt:get(?list,3) AS ?e3 ) + + FILTER( isBLANK(?e1) ) + FILTER( isBLANK(?e3) ) + FILTER( ?e1 = ?e3 ) +} diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-01.ttl b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-01.ttl new file mode 100644 index 00000000..eb275273 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-01.ttl @@ -0,0 +1,7 @@ +PREFIX rdf: +PREFIX rdfs: +PREFIX xsd: +PREFIX cdt: +PREFIX ex: + +ex:s ex:p "[_:b, 42, _:b]"^^cdt:List . diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-02.rq b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-02.rq new file mode 100644 index 00000000..7258c34b --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-02.rq @@ -0,0 +1,13 @@ +PREFIX cdt: +PREFIX ex: + +ASK { + ex:s ex:p ?map . + + BIND( cdt:get(?map,'1') AS ?e1 ) + BIND( cdt:get(?map,'3') AS ?e3 ) + + FILTER( isBLANK(?e1) ) + FILTER( isBLANK(?e3) ) + FILTER( ?e1 = ?e3 ) +} diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-02.ttl b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-02.ttl new file mode 100644 index 00000000..90ffb7f2 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-02.ttl @@ -0,0 +1,7 @@ +PREFIX rdf: +PREFIX rdfs: +PREFIX xsd: +PREFIX cdt: +PREFIX ex: + +ex:s ex:p "{ '1': _:b, '2': 42, '3': _:b }"^^cdt:Map . diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-03.rq b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-03.rq new file mode 100644 index 00000000..88d7a34d --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-03.rq @@ -0,0 +1,13 @@ +PREFIX cdt: +PREFIX ex: + +ASK { + ex:s ex:p ?list . + + BIND( cdt:get(?list,1) AS ?e1 ) + BIND( cdt:get(?list,3) AS ?e3 ) + + FILTER( isBLANK(?e1) ) + FILTER( isBLANK(?e3) ) + FILTER( ?e1 != ?e3 ) +} diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-03.ttl b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-03.ttl new file mode 100644 index 00000000..5502a19e --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-03.ttl @@ -0,0 +1,7 @@ +PREFIX rdf: +PREFIX rdfs: +PREFIX xsd: +PREFIX cdt: +PREFIX ex: + +ex:s ex:p "[_:b1, 42, _:b2]"^^cdt:List . diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-04.rq b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-04.rq new file mode 100644 index 00000000..b04cf720 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-04.rq @@ -0,0 +1,13 @@ +PREFIX cdt: +PREFIX ex: + +ASK { + ex:s ex:p ?map . + + BIND( cdt:get(?map,'1') AS ?e1 ) + BIND( cdt:get(?map,'3') AS ?e3 ) + + FILTER( isBLANK(?e1) ) + FILTER( isBLANK(?e3) ) + FILTER( ?e1 != ?e3 ) +} diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-04.ttl b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-04.ttl new file mode 100644 index 00000000..8d7f8d07 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-04.ttl @@ -0,0 +1,7 @@ +PREFIX rdf: +PREFIX rdfs: +PREFIX xsd: +PREFIX cdt: +PREFIX ex: + +ex:s ex:p "{ '1': _:b1, '2': 42, '3': _:b2 }"^^cdt:Map . diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-05.rq b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-05.rq new file mode 100644 index 00000000..36a894ac --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-05.rq @@ -0,0 +1,12 @@ +PREFIX cdt: +PREFIX ex: + +ASK { + ?s ex:p ?list . + + BIND( cdt:get(?list,1) AS ?e1 ) + + FILTER( isBLANK(?s) ) + FILTER( isBLANK(?e1) ) + FILTER( ?s = ?e1 ) +} diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-05.ttl b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-05.ttl new file mode 100644 index 00000000..6194f8e3 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-05.ttl @@ -0,0 +1,7 @@ +PREFIX rdf: +PREFIX rdfs: +PREFIX xsd: +PREFIX cdt: +PREFIX ex: + +_:b ex:p "[_:b, 42]"^^cdt:List . diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-06.rq b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-06.rq new file mode 100644 index 00000000..b2fa647e --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-06.rq @@ -0,0 +1,12 @@ +PREFIX cdt: +PREFIX ex: + +ASK { + ?s ex:p ?map . + + BIND( cdt:get(?map,'1') AS ?e1 ) + + FILTER( isBLANK(?s) ) + FILTER( isBLANK(?e1) ) + FILTER( ?s = ?e1 ) +} diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-06.ttl b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-06.ttl new file mode 100644 index 00000000..05fc3eae --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-06.ttl @@ -0,0 +1,7 @@ +PREFIX rdf: +PREFIX rdfs: +PREFIX xsd: +PREFIX cdt: +PREFIX ex: + +_:b ex:p "{ '1': _:b, '2': 42 }"^^cdt:Map . diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-07.rq b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-07.rq new file mode 100644 index 00000000..04ed6a8b --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-07.rq @@ -0,0 +1,12 @@ +PREFIX cdt: +PREFIX ex: + +ASK { + ?s ex:p ?list . + + BIND( cdt:get(?list,1) AS ?e1 ) + + FILTER( isBLANK(?s) ) + FILTER( isBLANK(?e1) ) + FILTER( ?s != ?e1 ) +} diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-07.ttl b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-07.ttl new file mode 100644 index 00000000..211ee3df --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-07.ttl @@ -0,0 +1,7 @@ +PREFIX rdf: +PREFIX rdfs: +PREFIX xsd: +PREFIX cdt: +PREFIX ex: + +_:b1 ex:p "[_:b2, 42]"^^cdt:List . diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-08.rq b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-08.rq new file mode 100644 index 00000000..e7bb213f --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-08.rq @@ -0,0 +1,12 @@ +PREFIX cdt: +PREFIX ex: + +ASK { + ?s ex:p ?map . + + BIND( cdt:get(?map,'1') AS ?e1 ) + + FILTER( isBLANK(?s) ) + FILTER( isBLANK(?e1) ) + FILTER( ?s != ?e1 ) +} diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-08.ttl b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-08.ttl new file mode 100644 index 00000000..ff9c4133 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-08.ttl @@ -0,0 +1,7 @@ +PREFIX rdf: +PREFIX rdfs: +PREFIX xsd: +PREFIX cdt: +PREFIX ex: + +_:b1 ex:p "{ '1': _:b2, '2': 42 }"^^cdt:Map . diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-09.rq b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-09.rq new file mode 100644 index 00000000..458d01bb --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-09.rq @@ -0,0 +1,14 @@ +PREFIX cdt: +PREFIX ex: + +ASK { + ex:s ex:p1 ?list1 . + ex:s ex:p2 ?list2 . + + BIND( cdt:get(?list1,1) AS ?e1 ) + BIND( cdt:get(?list2,1) AS ?e2 ) + + FILTER( isBLANK(?e1) ) + FILTER( isBLANK(?e2) ) + FILTER( ?e1 = ?e2 ) +} diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-09.ttl b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-09.ttl new file mode 100644 index 00000000..4cbb085b --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-09.ttl @@ -0,0 +1,8 @@ +PREFIX rdf: +PREFIX rdfs: +PREFIX xsd: +PREFIX cdt: +PREFIX ex: + +ex:s ex:p1 "[_:b, 42]"^^cdt:List . +ex:s ex:p2 "[_:b, 43]"^^cdt:List . diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-10.rq b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-10.rq new file mode 100644 index 00000000..523312c8 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-10.rq @@ -0,0 +1,14 @@ +PREFIX cdt: +PREFIX ex: + +ASK { + ex:s ex:p1 ?map1 . + ex:s ex:p2 ?map2 . + + BIND( cdt:get(?map1,'1') AS ?e1 ) + BIND( cdt:get(?map2,'1') AS ?e2 ) + + FILTER( isBLANK(?e1) ) + FILTER( isBLANK(?e2) ) + FILTER( ?e1 = ?e2 ) +} diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-10.ttl b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-10.ttl new file mode 100644 index 00000000..ac3b7836 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-10.ttl @@ -0,0 +1,8 @@ +PREFIX rdf: +PREFIX rdfs: +PREFIX xsd: +PREFIX cdt: +PREFIX ex: + +ex:s ex:p1 "{ '1': _:b, '2': 42 }"^^cdt:Map . +ex:s ex:p2 "{ '1': _:b, '2': 43 }"^^cdt:Map . diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-11.rq b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-11.rq new file mode 100644 index 00000000..ef9a8a05 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-11.rq @@ -0,0 +1,14 @@ +PREFIX cdt: +PREFIX ex: + +ASK { + ex:s ex:p1 ?list1 . + ex:s ex:p2 ?list2 . + + BIND( cdt:get(?list1,1) AS ?e1 ) + BIND( cdt:get(?list2,1) AS ?e2 ) + + FILTER( isBLANK(?e1) ) + FILTER( isBLANK(?e2) ) + FILTER( ?e1 != ?e2 ) +} diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-11.ttl b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-11.ttl new file mode 100644 index 00000000..3372e37b --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-11.ttl @@ -0,0 +1,8 @@ +PREFIX rdf: +PREFIX rdfs: +PREFIX xsd: +PREFIX cdt: +PREFIX ex: + +ex:s ex:p1 "[_:b1, 42]"^^cdt:List . +ex:s ex:p2 "[_:b2, 43]"^^cdt:List . diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-12.rq b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-12.rq new file mode 100644 index 00000000..eda5afd3 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-12.rq @@ -0,0 +1,14 @@ +PREFIX cdt: +PREFIX ex: + +ASK { + ex:s ex:p1 ?map1 . + ex:s ex:p2 ?map2 . + + BIND( cdt:get(?map1,'1') AS ?e1 ) + BIND( cdt:get(?map2,'1') AS ?e2 ) + + FILTER( isBLANK(?e1) ) + FILTER( isBLANK(?e2) ) + FILTER( ?e1 != ?e2 ) +} diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-12.ttl b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-12.ttl new file mode 100644 index 00000000..1cbb9944 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-12.ttl @@ -0,0 +1,8 @@ +PREFIX rdf: +PREFIX rdfs: +PREFIX xsd: +PREFIX cdt: +PREFIX ex: + +ex:s ex:p1 "{ '1': _:b1, '2': 42 }"^^cdt:Map . +ex:s ex:p2 "{ '1': _:b2, '2': 43 }"^^cdt:Map . diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-13.rq b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-13.rq new file mode 100644 index 00000000..02ff4313 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-13.rq @@ -0,0 +1,14 @@ +PREFIX cdt: +PREFIX ex: + +ASK { + ex:s ex:p1 ?list . + ex:s ex:p2 ?map . + + BIND( cdt:get(?list,1) AS ?e1 ) + BIND( cdt:get(?map,'1') AS ?e2 ) + + FILTER( isBLANK(?e1) ) + FILTER( isBLANK(?e2) ) + FILTER( ?e1 = ?e2 ) +} diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-13.ttl b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-13.ttl new file mode 100644 index 00000000..55d61641 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-13.ttl @@ -0,0 +1,8 @@ +PREFIX rdf: +PREFIX rdfs: +PREFIX xsd: +PREFIX cdt: +PREFIX ex: + +ex:s ex:p1 "[ _:b, 42 ]"^^cdt:List . +ex:s ex:p2 "{ '1': _:b, '2': 43 }"^^cdt:Map . diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-14.rq b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-14.rq new file mode 100644 index 00000000..1ae250c6 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-14.rq @@ -0,0 +1,14 @@ +PREFIX cdt: +PREFIX ex: + +ASK { + ex:s ex:p1 ?list . + ex:s ex:p2 ?map . + + BIND( cdt:get(?list,1) AS ?e1 ) + BIND( cdt:get(?map,'1') AS ?e2 ) + + FILTER( isBLANK(?e1) ) + FILTER( isBLANK(?e2) ) + FILTER( ?e1 != ?e2 ) +} diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-14.ttl b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-14.ttl new file mode 100644 index 00000000..1541932a --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-14.ttl @@ -0,0 +1,8 @@ +PREFIX rdf: +PREFIX rdfs: +PREFIX xsd: +PREFIX cdt: +PREFIX ex: + +ex:s ex:p1 "[ _:b1, 42 ]"^^cdt:List . +ex:s ex:p2 "{ '1': _:b2, '2': 43 }"^^cdt:Map . diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-15.rq b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-15.rq new file mode 100644 index 00000000..ef9a8a05 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-15.rq @@ -0,0 +1,14 @@ +PREFIX cdt: +PREFIX ex: + +ASK { + ex:s ex:p1 ?list1 . + ex:s ex:p2 ?list2 . + + BIND( cdt:get(?list1,1) AS ?e1 ) + BIND( cdt:get(?list2,1) AS ?e2 ) + + FILTER( isBLANK(?e1) ) + FILTER( isBLANK(?e2) ) + FILTER( ?e1 != ?e2 ) +} diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-15a.ttl b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-15a.ttl new file mode 100644 index 00000000..9d414841 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-15a.ttl @@ -0,0 +1,7 @@ +PREFIX rdf: +PREFIX rdfs: +PREFIX xsd: +PREFIX cdt: +PREFIX ex: + +ex:s ex:p1 "[_:b, 42]"^^cdt:List . diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-15b.ttl b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-15b.ttl new file mode 100644 index 00000000..c4b0e9de --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-15b.ttl @@ -0,0 +1,7 @@ +PREFIX rdf: +PREFIX rdfs: +PREFIX xsd: +PREFIX cdt: +PREFIX ex: + +ex:s ex:p2 "[_:b, 43]"^^cdt:List . diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-16.rq b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-16.rq new file mode 100644 index 00000000..eda5afd3 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-16.rq @@ -0,0 +1,14 @@ +PREFIX cdt: +PREFIX ex: + +ASK { + ex:s ex:p1 ?map1 . + ex:s ex:p2 ?map2 . + + BIND( cdt:get(?map1,'1') AS ?e1 ) + BIND( cdt:get(?map2,'1') AS ?e2 ) + + FILTER( isBLANK(?e1) ) + FILTER( isBLANK(?e2) ) + FILTER( ?e1 != ?e2 ) +} diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-16a.ttl b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-16a.ttl new file mode 100644 index 00000000..9667eb0b --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-16a.ttl @@ -0,0 +1,7 @@ +PREFIX rdf: +PREFIX rdfs: +PREFIX xsd: +PREFIX cdt: +PREFIX ex: + +ex:s ex:p1 "{ '1': _:b, '2': 42 }"^^cdt:Map . diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-16b.ttl b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-16b.ttl new file mode 100644 index 00000000..3a858d3d --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-16b.ttl @@ -0,0 +1,7 @@ +PREFIX rdf: +PREFIX rdfs: +PREFIX xsd: +PREFIX cdt: +PREFIX ex: + +ex:s ex:p2 "{ '1': _:b, '2': 43 }"^^cdt:Map . diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-17.rq b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-17.rq new file mode 100644 index 00000000..3e89da7c --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-17.rq @@ -0,0 +1,13 @@ +PREFIX cdt: +PREFIX ex: + +ASK { + ex:s ex:p1 ?list . + ex:s ex:p2 ?bn . + + BIND( cdt:get(?list,1) AS ?e1 ) + + FILTER( isBLANK(?e1) ) + FILTER( isBLANK(?bn) ) + FILTER( ?e1 != ?bn ) +} diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-17a.ttl b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-17a.ttl new file mode 100644 index 00000000..9d414841 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-17a.ttl @@ -0,0 +1,7 @@ +PREFIX rdf: +PREFIX rdfs: +PREFIX xsd: +PREFIX cdt: +PREFIX ex: + +ex:s ex:p1 "[_:b, 42]"^^cdt:List . diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-17b.ttl b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-17b.ttl new file mode 100644 index 00000000..fa65368f --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-17b.ttl @@ -0,0 +1,7 @@ +PREFIX rdf: +PREFIX rdfs: +PREFIX xsd: +PREFIX cdt: +PREFIX ex: + +ex:s ex:p2 _:b . diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-18.rq b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-18.rq new file mode 100644 index 00000000..87f7b29f --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-18.rq @@ -0,0 +1,13 @@ +PREFIX cdt: +PREFIX ex: + +ASK { + ex:s ex:p1 ?map . + ex:s ex:p2 ?bn . + + BIND( cdt:get(?map,'1') AS ?e1 ) + + FILTER( isBLANK(?e1) ) + FILTER( isBLANK(?bn) ) + FILTER( ?e1 != ?bn ) +} diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-18a.ttl b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-18a.ttl new file mode 100644 index 00000000..9667eb0b --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-18a.ttl @@ -0,0 +1,7 @@ +PREFIX rdf: +PREFIX rdfs: +PREFIX xsd: +PREFIX cdt: +PREFIX ex: + +ex:s ex:p1 "{ '1': _:b, '2': 42 }"^^cdt:Map . diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-18b.ttl b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-18b.ttl new file mode 100644 index 00000000..fa65368f --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-18b.ttl @@ -0,0 +1,7 @@ +PREFIX rdf: +PREFIX rdfs: +PREFIX xsd: +PREFIX cdt: +PREFIX ex: + +ex:s ex:p2 _:b . diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-19.rq b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-19.rq new file mode 100644 index 00000000..1ae250c6 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-19.rq @@ -0,0 +1,14 @@ +PREFIX cdt: +PREFIX ex: + +ASK { + ex:s ex:p1 ?list . + ex:s ex:p2 ?map . + + BIND( cdt:get(?list,1) AS ?e1 ) + BIND( cdt:get(?map,'1') AS ?e2 ) + + FILTER( isBLANK(?e1) ) + FILTER( isBLANK(?e2) ) + FILTER( ?e1 != ?e2 ) +} diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-19a.ttl b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-19a.ttl new file mode 100644 index 00000000..9d414841 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-19a.ttl @@ -0,0 +1,7 @@ +PREFIX rdf: +PREFIX rdfs: +PREFIX xsd: +PREFIX cdt: +PREFIX ex: + +ex:s ex:p1 "[_:b, 42]"^^cdt:List . diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-19b.ttl b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-19b.ttl new file mode 100644 index 00000000..3a858d3d --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-19b.ttl @@ -0,0 +1,7 @@ +PREFIX rdf: +PREFIX rdfs: +PREFIX xsd: +PREFIX cdt: +PREFIX ex: + +ex:s ex:p2 "{ '1': _:b, '2': 43 }"^^cdt:Map . diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-21.rq b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-21.rq new file mode 100644 index 00000000..9d8ce958 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-21.rq @@ -0,0 +1,14 @@ +PREFIX cdt: +PREFIX ex: + +ASK { + ex:s ex:p ?list . + + BIND( cdt:get(?list,1) AS ?e1 ) + BIND( cdt:get(?list,3) AS ?innerlist ) + BIND( cdt:get(?innerlist,1) AS ?e3 ) + + FILTER( isBLANK(?e1) ) + FILTER( isBLANK(?e3) ) + FILTER( ?e1 = ?e3 ) +} diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-21.ttl b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-21.ttl new file mode 100644 index 00000000..081108e9 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-21.ttl @@ -0,0 +1,7 @@ +PREFIX rdf: +PREFIX rdfs: +PREFIX xsd: +PREFIX cdt: +PREFIX ex: + +ex:s ex:p "[_:b, 42, [_:b] ]"^^cdt:List . diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-22.rq b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-22.rq new file mode 100644 index 00000000..475e111f --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-22.rq @@ -0,0 +1,14 @@ +PREFIX cdt: +PREFIX ex: + +ASK { + ex:s ex:p ?map . + + BIND( cdt:get(?map,'1') AS ?e1 ) + BIND( cdt:get(?map,'3') AS ?innermap ) + BIND( cdt:get(?innermap,'4') AS ?e3 ) + + FILTER( isBLANK(?e1) ) + FILTER( isBLANK(?e3) ) + FILTER( ?e1 = ?e3 ) +} diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-22.ttl b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-22.ttl new file mode 100644 index 00000000..a203de82 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-22.ttl @@ -0,0 +1,7 @@ +PREFIX rdf: +PREFIX rdfs: +PREFIX xsd: +PREFIX cdt: +PREFIX ex: + +ex:s ex:p "{ '1': _:b, '2': 42, '3': {'4': _:b} }"^^cdt:Map . diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-23.rq b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-23.rq new file mode 100644 index 00000000..52d3753a --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-23.rq @@ -0,0 +1,14 @@ +PREFIX cdt: +PREFIX ex: + +ASK { + ex:s ex:p ?list . + + BIND( cdt:get(?list,1) AS ?e1 ) + BIND( cdt:get(?list,3) AS ?innerlist ) + BIND( cdt:get(?innerlist,1) AS ?e3 ) + + FILTER( isBLANK(?e1) ) + FILTER( isBLANK(?e3) ) + FILTER( ?e1 != ?e3 ) +} diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-23.ttl b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-23.ttl new file mode 100644 index 00000000..ca1ec509 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-23.ttl @@ -0,0 +1,7 @@ +PREFIX rdf: +PREFIX rdfs: +PREFIX xsd: +PREFIX cdt: +PREFIX ex: + +ex:s ex:p "[_:b1, 42, [_:b2] ]"^^cdt:List . diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-24.rq b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-24.rq new file mode 100644 index 00000000..e38b5dfa --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-24.rq @@ -0,0 +1,14 @@ +PREFIX cdt: +PREFIX ex: + +ASK { + ex:s ex:p ?map . + + BIND( cdt:get(?map,'1') AS ?e1 ) + BIND( cdt:get(?map,'3') AS ?innermap ) + BIND( cdt:get(?innermap,'4') AS ?e3 ) + + FILTER( isBLANK(?e1) ) + FILTER( isBLANK(?e3) ) + FILTER( ?e1 != ?e3 ) +} diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-24.ttl b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-24.ttl new file mode 100644 index 00000000..e9094880 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-24.ttl @@ -0,0 +1,7 @@ +PREFIX rdf: +PREFIX rdfs: +PREFIX xsd: +PREFIX cdt: +PREFIX ex: + +ex:s ex:p "{ '1': _:b1, '2': 42, '3': {'4': _:b2} }"^^cdt:Map . diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-25.rq b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-25.rq new file mode 100644 index 00000000..773ee2b1 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-25.rq @@ -0,0 +1,13 @@ +PREFIX cdt: +PREFIX ex: + +ASK { + ?s ex:p ?list . + + BIND( cdt:get(?list,1) AS ?innerlist ) + BIND( cdt:get(?innerlist,1) AS ?e1 ) + + FILTER( isBLANK(?s) ) + FILTER( isBLANK(?e1) ) + FILTER( ?s = ?e1 ) +} diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-25.ttl b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-25.ttl new file mode 100644 index 00000000..21935275 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-25.ttl @@ -0,0 +1,7 @@ +PREFIX rdf: +PREFIX rdfs: +PREFIX xsd: +PREFIX cdt: +PREFIX ex: + +_:b ex:p " [ [_:b], 42]"^^cdt:List . diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-26.rq b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-26.rq new file mode 100644 index 00000000..3c6d05d6 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-26.rq @@ -0,0 +1,13 @@ +PREFIX cdt: +PREFIX ex: + +ASK { + ?s ex:p ?map . + + BIND( cdt:get(?map,'1') AS ?innermap ) + BIND( cdt:get(?innermap,'3') AS ?e1 ) + + FILTER( isBLANK(?s) ) + FILTER( isBLANK(?e1) ) + FILTER( ?s = ?e1 ) +} diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-26.ttl b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-26.ttl new file mode 100644 index 00000000..3ed6ba20 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-26.ttl @@ -0,0 +1,7 @@ +PREFIX rdf: +PREFIX rdfs: +PREFIX xsd: +PREFIX cdt: +PREFIX ex: + +_:b ex:p "{ '1': {'3': _:b}, '2': 42 }"^^cdt:Map . diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-27.rq b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-27.rq new file mode 100644 index 00000000..38897009 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-27.rq @@ -0,0 +1,13 @@ +PREFIX cdt: +PREFIX ex: + +ASK { + ?s ex:p ?list . + + BIND( cdt:get(?list,1) AS ?innerlist ) + BIND( cdt:get(?innerlist,1) AS ?e1 ) + + FILTER( isBLANK(?s) ) + FILTER( isBLANK(?e1) ) + FILTER( ?s != ?e1 ) +} diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-27.ttl b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-27.ttl new file mode 100644 index 00000000..ea8e4ec6 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-27.ttl @@ -0,0 +1,7 @@ +PREFIX rdf: +PREFIX rdfs: +PREFIX xsd: +PREFIX cdt: +PREFIX ex: + +_:b1 ex:p "[ [_:b2], 42]"^^cdt:List . diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-28.rq b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-28.rq new file mode 100644 index 00000000..938b2144 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-28.rq @@ -0,0 +1,13 @@ +PREFIX cdt: +PREFIX ex: + +ASK { + ?s ex:p ?map . + + BIND( cdt:get(?map,'1') AS ?innermap ) + BIND( cdt:get(?innermap,'3') AS ?e1 ) + + FILTER( isBLANK(?s) ) + FILTER( isBLANK(?e1) ) + FILTER( ?s != ?e1 ) +} diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-28.ttl b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-28.ttl new file mode 100644 index 00000000..dc0498b1 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-28.ttl @@ -0,0 +1,7 @@ +PREFIX rdf: +PREFIX rdfs: +PREFIX xsd: +PREFIX cdt: +PREFIX ex: + +_:b1 ex:p "{ '1': {'3': _:b2}, '2': 42 }"^^cdt:Map . diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-29.rq b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-29.rq new file mode 100644 index 00000000..7ee3e301 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-29.rq @@ -0,0 +1,15 @@ +PREFIX cdt: +PREFIX ex: + +ASK { + ex:s ex:p1 ?list1 . + ex:s ex:p2 ?list2 . + + BIND( cdt:get(?list1,1) AS ?e1 ) + BIND( cdt:get(?list2,1) AS ?innerlist ) + BIND( cdt:get(?innerlist,1) AS ?e2 ) + + FILTER( isBLANK(?e1) ) + FILTER( isBLANK(?e2) ) + FILTER( ?e1 = ?e2 ) +} diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-29.ttl b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-29.ttl new file mode 100644 index 00000000..80e3b3c5 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-29.ttl @@ -0,0 +1,8 @@ +PREFIX rdf: +PREFIX rdfs: +PREFIX xsd: +PREFIX cdt: +PREFIX ex: + +ex:s ex:p1 "[_:b, 42]"^^cdt:List . +ex:s ex:p2 "[ [_:b], 43]"^^cdt:List . diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-30.rq b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-30.rq new file mode 100644 index 00000000..54e37e63 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-30.rq @@ -0,0 +1,15 @@ +PREFIX cdt: +PREFIX ex: + +ASK { + ex:s ex:p1 ?map1 . + ex:s ex:p2 ?map2 . + + BIND( cdt:get(?map1,'1') AS ?e1 ) + BIND( cdt:get(?map2,'1') AS ?innermap ) + BIND( cdt:get(?innermap,'3') AS ?e2 ) + + FILTER( isBLANK(?e1) ) + FILTER( isBLANK(?e2) ) + FILTER( ?e1 = ?e2 ) +} diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-30.ttl b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-30.ttl new file mode 100644 index 00000000..b5e116b8 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-30.ttl @@ -0,0 +1,8 @@ +PREFIX rdf: +PREFIX rdfs: +PREFIX xsd: +PREFIX cdt: +PREFIX ex: + +ex:s ex:p1 "{ '1': _:b, '2': 42 }"^^cdt:Map . +ex:s ex:p2 "{ '1': {'3': _:b}, '2': 43 }"^^cdt:Map . diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-31.rq b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-31.rq new file mode 100644 index 00000000..cbbd4379 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-31.rq @@ -0,0 +1,15 @@ +PREFIX cdt: +PREFIX ex: + +ASK { + ex:s ex:p1 ?list1 . + ex:s ex:p2 ?list2 . + + BIND( cdt:get(?list1,1) AS ?e1 ) + BIND( cdt:get(?list2,1) AS ?innerlist ) + BIND( cdt:get(?innerlist,1) AS ?e2 ) + + FILTER( isBLANK(?e1) ) + FILTER( isBLANK(?e2) ) + FILTER( ?e1 != ?e2 ) +} diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-31.ttl b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-31.ttl new file mode 100644 index 00000000..09bb8e49 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-31.ttl @@ -0,0 +1,8 @@ +PREFIX rdf: +PREFIX rdfs: +PREFIX xsd: +PREFIX cdt: +PREFIX ex: + +ex:s ex:p1 "[_:b1, 42]"^^cdt:List . +ex:s ex:p2 "[ [_:b2], 43]"^^cdt:List . diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-32.rq b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-32.rq new file mode 100644 index 00000000..9d5d1b22 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-32.rq @@ -0,0 +1,15 @@ +PREFIX cdt: +PREFIX ex: + +ASK { + ex:s ex:p1 ?map1 . + ex:s ex:p2 ?map2 . + + BIND( cdt:get(?map1,'1') AS ?e1 ) + BIND( cdt:get(?map2,'1') AS ?innermap ) + BIND( cdt:get(?innermap,'3') AS ?e2 ) + + FILTER( isBLANK(?e1) ) + FILTER( isBLANK(?e2) ) + FILTER( ?e1 != ?e2 ) +} diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-32.ttl b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-32.ttl new file mode 100644 index 00000000..dd63fb29 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-32.ttl @@ -0,0 +1,8 @@ +PREFIX rdf: +PREFIX rdfs: +PREFIX xsd: +PREFIX cdt: +PREFIX ex: + +ex:s ex:p1 "{ '1': _:b1, '2': 42 }"^^cdt:Map . +ex:s ex:p2 "{ '1': {'3': _:b2}, '2': 43 }"^^cdt:Map . diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-41.ttl b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-41.ttl new file mode 100644 index 00000000..ae81042e --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-41.ttl @@ -0,0 +1,7 @@ +PREFIX rdf: +PREFIX rdfs: +PREFIX xsd: +PREFIX cdt: +PREFIX ex: + +ex:s ex:p "[_:b, 42, '[_:b]'^^ ]"^^cdt:List . diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-42.ttl b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-42.ttl new file mode 100644 index 00000000..d2976d8b --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-42.ttl @@ -0,0 +1,7 @@ +PREFIX rdf: +PREFIX rdfs: +PREFIX xsd: +PREFIX cdt: +PREFIX ex: + +ex:s ex:p """{ '1': _:b, '2': 42, '3': "{'4': _:b}"^^ }"""^^cdt:Map . diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-43.ttl b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-43.ttl new file mode 100644 index 00000000..3d5bf351 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-43.ttl @@ -0,0 +1,7 @@ +PREFIX rdf: +PREFIX rdfs: +PREFIX xsd: +PREFIX cdt: +PREFIX ex: + +ex:s ex:p "[_:b1, 42, '[_:b2]'^^ ]"^^cdt:List . diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-44.ttl b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-44.ttl new file mode 100644 index 00000000..8e9f25f4 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-44.ttl @@ -0,0 +1,7 @@ +PREFIX rdf: +PREFIX rdfs: +PREFIX xsd: +PREFIX cdt: +PREFIX ex: + +ex:s ex:p """{ '1': _:b1, '2': 42, '3': "{'4': _:b2}"^^ }"""^^cdt:Map . diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-45.ttl b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-45.ttl new file mode 100644 index 00000000..0d5cff1a --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-45.ttl @@ -0,0 +1,7 @@ +PREFIX rdf: +PREFIX rdfs: +PREFIX xsd: +PREFIX cdt: +PREFIX ex: + +_:b ex:p "[ '[_:b]'^^, 42]"^^cdt:List . diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-46.ttl b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-46.ttl new file mode 100644 index 00000000..ec80c1fb --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-46.ttl @@ -0,0 +1,7 @@ +PREFIX rdf: +PREFIX rdfs: +PREFIX xsd: +PREFIX cdt: +PREFIX ex: + +_:b ex:p """{ '1': "{'3': _:b}"^^, '2': 42 }"""^^cdt:Map . diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-47.ttl b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-47.ttl new file mode 100644 index 00000000..02da47e9 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-47.ttl @@ -0,0 +1,7 @@ +PREFIX rdf: +PREFIX rdfs: +PREFIX xsd: +PREFIX cdt: +PREFIX ex: + +_:b1 ex:p "[ '[_:b2]'^^, 42]"^^cdt:List . diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-48.ttl b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-48.ttl new file mode 100644 index 00000000..6d22ca06 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-48.ttl @@ -0,0 +1,7 @@ +PREFIX rdf: +PREFIX rdfs: +PREFIX xsd: +PREFIX cdt: +PREFIX ex: + +_:b1 ex:p """{ '1': "{'3': _:b2}"^^, '2': 42 }"""^^cdt:Map . diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-49.ttl b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-49.ttl new file mode 100644 index 00000000..3923af01 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-49.ttl @@ -0,0 +1,8 @@ +PREFIX rdf: +PREFIX rdfs: +PREFIX xsd: +PREFIX cdt: +PREFIX ex: + +ex:s ex:p1 "[_:b, 42]"^^cdt:List . +ex:s ex:p2 "[ '[_:b]'^^, 43]"^^cdt:List . diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-50.ttl b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-50.ttl new file mode 100644 index 00000000..77364e76 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-50.ttl @@ -0,0 +1,8 @@ +PREFIX rdf: +PREFIX rdfs: +PREFIX xsd: +PREFIX cdt: +PREFIX ex: + +ex:s ex:p1 "{ '1': _:b, '2': 42 }"^^cdt:Map . +ex:s ex:p2 """{ '1': "{'3': _:b}"^^, '2': 43 }"""^^cdt:Map . diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-51.ttl b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-51.ttl new file mode 100644 index 00000000..99d0674c --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-51.ttl @@ -0,0 +1,8 @@ +PREFIX rdf: +PREFIX rdfs: +PREFIX xsd: +PREFIX cdt: +PREFIX ex: + +ex:s ex:p1 "[_:b1, 42]"^^cdt:List . +ex:s ex:p2 "[ '[_:b2]'^^, 43]"^^cdt:List . diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-52.ttl b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-52.ttl new file mode 100644 index 00000000..a19b160e --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-52.ttl @@ -0,0 +1,8 @@ +PREFIX rdf: +PREFIX rdfs: +PREFIX xsd: +PREFIX cdt: +PREFIX ex: + +ex:s ex:p1 "{ '1': _:b1, '2': 42 }"^^cdt:Map . +ex:s ex:p2 """{ '1': "{'3': _:b2}"^^, '2': 43 }"""^^cdt:Map . diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-sparql-01.rq b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-sparql-01.rq new file mode 100644 index 00000000..144f722b --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-sparql-01.rq @@ -0,0 +1,14 @@ +PREFIX cdt: +PREFIX ex: + +ASK { + BIND( "[_:b, 42]"^^cdt:List AS ?list1 ) + ex:s ex:p ?list2 . + + BIND( cdt:get(?list1,1) AS ?e1 ) + BIND( cdt:get(?list2,1) AS ?e2 ) + + FILTER( isBLANK(?e1) ) + FILTER( isBLANK(?e2) ) + FILTER( ?e1 != ?e2 ) +} diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-sparql-01.ttl b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-sparql-01.ttl new file mode 100644 index 00000000..e46c2ca5 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-sparql-01.ttl @@ -0,0 +1,7 @@ +PREFIX rdf: +PREFIX rdfs: +PREFIX xsd: +PREFIX cdt: +PREFIX ex: + +ex:s ex:p "[_:b, 42]"^^cdt:List . diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-sparql-02.rq b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-sparql-02.rq new file mode 100644 index 00000000..cdca76e6 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-sparql-02.rq @@ -0,0 +1,14 @@ +PREFIX cdt: +PREFIX ex: + +ASK { + BIND( "{ '1': _:b, '2': 42 }"^^cdt:Map AS ?map1 ) + ex:s ex:p ?map2 . + + BIND( cdt:get(?map1,'1') AS ?e1 ) + BIND( cdt:get(?map2,'1') AS ?e2 ) + + FILTER( isBLANK(?e1) ) + FILTER( isBLANK(?e2) ) + FILTER( ?e1 != ?e2 ) +} diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-sparql-02.ttl b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-sparql-02.ttl new file mode 100644 index 00000000..badff0fc --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-sparql-02.ttl @@ -0,0 +1,7 @@ +PREFIX rdf: +PREFIX rdfs: +PREFIX xsd: +PREFIX cdt: +PREFIX ex: + +ex:s ex:p "{ '1': _:b, '2': 43 }"^^cdt:Map . diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-sparql-03.rq b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-sparql-03.rq new file mode 100644 index 00000000..0b4097da --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-sparql-03.rq @@ -0,0 +1,13 @@ +PREFIX cdt: +PREFIX ex: + +ASK { + BIND( "[_:b, 42]"^^cdt:List AS ?list ) + ex:s ex:p ?bn . + + BIND( cdt:get(?list,1) AS ?e1 ) + + FILTER( isBLANK(?e1) ) + FILTER( isBLANK(?bn) ) + FILTER( ?e1 != ?bn ) +} diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-sparql-03.ttl b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-sparql-03.ttl new file mode 100644 index 00000000..d4fb3570 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-sparql-03.ttl @@ -0,0 +1,7 @@ +PREFIX rdf: +PREFIX rdfs: +PREFIX xsd: +PREFIX cdt: +PREFIX ex: + +ex:s ex:p _:b . diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-sparql-04.rq b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-sparql-04.rq new file mode 100644 index 00000000..822b971d --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-sparql-04.rq @@ -0,0 +1,13 @@ +PREFIX cdt: +PREFIX ex: + +ASK { + BIND( "{ '1': _:b, '2': 42 }"^^cdt:Map AS ?map ) + ex:s ex:p ?bn . + + BIND( cdt:get(?map,'1') AS ?e1 ) + + FILTER( isBLANK(?e1) ) + FILTER( isBLANK(?bn) ) + FILTER( ?e1 != ?bn ) +} diff --git a/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-sparql-04.ttl b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-sparql-04.ttl new file mode 100644 index 00000000..d4fb3570 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/bnodes-turtle-sparql-04.ttl @@ -0,0 +1,7 @@ +PREFIX rdf: +PREFIX rdfs: +PREFIX xsd: +PREFIX cdt: +PREFIX ex: + +ex:s ex:p _:b . diff --git a/src/test/resources/sparql-cdts/tests/bnodes/empty.ttl b/src/test/resources/sparql-cdts/tests/bnodes/empty.ttl new file mode 100644 index 00000000..e69de29b diff --git a/src/test/resources/sparql-cdts/tests/bnodes/manifest.ttl b/src/test/resources/sparql-cdts/tests/bnodes/manifest.ttl new file mode 100644 index 00000000..a3fd0d7c --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/manifest.ttl @@ -0,0 +1,803 @@ +@prefix rdf: . +@prefix : . +@prefix rdfs: . +@prefix mf: . +@prefix qt: . +@prefix dawgt: . +@prefix sparql: . +@prefix cdt: . + +<> rdf:type mf:Manifest ; + rdfs:label "Handling of blank nodes in CDT literals" ; + mf:entries + ( + :bnodes-turtle-01 + :bnodes-turtle-02 + :bnodes-turtle-03 + :bnodes-turtle-04 + :bnodes-turtle-05 + :bnodes-turtle-06 + :bnodes-turtle-07 + :bnodes-turtle-08 + :bnodes-turtle-09 + :bnodes-turtle-10 + :bnodes-turtle-11 + :bnodes-turtle-12 + :bnodes-turtle-13 + :bnodes-turtle-14 + :bnodes-turtle-15 + :bnodes-turtle-16 + :bnodes-turtle-17 + :bnodes-turtle-18 + :bnodes-turtle-19 + + :bnodes-turtle-21 + :bnodes-turtle-22 + :bnodes-turtle-23 + :bnodes-turtle-24 + :bnodes-turtle-25 + :bnodes-turtle-26 + :bnodes-turtle-27 + :bnodes-turtle-28 + :bnodes-turtle-29 + :bnodes-turtle-30 + :bnodes-turtle-31 + :bnodes-turtle-32 + + :bnodes-turtle-41 + :bnodes-turtle-42 + :bnodes-turtle-43 + :bnodes-turtle-44 + :bnodes-turtle-45 + :bnodes-turtle-46 + :bnodes-turtle-47 + :bnodes-turtle-48 + :bnodes-turtle-49 + :bnodes-turtle-50 + :bnodes-turtle-51 + :bnodes-turtle-52 + + :bnodes-sparql-01 + :bnodes-sparql-02 + :bnodes-sparql-03 + :bnodes-sparql-04 + :bnodes-sparql-05 + :bnodes-sparql-06 + :bnodes-sparql-07 + :bnodes-sparql-08 + :bnodes-sparql-09 + + :bnodes-sparql-11 + :bnodes-sparql-12 + :bnodes-sparql-13 + :bnodes-sparql-14 + :bnodes-sparql-15 + :bnodes-sparql-16 + :bnodes-sparql-17 + :bnodes-sparql-18 + + :bnodes-sparql-21 + :bnodes-sparql-22 + :bnodes-sparql-23 + :bnodes-sparql-24 + :bnodes-sparql-25 + :bnodes-sparql-26 + :bnodes-sparql-27 + :bnodes-sparql-28 + + :bnodes-turtle-sparql-01 + :bnodes-turtle-sparql-02 + :bnodes-turtle-sparql-03 + :bnodes-turtle-sparql-04 + + :bnodes-export-turtle-01 + :bnodes-export-ntriples-01 + :bnodes-export-rdfxml-01 + :bnodes-export-service-01 + ) . + +:bnodes-turtle-01 rdf:type mf:QueryEvaluationTest ; + mf:name "bnodes-turtle-01" ; + rdfs:comment "same blank node identifier twice within a cdt:List literal" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:data ; + qt:query ] ; + mf:result . + +:bnodes-turtle-02 rdf:type mf:QueryEvaluationTest ; + mf:name "bnodes-turtle-02" ; + rdfs:comment "same blank node identifier twice within a cdt:Map literal" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:data ; + qt:query ] ; + mf:result . + +:bnodes-turtle-03 rdf:type mf:QueryEvaluationTest ; + mf:name "bnodes-turtle-03" ; + rdfs:comment "different blank node identifiers within a cdt:List literal" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:data ; + qt:query ] ; + mf:result . + +:bnodes-turtle-04 rdf:type mf:QueryEvaluationTest ; + mf:name "bnodes-turtle-04" ; + rdfs:comment "different blank node identifiers within a cdt:Map literal" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:data ; + qt:query ] ; + mf:result . + +:bnodes-turtle-05 rdf:type mf:QueryEvaluationTest ; + mf:name "bnodes-turtle-05" ; + rdfs:comment "same blank node identifier both within a cdt:List literal and outside of the literal" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:data ; + qt:query ] ; + mf:result . + +:bnodes-turtle-06 rdf:type mf:QueryEvaluationTest ; + mf:name "bnodes-turtle-06" ; + rdfs:comment "same blank node identifier both within a cdt:Map literal and outside of the literal" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:data ; + qt:query ] ; + mf:result . + +:bnodes-turtle-07 rdf:type mf:QueryEvaluationTest ; + mf:name "bnodes-turtle-07" ; + rdfs:comment "different blank node identifiers within a cdt:List literal and outside of the literal" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:data ; + qt:query ] ; + mf:result . + +:bnodes-turtle-08 rdf:type mf:QueryEvaluationTest ; + mf:name "bnodes-turtle-08" ; + rdfs:comment "different blank node identifiers within a cdt:Map literal and outside of the literal" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:data ; + qt:query ] ; + mf:result . + +:bnodes-turtle-09 rdf:type mf:QueryEvaluationTest ; + mf:name "bnodes-turtle-09" ; + rdfs:comment "same blank node identifier within two different cdt:List literals" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:data ; + qt:query ] ; + mf:result . + +:bnodes-turtle-10 rdf:type mf:QueryEvaluationTest ; + mf:name "bnodes-turtle-10" ; + rdfs:comment "same blank node identifier within two different cdt:Map literals" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:data ; + qt:query ] ; + mf:result . + +:bnodes-turtle-11 rdf:type mf:QueryEvaluationTest ; + mf:name "bnodes-turtle-11" ; + rdfs:comment "different blank node identifiers within two different cdt:List literals" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:data ; + qt:query ] ; + mf:result . + +:bnodes-turtle-12 rdf:type mf:QueryEvaluationTest ; + mf:name "bnodes-turtle-12" ; + rdfs:comment "different blank node identifiers within two different cdt:Map literals" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:data ; + qt:query ] ; + mf:result . + +:bnodes-turtle-13 rdf:type mf:QueryEvaluationTest ; + mf:name "bnodes-turtle-13" ; + rdfs:comment "same blank node identifier both within a cdt:List literal and a cdt:Map literal" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:data ; + qt:query ] ; + mf:result . + +:bnodes-turtle-14 rdf:type mf:QueryEvaluationTest ; + mf:name "bnodes-turtle-14" ; + rdfs:comment "different blank node identifiers within a cdt:List literal and a cdt:Map literal" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:data ; + qt:query ] ; + mf:result . + +:bnodes-turtle-15 rdf:type mf:QueryEvaluationTest ; + mf:name "bnodes-turtle-15" ; + rdfs:comment "same blank node identifier within cdt:List literals in two different files" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:data , + ; + qt:query ] ; + mf:result . + +:bnodes-turtle-16 rdf:type mf:QueryEvaluationTest ; + mf:name "bnodes-turtle-16" ; + rdfs:comment "same blank node identifier within cdt:Map literals in two different files" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:data , + ; + qt:query ] ; + mf:result . + +:bnodes-turtle-17 rdf:type mf:QueryEvaluationTest ; + mf:name "bnodes-turtle-17" ; + rdfs:comment "same blank node identifier within a cdt:List literal in one file and outside of literals in another file" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:data , + ; + qt:query ] ; + mf:result . + +:bnodes-turtle-18 rdf:type mf:QueryEvaluationTest ; + mf:name "bnodes-turtle-18" ; + rdfs:comment "same blank node identifier within a cdt:Map literal in one file and outside of literals in another file" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:data , + ; + qt:query ] ; + mf:result . + +:bnodes-turtle-19 rdf:type mf:QueryEvaluationTest ; + mf:name "bnodes-turtle-19" ; + rdfs:comment "same blank node identifier within a cdt:List literal in one file and within a cdt:Map literal in another file" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:data , + ; + qt:query ] ; + mf:result . + +:bnodes-turtle-21 rdf:type mf:QueryEvaluationTest ; + mf:name "bnodes-turtle-21" ; + rdfs:comment "same blank node identifier twice within a *nested* cdt:List literal" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:data ; + qt:query ] ; + mf:result . + +:bnodes-turtle-22 rdf:type mf:QueryEvaluationTest ; + mf:name "bnodes-turtle-22" ; + rdfs:comment "same blank node identifier twice within a *nested* cdt:Map literal" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:data ; + qt:query ] ; + mf:result . + +:bnodes-turtle-23 rdf:type mf:QueryEvaluationTest ; + mf:name "bnodes-turtle-23" ; + rdfs:comment "different blank node identifiers within a *nested* cdt:List literal" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:data ; + qt:query ] ; + mf:result . + +:bnodes-turtle-24 rdf:type mf:QueryEvaluationTest ; + mf:name "bnodes-turtle-24" ; + rdfs:comment "different blank node identifiers within a *nested* cdt:Map literal" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:data ; + qt:query ] ; + mf:result . + +:bnodes-turtle-25 rdf:type mf:QueryEvaluationTest ; + mf:name "bnodes-turtle-25" ; + rdfs:comment "same blank node identifier both within a *nested* cdt:List literal and outside of the literal" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:data ; + qt:query ] ; + mf:result . + +:bnodes-turtle-26 rdf:type mf:QueryEvaluationTest ; + mf:name "bnodes-turtle-26" ; + rdfs:comment "same blank node identifier both within a *nested* cdt:Map literal and outside of the literal" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:data ; + qt:query ] ; + mf:result . + +:bnodes-turtle-27 rdf:type mf:QueryEvaluationTest ; + mf:name "bnodes-turtle-27" ; + rdfs:comment "different blank node identifiers within a *nested* cdt:List literal and outside of the literal" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:data ; + qt:query ] ; + mf:result . + +:bnodes-turtle-28 rdf:type mf:QueryEvaluationTest ; + mf:name "bnodes-turtle-28" ; + rdfs:comment "different blank node identifiers within a *nested* cdt:Map literal and outside of the literal" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:data ; + qt:query ] ; + mf:result . + +:bnodes-turtle-29 rdf:type mf:QueryEvaluationTest ; + mf:name "bnodes-turtle-29" ; + rdfs:comment "same blank node identifier within two different cdt:List literals, where one of them is nested" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:data ; + qt:query ] ; + mf:result . + +:bnodes-turtle-30 rdf:type mf:QueryEvaluationTest ; + mf:name "bnodes-turtle-30" ; + rdfs:comment "same blank node identifier within two different cdt:Map literals, where one of them is nested" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:data ; + qt:query ] ; + mf:result . + +:bnodes-turtle-31 rdf:type mf:QueryEvaluationTest ; + mf:name "bnodes-turtle-31" ; + rdfs:comment "different blank node identifiers within two different cdt:List literals, where one of them is nested" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:data ; + qt:query ] ; + mf:result . + +:bnodes-turtle-32 rdf:type mf:QueryEvaluationTest ; + mf:name "bnodes-turtle-32" ; + rdfs:comment "different blank node identifiers within two different cdt:Map literals, where one of them is nested" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:data ; + qt:query ] ; + mf:result . + +:bnodes-turtle-41 rdf:type mf:QueryEvaluationTest ; + mf:name "bnodes-turtle-41" ; + rdfs:comment "same blank node identifier twice within a *nested* cdt:List literal" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:data ; + qt:query ] ; + mf:result . + +:bnodes-turtle-42 rdf:type mf:QueryEvaluationTest ; + mf:name "bnodes-turtle-42" ; + rdfs:comment "same blank node identifier twice within a *nested* cdt:Map literal" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:data ; + qt:query ] ; + mf:result . + +:bnodes-turtle-43 rdf:type mf:QueryEvaluationTest ; + mf:name "bnodes-turtle-43" ; + rdfs:comment "different blank node identifiers within a *nested* cdt:List literal" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:data ; + qt:query ] ; + mf:result . + +:bnodes-turtle-44 rdf:type mf:QueryEvaluationTest ; + mf:name "bnodes-turtle-44" ; + rdfs:comment "different blank node identifiers within a *nested* cdt:Map literal" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:data ; + qt:query ] ; + mf:result . + +:bnodes-turtle-45 rdf:type mf:QueryEvaluationTest ; + mf:name "bnodes-turtle-45" ; + rdfs:comment "same blank node identifier both within a *nested* cdt:List literal and outside of the literal" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:data ; + qt:query ] ; + mf:result . + +:bnodes-turtle-46 rdf:type mf:QueryEvaluationTest ; + mf:name "bnodes-turtle-46" ; + rdfs:comment "same blank node identifier both within a *nested* cdt:Map literal and outside of the literal" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:data ; + qt:query ] ; + mf:result . + +:bnodes-turtle-47 rdf:type mf:QueryEvaluationTest ; + mf:name "bnodes-turtle-47" ; + rdfs:comment "different blank node identifiers within a *nested* cdt:List literal and outside of the literal" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:data ; + qt:query ] ; + mf:result . + +:bnodes-turtle-48 rdf:type mf:QueryEvaluationTest ; + mf:name "bnodes-turtle-48" ; + rdfs:comment "different blank node identifiers within a *nested* cdt:Map literal and outside of the literal" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:data ; + qt:query ] ; + mf:result . + +:bnodes-turtle-49 rdf:type mf:QueryEvaluationTest ; + mf:name "bnodes-turtle-49" ; + rdfs:comment "same blank node identifier within two different cdt:List literals, where one of them is nested" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:data ; + qt:query ] ; + mf:result . + +:bnodes-turtle-50 rdf:type mf:QueryEvaluationTest ; + mf:name "bnodes-turtle-50" ; + rdfs:comment "same blank node identifier within two different cdt:Map literals, where one of them is nested" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:data ; + qt:query ] ; + mf:result . + +:bnodes-turtle-51 rdf:type mf:QueryEvaluationTest ; + mf:name "bnodes-turtle-51" ; + rdfs:comment "different blank node identifiers within two different cdt:List literals, where one of them is nested" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:data ; + qt:query ] ; + mf:result . + +:bnodes-turtle-52 rdf:type mf:QueryEvaluationTest ; + mf:name "bnodes-turtle-52" ; + rdfs:comment "different blank node identifiers within two different cdt:Map literals, where one of them is nested" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:data ; + qt:query ] ; + mf:result . + + + +:bnodes-sparql-01 rdf:type mf:QueryEvaluationTest ; + mf:name "bnodes-sparql-01" ; + rdfs:comment "same blank node identifier twice within a cdt:List literal" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:data ; + qt:query ] ; + mf:result . + +:bnodes-sparql-02 rdf:type mf:QueryEvaluationTest ; + mf:name "bnodes-sparql-02" ; + rdfs:comment "same blank node identifier twice within a cdt:Map literal" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:data ; + qt:query ] ; + mf:result . + +:bnodes-sparql-03 rdf:type mf:QueryEvaluationTest ; + mf:name "bnodes-sparql-03" ; + rdfs:comment "two different blank node identifiers within a cdt:List literal" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:data ; + qt:query ] ; + mf:result . + +:bnodes-sparql-04 rdf:type mf:QueryEvaluationTest ; + mf:name "bnodes-sparql-04" ; + rdfs:comment "two different blank node identifiers within a cdt:Map literal" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:data ; + qt:query ] ; + mf:result . + +:bnodes-sparql-05 rdf:type mf:QueryEvaluationTest ; + mf:name "bnodes-sparql-05" ; + rdfs:comment "same blank node identifier within two different cdt:List literals" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:data ; + qt:query ] ; + mf:result . + +:bnodes-sparql-06 rdf:type mf:QueryEvaluationTest ; + mf:name "bnodes-sparql-06" ; + rdfs:comment "same blank node identifier within two different cdt:Map literals" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:data ; + qt:query ] ; + mf:result . + +:bnodes-sparql-07 rdf:type mf:QueryEvaluationTest ; + mf:name "bnodes-sparql-07" ; + rdfs:comment "different blank node identifiers within two different cdt:List literals" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:data ; + qt:query ] ; + mf:result . + +:bnodes-sparql-08 rdf:type mf:QueryEvaluationTest ; + mf:name "bnodes-sparql-08" ; + rdfs:comment "different blank node identifiers within two different cdt:Map literals" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:data ; + qt:query ] ; + mf:result . + +:bnodes-sparql-09 rdf:type mf:QueryEvaluationTest ; + mf:name "bnodes-sparql-09" ; + rdfs:comment "same blank node identifier, once within a cdt:List literal and once within a cdt:Map literal" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:data ; + qt:query ] ; + mf:result . + +:bnodes-sparql-11 rdf:type mf:QueryEvaluationTest ; + mf:name "bnodes-sparql-11" ; + rdfs:comment "same blank node identifier twice within a *nested* cdt:List literal" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:data ; + qt:query ] ; + mf:result . + +:bnodes-sparql-12 rdf:type mf:QueryEvaluationTest ; + mf:name "bnodes-sparql-12" ; + rdfs:comment "same blank node identifier twice within a *nested* cdt:Map literal" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:data ; + qt:query ] ; + mf:result . + +:bnodes-sparql-13 rdf:type mf:QueryEvaluationTest ; + mf:name "bnodes-sparql-13" ; + rdfs:comment "two different blank node identifiers within a *nested* cdt:List literal" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:data ; + qt:query ] ; + mf:result . + +:bnodes-sparql-14 rdf:type mf:QueryEvaluationTest ; + mf:name "bnodes-sparql-14" ; + rdfs:comment "two different blank node identifiers within a *nested* cdt:Map literal" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:data ; + qt:query ] ; + mf:result . + +:bnodes-sparql-15 rdf:type mf:QueryEvaluationTest ; + mf:name "bnodes-sparql-15" ; + rdfs:comment "same blank node identifier within two different cdt:List literals, where one of them is a nested one" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:data ; + qt:query ] ; + mf:result . + +:bnodes-sparql-16 rdf:type mf:QueryEvaluationTest ; + mf:name "bnodes-sparql-16" ; + rdfs:comment "same blank node identifier within two different cdt:Map literals, where one of them is a nested one" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:data ; + qt:query ] ; + mf:result . + +:bnodes-sparql-17 rdf:type mf:QueryEvaluationTest ; + mf:name "bnodes-sparql-17" ; + rdfs:comment "different blank node identifiers within two different cdt:List literals, where one of them is a nested one" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:data ; + qt:query ] ; + mf:result . + +:bnodes-sparql-18 rdf:type mf:QueryEvaluationTest ; + mf:name "bnodes-sparql-18" ; + rdfs:comment "different blank node identifiers within two different cdt:Map literals, where one of them is a nested one" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:data ; + qt:query ] ; + mf:result . + +:bnodes-sparql-21 rdf:type mf:QueryEvaluationTest ; + mf:name "bnodes-sparql-21" ; + rdfs:comment "same blank node identifier twice within a *nested* cdt:List literal" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:data ; + qt:query ] ; + mf:result . + +:bnodes-sparql-22 rdf:type mf:QueryEvaluationTest ; + mf:name "bnodes-sparql-22" ; + rdfs:comment "same blank node identifier twice within a *nested* cdt:Map literal" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:data ; + qt:query ] ; + mf:result . + +:bnodes-sparql-23 rdf:type mf:QueryEvaluationTest ; + mf:name "bnodes-sparql-23" ; + rdfs:comment "two different blank node identifiers within a *nested* cdt:List literal" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:data ; + qt:query ] ; + mf:result . + +:bnodes-sparql-24 rdf:type mf:QueryEvaluationTest ; + mf:name "bnodes-sparql-24" ; + rdfs:comment "two different blank node identifiers within a *nested* cdt:Map literal" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:data ; + qt:query ] ; + mf:result . + +:bnodes-sparql-25 rdf:type mf:QueryEvaluationTest ; + mf:name "bnodes-sparql-25" ; + rdfs:comment "same blank node identifier within two different cdt:List literals, where one of them is a nested one" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:data ; + qt:query ] ; + mf:result . + +:bnodes-sparql-26 rdf:type mf:QueryEvaluationTest ; + mf:name "bnodes-sparql-26" ; + rdfs:comment "same blank node identifier within two different cdt:Map literals, where one of them is a nested one" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:data ; + qt:query ] ; + mf:result . + +:bnodes-sparql-27 rdf:type mf:QueryEvaluationTest ; + mf:name "bnodes-sparql-27" ; + rdfs:comment "different blank node identifiers within two different cdt:List literals, where one of them is a nested one" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:data ; + qt:query ] ; + mf:result . + +:bnodes-sparql-28 rdf:type mf:QueryEvaluationTest ; + mf:name "bnodes-sparql-28" ; + rdfs:comment "different blank node identifiers within two different cdt:Map literals, where one of them is a nested one" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:data ; + qt:query ] ; + mf:result . + + + +:bnodes-turtle-sparql-01 rdf:type mf:QueryEvaluationTest ; + mf:name "bnodes-turtle-sparql-01" ; + rdfs:comment "same blank node identifier both within a cdt:List literal in a Turtle file and within a cdt:List literal in the SPARQL query" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:data ; + qt:query ] ; + mf:result . + +:bnodes-turtle-sparql-02 rdf:type mf:QueryEvaluationTest ; + mf:name "bnodes-turtle-sparql-02" ; + rdfs:comment "same blank node identifier both within a cdt:Map literal in a Turtle file and within a cdt:Map literal in the SPARQL query" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:data ; + qt:query ] ; + mf:result . + +:bnodes-turtle-sparql-03 rdf:type mf:QueryEvaluationTest ; + mf:name "bnodes-turtle-sparql-03" ; + rdfs:comment "same blank node identifier both within a cdt:List literal in the SPARQL query and outside of literals in a Turtle file" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:data ; + qt:query ] ; + mf:result . + +:bnodes-turtle-sparql-04 rdf:type mf:QueryEvaluationTest ; + mf:name "bnodes-turtle-sparql-04" ; + rdfs:comment "same blank node identifier both within a cdt:Map literal in the SPARQL query and outside of literals in a Turtle file" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:data ; + qt:query ] ; + mf:result . + + +:bnodes-export-service-01 rdf:type mf:QueryEvaluationTest ; + mf:name "bnodes-export-service-01" ; + rdfs:comment "bnodes appearing both inside and outside of a CDT literal in SPARQL results need to be serialized with the same identifier so they reference the same value" ; + dawgt:approval dawgt:Proposed ; + mf:action [ + qt:serviceData [ + qt:endpoint ; + qt:data + ] ; + qt:query ] ; + mf:result . + +:bnodes-export-turtle-01 rdf:type mf:QueryEvaluationTest ; + mf:name "bnodes-export-turtle-01" ; + rdfs:comment "bnodes appearing both inside and outside of a CDT literal in SPARQL results need to be serialized with the same identifier so they reference the same value" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:constructDataFile [ + qt:query ; + qt:format "text/turtle" + ] ; + qt:query ] ; + mf:result . + +:bnodes-export-ntriples-01 rdf:type mf:QueryEvaluationTest ; + mf:name "bnodes-export-ntriples-01" ; + rdfs:comment "bnodes appearing both inside and outside of a CDT literal in SPARQL results need to be serialized with the same identifier so they reference the same value" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:constructDataFile [ + qt:query ; + qt:format "application/n-triples" + ] ; + qt:query ] ; + mf:result . + +:bnodes-export-rdfxml-01 rdf:type mf:QueryEvaluationTest ; + mf:name "bnodes-export-rdfxml-01" ; + rdfs:comment "bnodes appearing both inside and outside of a CDT literal in SPARQL results need to be serialized with the same identifier so they reference the same value" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:constructDataFile [ + qt:query ; + qt:format "application/rdf+xml" + ] ; + qt:query ] ; + mf:result . diff --git a/src/test/resources/sparql-cdts/tests/bnodes/true.srx b/src/test/resources/sparql-cdts/tests/bnodes/true.srx new file mode 100644 index 00000000..c187f066 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/bnodes/true.srx @@ -0,0 +1,5 @@ + + + + true + diff --git a/src/test/resources/sparql-cdts/tests/fold/empty.ttl b/src/test/resources/sparql-cdts/tests/fold/empty.ttl new file mode 100644 index 00000000..e69de29b diff --git a/src/test/resources/sparql-cdts/tests/fold/fold-list-01.rq b/src/test/resources/sparql-cdts/tests/fold/fold-list-01.rq new file mode 100644 index 00000000..d6fdf304 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/fold/fold-list-01.rq @@ -0,0 +1,11 @@ +PREFIX cdt: + +ASK { + { + SELECT (FOLD(?v) AS ?list) + WHERE { + VALUES ?v { 1 } + } + } + FILTER(?list = "[1]"^^cdt:List) +} diff --git a/src/test/resources/sparql-cdts/tests/fold/fold-list-02.rq b/src/test/resources/sparql-cdts/tests/fold/fold-list-02.rq new file mode 100644 index 00000000..9ed294fa --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/fold/fold-list-02.rq @@ -0,0 +1,11 @@ +PREFIX cdt: + +ASK { + { + SELECT (FOLD(?v) AS ?list) + WHERE { + FILTER(false) + } + } + FILTER(?list = "[]"^^cdt:List) +} diff --git a/src/test/resources/sparql-cdts/tests/fold/fold-list-03.rq b/src/test/resources/sparql-cdts/tests/fold/fold-list-03.rq new file mode 100644 index 00000000..019f5bf5 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/fold/fold-list-03.rq @@ -0,0 +1,15 @@ +PREFIX cdt: + +ASK { + { + SELECT (FOLD(?v) AS ?list) + WHERE { + VALUES ?v { 1 2 } + } + } + FILTER( + (cdt:get(?list, 1) = 1 && cdt:get(?list, 2) = 2) + || + (cdt:get(?list, 1) = 2 && cdt:get(?list, 2) = 1) + ) +} diff --git a/src/test/resources/sparql-cdts/tests/fold/fold-list-04.rq b/src/test/resources/sparql-cdts/tests/fold/fold-list-04.rq new file mode 100644 index 00000000..86fb69e3 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/fold/fold-list-04.rq @@ -0,0 +1,21 @@ +PREFIX cdt: + +ASK { + { + SELECT (FOLD(?v) AS ?list) + WHERE { + VALUES ?v { 1 UNDEF } + } + } + + FILTER( cdt:size(?list) = 2 ) + + BIND( cdt:get(?list, 1) AS ?e1 ) + BIND( cdt:get(?list, 2) AS ?e2 ) + + FILTER( + ( ?e1 = 1 && ! BOUND(?e2) ) + || + ( ?e2 = 1 && ! BOUND(?e1) ) + ) +} diff --git a/src/test/resources/sparql-cdts/tests/fold/fold-list-05.rq b/src/test/resources/sparql-cdts/tests/fold/fold-list-05.rq new file mode 100644 index 00000000..d1ce9e51 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/fold/fold-list-05.rq @@ -0,0 +1,24 @@ +PREFIX cdt: + +ASK { + { + SELECT (FOLD(?v) AS ?list) + WHERE { + VALUES ?v { 1 UNDEF UNDEF } + } + } + + FILTER( cdt:size(?list) = 3 ) + + BIND( cdt:get(?list, 1) AS ?e1 ) + BIND( cdt:get(?list, 2) AS ?e2 ) + BIND( cdt:get(?list, 3) AS ?e3 ) + + FILTER( + ( ?e1 = 1 && ! BOUND(?e2) && ! BOUND(?e3) ) + || + ( ?e2 = 1 && ! BOUND(?e1) && ! BOUND(?e3) ) + || + ( ?e3 = 1 && ! BOUND(?e1) && ! BOUND(?e2) ) + ) +} diff --git a/src/test/resources/sparql-cdts/tests/fold/fold-list-distinct-01.rq b/src/test/resources/sparql-cdts/tests/fold/fold-list-distinct-01.rq new file mode 100644 index 00000000..1378cc1c --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/fold/fold-list-distinct-01.rq @@ -0,0 +1,11 @@ +PREFIX cdt: + +ASK { + { + SELECT (FOLD(DISTINCT ?v) AS ?list) + WHERE { + VALUES ?v { 1 1 } + } + } + FILTER(?list = "[1]"^^cdt:List) +} diff --git a/src/test/resources/sparql-cdts/tests/fold/fold-list-distinct-02.rq b/src/test/resources/sparql-cdts/tests/fold/fold-list-distinct-02.rq new file mode 100644 index 00000000..6f6c04db --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/fold/fold-list-distinct-02.rq @@ -0,0 +1,18 @@ +PREFIX cdt: + +ASK { + { + SELECT (FOLD(DISTINCT ?v) AS ?list) + WHERE { + VALUES ?v { 1 2 1 } + } + } + + FILTER( cdt:size(?list) = 2 ) + + FILTER( + (cdt:get(?list, 1) = 1 && cdt:get(?list, 2) = 2) + || + (cdt:get(?list, 1) = 2 && cdt:get(?list, 2) = 1) + ) +} diff --git a/src/test/resources/sparql-cdts/tests/fold/fold-list-distinct-03.rq b/src/test/resources/sparql-cdts/tests/fold/fold-list-distinct-03.rq new file mode 100644 index 00000000..94a338a0 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/fold/fold-list-distinct-03.rq @@ -0,0 +1,18 @@ +PREFIX cdt: + +ASK { + { + SELECT (FOLD(DISTINCT ?v) AS ?list) + WHERE { + VALUES ?v { 1 1 2 } + } + } + + FILTER( cdt:size(?list) = 2 ) + + FILTER( + (cdt:get(?list, 1) = 1 && cdt:get(?list, 2) = 2) + || + (cdt:get(?list, 1) = 2 && cdt:get(?list, 2) = 1) + ) +} diff --git a/src/test/resources/sparql-cdts/tests/fold/fold-list-distinct-04.rq b/src/test/resources/sparql-cdts/tests/fold/fold-list-distinct-04.rq new file mode 100644 index 00000000..2673de51 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/fold/fold-list-distinct-04.rq @@ -0,0 +1,21 @@ +PREFIX cdt: + +ASK { + { + SELECT (FOLD(DISTINCT ?v) AS ?list) + WHERE { + VALUES ?v { 1 1 UNDEF } + } + } + + FILTER( cdt:size(?list) = 2 ) + + BIND( cdt:get(?list, 1) AS ?e1 ) + BIND( cdt:get(?list, 2) AS ?e2 ) + + FILTER( + ( ?e1 = 1 && ! BOUND(?e2) ) + || + ( ?e2 = 1 && ! BOUND(?e1) ) + ) +} diff --git a/src/test/resources/sparql-cdts/tests/fold/fold-list-distinct-05.rq b/src/test/resources/sparql-cdts/tests/fold/fold-list-distinct-05.rq new file mode 100644 index 00000000..1dbe33ac --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/fold/fold-list-distinct-05.rq @@ -0,0 +1,21 @@ +PREFIX cdt: + +ASK { + { + SELECT (FOLD(DISTINCT ?v) AS ?list) + WHERE { + VALUES ?v { 1 UNDEF UNDEF } + } + } + + FILTER( cdt:size(?list) = 2 ) + + BIND( cdt:get(?list, 1) AS ?e1 ) + BIND( cdt:get(?list, 2) AS ?e2 ) + + FILTER( + ( ?e1 = 1 && ! BOUND(?e2) ) + || + ( ?e2 = 1 && ! BOUND(?e1) ) + ) +} diff --git a/src/test/resources/sparql-cdts/tests/fold/fold-list-distinct-06.rq b/src/test/resources/sparql-cdts/tests/fold/fold-list-distinct-06.rq new file mode 100644 index 00000000..e9ec655b --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/fold/fold-list-distinct-06.rq @@ -0,0 +1,21 @@ +PREFIX cdt: + +ASK { + { + SELECT (FOLD(DISTINCT ?v) AS ?list) + WHERE { + VALUES ?v { 1 UNDEF UNDEF 1 } + } + } + + FILTER( cdt:size(?list) = 2 ) + + BIND( cdt:get(?list, 1) AS ?e1 ) + BIND( cdt:get(?list, 2) AS ?e2 ) + + FILTER( + ( ?e1 = 1 && ! BOUND(?e2) ) + || + ( ?e2 = 1 && ! BOUND(?e1) ) + ) +} diff --git a/src/test/resources/sparql-cdts/tests/fold/fold-list-distinct-07.rq b/src/test/resources/sparql-cdts/tests/fold/fold-list-distinct-07.rq new file mode 100644 index 00000000..8bdd1aa9 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/fold/fold-list-distinct-07.rq @@ -0,0 +1,22 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + { + SELECT (FOLD(DISTINCT ?v) AS ?list) + WHERE { + VALUES ?v { "1"^^xsd:integer "01"^^xsd:integer } + } + } + + FILTER( cdt:size(?list) = 2 ) + + BIND( cdt:get(?list, 1) AS ?e1 ) + BIND( cdt:get(?list, 2) AS ?e2 ) + + FILTER( + ( SAMETERM(?e1,"1"^^xsd:integer) && SAMETERM(?e2,"01"^^xsd:integer) ) + || + ( SAMETERM(?e2,"1"^^xsd:integer) && SAMETERM(?e1,"01"^^xsd:integer) ) + ) +} diff --git a/src/test/resources/sparql-cdts/tests/fold/fold-list-distinct-08.rq b/src/test/resources/sparql-cdts/tests/fold/fold-list-distinct-08.rq new file mode 100644 index 00000000..3431aaaf --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/fold/fold-list-distinct-08.rq @@ -0,0 +1,22 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + { + SELECT (FOLD(DISTINCT ?v) AS ?list) + WHERE { + VALUES ?v { "1"^^xsd:integer "01"^^xsd:integer "1"^^xsd:integer "01"^^xsd:integer } + } + } + + FILTER( cdt:size(?list) = 2 ) + + BIND( cdt:get(?list, 1) AS ?e1 ) + BIND( cdt:get(?list, 2) AS ?e2 ) + + FILTER( + ( SAMETERM(?e1,"1"^^xsd:integer) && SAMETERM(?e2,"01"^^xsd:integer) ) + || + ( SAMETERM(?e2,"1"^^xsd:integer) && SAMETERM(?e1,"01"^^xsd:integer) ) + ) +} diff --git a/src/test/resources/sparql-cdts/tests/fold/fold-list-distinct-orderby-01.rq b/src/test/resources/sparql-cdts/tests/fold/fold-list-distinct-orderby-01.rq new file mode 100644 index 00000000..3952a58a --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/fold/fold-list-distinct-orderby-01.rq @@ -0,0 +1,31 @@ +PREFIX cdt: + +ASK { + { + SELECT (FOLD(DISTINCT ?v ORDER BY ASC(?sort)) AS ?list) + WHERE { + VALUES (?sort ?v) { + (1 1) + (3 3) + (2 2) + (2 2) + (3 4) + } + } + } + + FILTER( cdt:size(?list) = 4 ) + + BIND( cdt:get(?list, 1) AS ?e1 ) + BIND( cdt:get(?list, 2) AS ?e2 ) + BIND( cdt:get(?list, 3) AS ?e3 ) + BIND( cdt:get(?list, 4) AS ?e4 ) + + FILTER( ?e1 = 1 ) + FILTER( ?e2 = 2 ) + FILTER( + ( (?e3=3) && (?e4=4) ) + || + ( (?e3=4) && (?e4=3) ) + ) +} diff --git a/src/test/resources/sparql-cdts/tests/fold/fold-list-distinct-orderby-02.rq b/src/test/resources/sparql-cdts/tests/fold/fold-list-distinct-orderby-02.rq new file mode 100644 index 00000000..71423fd3 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/fold/fold-list-distinct-orderby-02.rq @@ -0,0 +1,22 @@ +PREFIX cdt: + +ASK { + { + SELECT (FOLD(DISTINCT ?v ORDER BY ASC(?sort)) AS ?list) + WHERE { + VALUES (?sort ?v ?other) { + (1 1 "same") + (1 1 "same") + + (3 3 "same") + (3 3 "same") + (3 3 "different") + + (2 2 "different a") + (2 2 "different b") + } + } + } + + FILTER(?list = "[1,2,3]"^^cdt:List) +} diff --git a/src/test/resources/sparql-cdts/tests/fold/fold-list-distinct-orderby-03.rq b/src/test/resources/sparql-cdts/tests/fold/fold-list-distinct-orderby-03.rq new file mode 100644 index 00000000..669d31eb --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/fold/fold-list-distinct-orderby-03.rq @@ -0,0 +1,40 @@ +PREFIX cdt: + +ASK { + { + SELECT (FOLD(DISTINCT ?v ORDER BY ASC(?sort)) AS ?list) + WHERE { + VALUES (?sort ?v) { + (2 UNDEF) + (1 3) + (UNDEF "same") # duplicate 1 + (3 5) + (UNDEF "same") # duplicate 1 + (4 6) # duplicate 2 + (UNDEF "different") + (4 6) # duplicate 2 + } + } + } + + FILTER( cdt:size(?list) = 6 ) + + BIND( cdt:get(?list, 1) AS ?e1 ) + BIND( cdt:get(?list, 2) AS ?e2 ) + BIND( cdt:get(?list, 3) AS ?e3 ) + BIND( cdt:get(?list, 4) AS ?e4 ) + BIND( cdt:get(?list, 5) AS ?e5 ) + BIND( cdt:get(?list, 6) AS ?e6 ) + + FILTER( + ( (?e1="same") && (?e2="different") ) + || + ( (?e2="same") && (?e1="different") ) + ) + + FILTER( ?e3 = 3 ) + FILTER( ! BOUND(?e4) ) + FILTER( ?e5 = 5 ) + FILTER( ?e6 = 6 ) + +} diff --git a/src/test/resources/sparql-cdts/tests/fold/fold-list-orderby-01.rq b/src/test/resources/sparql-cdts/tests/fold/fold-list-orderby-01.rq new file mode 100644 index 00000000..ac68545f --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/fold/fold-list-orderby-01.rq @@ -0,0 +1,11 @@ +PREFIX cdt: + +ASK { + { + SELECT (FOLD(?v ORDER BY ?v) AS ?list) + WHERE { + VALUES ?v { 1 2 3 6 5 4 } + } + } + FILTER(?list = "[1,2,3,4,5,6]"^^cdt:List) +} diff --git a/src/test/resources/sparql-cdts/tests/fold/fold-list-orderby-02.rq b/src/test/resources/sparql-cdts/tests/fold/fold-list-orderby-02.rq new file mode 100644 index 00000000..244ccff8 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/fold/fold-list-orderby-02.rq @@ -0,0 +1,11 @@ +PREFIX cdt: + +ASK { + { + SELECT (FOLD(?v ORDER BY ?sort) AS ?list) + WHERE { + VALUES (?sort ?v) { (1 1) (3 2) (2 3) } + } + } + FILTER(?list = "[1,3,2]"^^cdt:List) +} diff --git a/src/test/resources/sparql-cdts/tests/fold/fold-list-orderby-03.rq b/src/test/resources/sparql-cdts/tests/fold/fold-list-orderby-03.rq new file mode 100644 index 00000000..f29540e0 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/fold/fold-list-orderby-03.rq @@ -0,0 +1,15 @@ +PREFIX cdt: + +ASK { + { + SELECT (FOLD(?v ORDER BY DESC(?sort)) AS ?list) + WHERE { + VALUES (?sort ?v) { + (1 "one") + (2 "two") + (3 "three") + } + } + } + FILTER(?list = "['three','two','one']"^^cdt:List) +} diff --git a/src/test/resources/sparql-cdts/tests/fold/fold-list-orderby-04.rq b/src/test/resources/sparql-cdts/tests/fold/fold-list-orderby-04.rq new file mode 100644 index 00000000..6b8dd588 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/fold/fold-list-orderby-04.rq @@ -0,0 +1,18 @@ +PREFIX cdt: + +ASK { + { + SELECT (FOLD(?v ORDER BY ASC(?sort)) AS ?list) + WHERE { + VALUES (?sort ?v) { + (1 1) + (3 3) + (2 UNDEF) + } + } + } + FILTER(cdt:get(?list, 1) = 1) + FILTER(cdt:get(?list, 3) = 3) + BIND(cdt:get(?list, 2) AS ?null) + FILTER(!BOUND(?null)) +} diff --git a/src/test/resources/sparql-cdts/tests/fold/fold-list-orderby-05.rq b/src/test/resources/sparql-cdts/tests/fold/fold-list-orderby-05.rq new file mode 100644 index 00000000..552da7f4 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/fold/fold-list-orderby-05.rq @@ -0,0 +1,15 @@ +PREFIX cdt: + +ASK { + { + SELECT (FOLD(?v ORDER BY ASC(?sort)) AS ?list) + WHERE { + VALUES (?sort ?v) { + ( 3) + ("literal" 4) + (UNDEF 1) + } + } + } + FILTER(?list = "[1,3,4]"^^cdt:List) +} diff --git a/src/test/resources/sparql-cdts/tests/fold/fold-list-orderby-06.rq b/src/test/resources/sparql-cdts/tests/fold/fold-list-orderby-06.rq new file mode 100644 index 00000000..fece8625 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/fold/fold-list-orderby-06.rq @@ -0,0 +1,16 @@ +PREFIX cdt: + +ASK { + { + SELECT (FOLD(?v ORDER BY ASC(?sort1) ASC(?sort2)) AS ?list) + WHERE { + VALUES (?sort1 ?sort2 ?v) { + (2 2 "three") + (2 3 "four") + (2 1 "two") + (1 UNDEF "one") + } + } + } + FILTER(?list = "['one','two','three','four']"^^cdt:List) +} diff --git a/src/test/resources/sparql-cdts/tests/fold/fold-map-01.rq b/src/test/resources/sparql-cdts/tests/fold/fold-map-01.rq new file mode 100644 index 00000000..04235a0d --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/fold/fold-map-01.rq @@ -0,0 +1,11 @@ +PREFIX cdt: + +ASK { + { + SELECT (FOLD(?k, ?v) AS ?map) + WHERE { + FILTER(false) + } + } + FILTER(?map = "{}"^^cdt:Map) +} diff --git a/src/test/resources/sparql-cdts/tests/fold/fold-map-02.rq b/src/test/resources/sparql-cdts/tests/fold/fold-map-02.rq new file mode 100644 index 00000000..ff88b4d8 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/fold/fold-map-02.rq @@ -0,0 +1,15 @@ +PREFIX cdt: + +ASK { + { + SELECT (FOLD(?k, ?v) AS ?map) + WHERE { + VALUES (?k ?v) { + (2 "two") + (1 "one") + ("hello"@en "there"@en) + } + } + } + FILTER(?map = "{\"hello\"@en:'there'@en,1:'one',2:'two'}"^^cdt:Map) +} diff --git a/src/test/resources/sparql-cdts/tests/fold/fold-map-03.rq b/src/test/resources/sparql-cdts/tests/fold/fold-map-03.rq new file mode 100644 index 00000000..6ff6d91b --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/fold/fold-map-03.rq @@ -0,0 +1,19 @@ +PREFIX cdt: + +ASK { + { + SELECT (FOLD(?k, ?v) AS ?map) + WHERE { + VALUES (?k ?v) { + (2 UNDEF) + (1 "one") + ("hello"@en "there"@en) + } + } + } + + FILTER(cdt:get(?map, 1) = "one") + BIND(cdt:get(?map, 2) AS ?null) + FILTER(!BOUND(?null)) + FILTER(cdt:get(?map, 'hello'@en) = "there"@en) +} diff --git a/src/test/resources/sparql-cdts/tests/fold/fold-map-04.rq b/src/test/resources/sparql-cdts/tests/fold/fold-map-04.rq new file mode 100644 index 00000000..a84aa97c --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/fold/fold-map-04.rq @@ -0,0 +1,15 @@ +PREFIX cdt: + +ASK { + { + SELECT (FOLD(?k, ?v) AS ?map) + WHERE { + VALUES (?k ?v) { + (UNDEF "two") + (1 "one") + ("hello"@en "there"@en) + } + } + } + FILTER(?map = "{\"hello\"@en:'there'@en,1:'one'}"^^cdt:Map) +} diff --git a/src/test/resources/sparql-cdts/tests/fold/fold-map-05.rq b/src/test/resources/sparql-cdts/tests/fold/fold-map-05.rq new file mode 100644 index 00000000..bd898e79 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/fold/fold-map-05.rq @@ -0,0 +1,19 @@ +PREFIX cdt: + +ASK { + { + SELECT (FOLD(?k, ?v) AS ?map) + WHERE { + { + BIND( BNODE() AS ?k ) + BIND( 1 AS ?v ) + } + UNION + { + BIND( 42 AS ?k ) + BIND( 2 AS ?v ) + } + } + } + FILTER(?map = "{42:2}"^^cdt:Map) +} diff --git a/src/test/resources/sparql-cdts/tests/fold/fold-map-06.rq b/src/test/resources/sparql-cdts/tests/fold/fold-map-06.rq new file mode 100644 index 00000000..7a4ae693 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/fold/fold-map-06.rq @@ -0,0 +1,15 @@ +PREFIX cdt: + +ASK { + { + SELECT (FOLD(?k, ?v) AS ?map) + WHERE { + VALUES (?k ?v) { + (1 100) + (2 201) + (2 202) + } + } + } + FILTER( (?map = "{1:100, 2:201}"^^cdt:Map) || (?map = "{1:100, 2:202}"^^cdt:Map) ) +} diff --git a/src/test/resources/sparql-cdts/tests/fold/fold-map-orderby-01.rq b/src/test/resources/sparql-cdts/tests/fold/fold-map-orderby-01.rq new file mode 100644 index 00000000..4d95047e --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/fold/fold-map-orderby-01.rq @@ -0,0 +1,16 @@ +PREFIX cdt: + +ASK { + { + SELECT (FOLD(?k, ?v ORDER BY ?sort) AS ?map) + WHERE { + VALUES (?k ?v ?sort) { + (1 100 "irrelevant") + (2 201 1) + (2 203 3) + (2 202 2) + } + } + } + FILTER( ?map = "{1:100, 2:203}"^^cdt:Map ) +} diff --git a/src/test/resources/sparql-cdts/tests/fold/fold-map-orderby-02.rq b/src/test/resources/sparql-cdts/tests/fold/fold-map-orderby-02.rq new file mode 100644 index 00000000..f4ab9f47 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/fold/fold-map-orderby-02.rq @@ -0,0 +1,16 @@ +PREFIX cdt: + +ASK { + { + SELECT (FOLD(?k, ?v ORDER BY DESC(?sort)) AS ?map) + WHERE { + VALUES (?k ?v ?sort) { + (1 100 "irrelevant") + (2 201 1) + (2 203 3) + (2 202 2) + } + } + } + FILTER( ?map = "{1:100, 2:201}"^^cdt:Map ) +} diff --git a/src/test/resources/sparql-cdts/tests/fold/manifest.ttl b/src/test/resources/sparql-cdts/tests/fold/manifest.ttl new file mode 100644 index 00000000..71d21648 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/fold/manifest.ttl @@ -0,0 +1,354 @@ +@prefix rdf: . +@prefix : . +@prefix rdfs: . +@prefix mf: . +@prefix qt: . +@prefix dawgt: . +@prefix sparql: . +@prefix cdt: . + +<> rdf:type mf:Manifest ; + rdfs:label "SPARQL FOLD operator" ; + mf:entries + ( + :fold-list-01 + :fold-list-02 + :fold-list-03 + :fold-list-04 + :fold-list-05 + + :fold-list-distinct-01 + :fold-list-distinct-02 + :fold-list-distinct-03 + :fold-list-distinct-04 + :fold-list-distinct-05 + :fold-list-distinct-06 + :fold-list-distinct-07 + :fold-list-distinct-08 + + :fold-list-orderby-01 + :fold-list-orderby-02 + :fold-list-orderby-03 + :fold-list-orderby-04 + :fold-list-orderby-05 + :fold-list-orderby-06 + + :fold-list-distinct-orderby-01 + :fold-list-distinct-orderby-02 + :fold-list-distinct-orderby-03 + + :fold-map-01 + :fold-map-02 + :fold-map-03 + :fold-map-04 + :fold-map-05 + :fold-map-06 + + :fold-map-orderby-01 + :fold-map-orderby-02 + ) . + +:fold-list-01 rdf:type mf:QueryEvaluationTest ; + mf:name "fold-list-01" ; + rdfs:comment "FOLD a single value list" ; + mf:feature cdt:fold ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result . + +:fold-list-02 rdf:type mf:QueryEvaluationTest ; + mf:name "fold-list-02" ; + rdfs:comment "FOLD on empty group" ; + mf:feature cdt:fold ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result . + +:fold-list-03 rdf:type mf:QueryEvaluationTest ; + mf:name "fold-list-03" ; + rdfs:comment "FOLD with two elements but no ORDER BY" ; + mf:feature cdt:fold ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result . + +:fold-list-04 rdf:type mf:QueryEvaluationTest ; + mf:name "fold-list-04" ; + rdfs:comment "FOLD with two elements, including an error" ; + mf:feature cdt:fold ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result . + +:fold-list-05 rdf:type mf:QueryEvaluationTest ; + mf:name "fold-list-05" ; + rdfs:comment "FOLD with three elements, including two errors" ; + mf:feature cdt:fold ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result . + + +:fold-list-distinct-01 rdf:type mf:QueryEvaluationTest ; + mf:name "fold-list-distinct-01" ; + rdfs:comment "FOLD with DISTINCT" ; + mf:feature cdt:fold ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result . + +:fold-list-distinct-02 rdf:type mf:QueryEvaluationTest ; + mf:name "fold-list-distinct-02" ; + rdfs:comment "FOLD with DISTINCT" ; + mf:feature cdt:fold ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result . + +:fold-list-distinct-03 rdf:type mf:QueryEvaluationTest ; + mf:name "fold-list-distinct-03" ; + rdfs:comment "FOLD with DISTINCT" ; + mf:feature cdt:fold ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result . + +:fold-list-distinct-04 rdf:type mf:QueryEvaluationTest ; + mf:name "fold-list-distinct-04" ; + rdfs:comment "FOLD with DISTINCT" ; + mf:feature cdt:fold ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result . + +:fold-list-distinct-05 rdf:type mf:QueryEvaluationTest ; + mf:name "fold-list-distinct-05" ; + rdfs:comment "FOLD with DISTINCT" ; + mf:feature cdt:fold ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result . + +:fold-list-distinct-06 rdf:type mf:QueryEvaluationTest ; + mf:name "fold-list-distinct-06" ; + rdfs:comment "FOLD with DISTINCT" ; + mf:feature cdt:fold ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result . + +:fold-list-distinct-07 rdf:type mf:QueryEvaluationTest ; + mf:name "fold-list-distinct-07" ; + rdfs:comment "FOLD with DISTINCT" ; + mf:feature cdt:fold ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result . + +:fold-list-distinct-08 rdf:type mf:QueryEvaluationTest ; + mf:name "fold-list-distinct-08" ; + rdfs:comment "FOLD with DISTINCT" ; + mf:feature cdt:fold ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result . + + +:fold-list-orderby-01 rdf:type mf:QueryEvaluationTest ; + mf:name "fold-list-orderby-01" ; + rdfs:comment "FOLD with ordering on the list member values" ; + mf:feature cdt:fold ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result . + +:fold-list-orderby-02 rdf:type mf:QueryEvaluationTest ; + mf:name "fold-list-orderby-02" ; + rdfs:comment "FOLD with ordering on correlated values" ; + mf:feature cdt:fold ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result . + +:fold-list-orderby-03 rdf:type mf:QueryEvaluationTest ; + mf:name "fold-list-orderby-03" ; + rdfs:comment "FOLD with descending ordering on correlated values" ; + mf:feature cdt:fold ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result . + +:fold-list-orderby-04 rdf:type mf:QueryEvaluationTest ; + mf:name "fold-list-orderby-04" ; + rdfs:comment "FOLD with unbound elements" ; + mf:feature cdt:fold ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result . + +:fold-list-orderby-05 rdf:type mf:QueryEvaluationTest ; + mf:name "fold-list-orderby-05" ; + rdfs:comment "FOLD with ORDER BY over different types of RDF terms" ; + mf:feature cdt:fold ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result . + +:fold-list-orderby-06 rdf:type mf:QueryEvaluationTest ; + mf:name "fold-list-orderby-06" ; + rdfs:comment "FOLD with ORDER BY with two sort conditions" ; + mf:feature cdt:fold ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result . + + +:fold-list-distinct-orderby-01 rdf:type mf:QueryEvaluationTest ; + mf:name "fold-list-distinct-orderby-01" ; + rdfs:comment "FOLD with DISTINCT and ORDER BY" ; + mf:feature cdt:fold ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result . + +:fold-list-distinct-orderby-02 rdf:type mf:QueryEvaluationTest ; + mf:name "fold-list-distinct-orderby-02" ; + rdfs:comment "FOLD with DISTINCT and ORDER BY" ; + mf:feature cdt:fold ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result . + +:fold-list-distinct-orderby-03 rdf:type mf:QueryEvaluationTest ; + mf:name "fold-list-distinct-orderby-03" ; + rdfs:comment "FOLD with DISTINCT and ORDER BY" ; + mf:feature cdt:fold ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result . + + +:fold-map-01 rdf:type mf:QueryEvaluationTest ; + mf:name "fold-map-01" ; + rdfs:comment "FOLD on empty group" ; + mf:feature cdt:fold ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result . + +:fold-map-02 rdf:type mf:QueryEvaluationTest ; + mf:name "fold-map-02" ; + rdfs:comment "FOLD pairs into map" ; + mf:feature cdt:fold ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result . + +:fold-map-03 rdf:type mf:QueryEvaluationTest ; + mf:name "fold-map-03" ; + rdfs:comment "FOLD into map with unbound values" ; + mf:feature cdt:fold ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result . + +:fold-map-04 rdf:type mf:QueryEvaluationTest ; + mf:name "fold-map-04" ; + rdfs:comment "FOLD into map with unbound keys" ; + mf:feature cdt:fold ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result . + +:fold-map-05 rdf:type mf:QueryEvaluationTest ; + mf:name "fold-map-05" ; + rdfs:comment "FOLD into map with blank node as key" ; + mf:feature cdt:fold ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result . + +:fold-map-06 rdf:type mf:QueryEvaluationTest ; + mf:name "fold-map-06" ; + rdfs:comment "FOLD into map with duplicate keys" ; + mf:feature cdt:fold ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result . + + +:fold-map-orderby-01 rdf:type mf:QueryEvaluationTest ; + mf:name "fold-map-orderby-01" ; + rdfs:comment "FOLD for maps with ORDER BY" ; + mf:feature cdt:fold ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result . + +:fold-map-orderby-02 rdf:type mf:QueryEvaluationTest ; + mf:name "fold-map-orderby-02" ; + rdfs:comment "FOLD for maps with ORDER BY" ; + mf:feature cdt:fold ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result . diff --git a/src/test/resources/sparql-cdts/tests/fold/true.srx b/src/test/resources/sparql-cdts/tests/fold/true.srx new file mode 100644 index 00000000..c187f066 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/fold/true.srx @@ -0,0 +1,5 @@ + + + + true + diff --git a/src/test/resources/sparql-cdts/tests/list-functions/concat-01.rq b/src/test/resources/sparql-cdts/tests/list-functions/concat-01.rq new file mode 100644 index 00000000..bbb3b05e --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/concat-01.rq @@ -0,0 +1,8 @@ +PREFIX cdt: + +# empty lists +ASK { + BIND("[]"^^cdt:List AS ?empty) + BIND(cdt:concat(?empty, ?empty) AS ?result) + FILTER(?result = ?empty) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/concat-02.rq b/src/test/resources/sparql-cdts/tests/list-functions/concat-02.rq new file mode 100644 index 00000000..e2bf264f --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/concat-02.rq @@ -0,0 +1,10 @@ +PREFIX cdt: + + +# concat identity (lhs) +ASK { + BIND("[]"^^cdt:List AS ?empty) + BIND("[1]"^^cdt:List AS ?one) + BIND(cdt:concat(?empty, ?one) AS ?result) + FILTER(?result = ?one) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/concat-03.rq b/src/test/resources/sparql-cdts/tests/list-functions/concat-03.rq new file mode 100644 index 00000000..9306bc86 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/concat-03.rq @@ -0,0 +1,10 @@ +PREFIX cdt: + + +# concat identity (rhs) +ASK { + BIND("[]"^^cdt:List AS ?empty) + BIND("[1]"^^cdt:List AS ?one) + BIND(cdt:concat(?one, ?empty) AS ?result) + FILTER(?result = ?one) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/concat-04.rq b/src/test/resources/sparql-cdts/tests/list-functions/concat-04.rq new file mode 100644 index 00000000..3f5d77d2 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/concat-04.rq @@ -0,0 +1,9 @@ +PREFIX cdt: + + +# concat duplicate 1-element +ASK { + BIND("[1]"^^cdt:List AS ?one) + BIND(cdt:concat(?one, ?one) AS ?result) + FILTER(?result = "[1,1]"^^cdt:List) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/concat-05.rq b/src/test/resources/sparql-cdts/tests/list-functions/concat-05.rq new file mode 100644 index 00000000..58b63f93 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/concat-05.rq @@ -0,0 +1,9 @@ +PREFIX cdt: + + +# concat duplicate 2-element +ASK { + BIND("[1, 2]"^^cdt:List AS ?list) + BIND(cdt:concat(?list, ?list) AS ?result) + FILTER(?result = "[1,2,1,2]"^^cdt:List) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/concat-06.rq b/src/test/resources/sparql-cdts/tests/list-functions/concat-06.rq new file mode 100644 index 00000000..fa112574 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/concat-06.rq @@ -0,0 +1,10 @@ +PREFIX cdt: + + +# concat different lists +ASK { + BIND("[1, 2]"^^cdt:List AS ?lhs) + BIND("[3, 4]"^^cdt:List AS ?rhs) + BIND(cdt:concat(?lhs, ?rhs) AS ?result) + FILTER(?result = "[1,2,3,4]"^^cdt:List) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/concat-07.rq b/src/test/resources/sparql-cdts/tests/list-functions/concat-07.rq new file mode 100644 index 00000000..e8c27da5 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/concat-07.rq @@ -0,0 +1,10 @@ +PREFIX cdt: + + +# concat nested lists +ASK { + BIND("[[1]]"^^cdt:List AS ?lhs) + BIND("[[2]]"^^cdt:List AS ?rhs) + BIND(cdt:concat(?lhs, ?rhs) AS ?result) + FILTER(?result = "[[1],[2]]"^^cdt:List) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/concat-08.rq b/src/test/resources/sparql-cdts/tests/list-functions/concat-08.rq new file mode 100644 index 00000000..4d7c47bc --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/concat-08.rq @@ -0,0 +1,8 @@ +PREFIX cdt: + + +# nullary concat +ASK { + BIND(cdt:concat() AS ?result) + FILTER(?result = "[]"^^cdt:List) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/concat-09.rq b/src/test/resources/sparql-cdts/tests/list-functions/concat-09.rq new file mode 100644 index 00000000..7d817671 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/concat-09.rq @@ -0,0 +1,9 @@ +PREFIX cdt: + + +# unary concat +ASK { + BIND("[1]"^^cdt:List AS ?input) + BIND(cdt:concat(?input) AS ?result) + FILTER(?result = "[1]"^^cdt:List) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/concat-10.rq b/src/test/resources/sparql-cdts/tests/list-functions/concat-10.rq new file mode 100644 index 00000000..9807d411 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/concat-10.rq @@ -0,0 +1,10 @@ +PREFIX cdt: + + +# ternary concat +ASK { + BIND("[1]"^^cdt:List AS ?list1) + BIND("[2,3]"^^cdt:List AS ?list2) + BIND(cdt:concat(?list1, ?list2, ?list1) AS ?result) + FILTER(?result = "[1,2,3,1]"^^cdt:List) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/concat-error-01.rq b/src/test/resources/sparql-cdts/tests/list-functions/concat-error-01.rq new file mode 100644 index 00000000..629ca626 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/concat-error-01.rq @@ -0,0 +1,8 @@ +PREFIX cdt: + +ASK { + BIND("[]" AS ?noListLiteral) + BIND("[1]"^^cdt:List AS ?one) + BIND(cdt:concat(?noListLiteral, ?one) AS ?result) + FILTER(!BOUND(?result)) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/concat-error-02.rq b/src/test/resources/sparql-cdts/tests/list-functions/concat-error-02.rq new file mode 100644 index 00000000..fc5c4c0f --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/concat-error-02.rq @@ -0,0 +1,7 @@ +PREFIX cdt: + +ASK { + BIND("[]" AS ?noListLiteral) + BIND(cdt:concat(?noListLiteral) AS ?result) + FILTER(!BOUND(?result)) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/concat-null-01.rq b/src/test/resources/sparql-cdts/tests/list-functions/concat-null-01.rq new file mode 100644 index 00000000..83b77d7e --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/concat-null-01.rq @@ -0,0 +1,14 @@ +PREFIX cdt: + +ASK { + BIND("[null]"^^cdt:List AS ?list) + BIND(cdt:concat(?list, ?list) AS ?result) + + FILTER(cdt:size(?result) = 2) + + BIND(cdt:get(?result,1) AS ?elm1) + FILTER(!BOUND(?elm1)) + + BIND(cdt:get(?result,2) AS ?elm2) + FILTER(!BOUND(?elm2)) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/contains-01.rq b/src/test/resources/sparql-cdts/tests/list-functions/contains-01.rq new file mode 100644 index 00000000..31cf52ed --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/contains-01.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +# empty lists +ASK { + BIND("[]"^^cdt:List AS ?list) + FILTER(!cdt:contains(?list, 1)) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/contains-02.rq b/src/test/resources/sparql-cdts/tests/list-functions/contains-02.rq new file mode 100644 index 00000000..52172f20 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/contains-02.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: +# contains integer +ASK { + BIND("[1]"^^cdt:List AS ?list) + FILTER(cdt:contains(?list, 1)) + FILTER(!cdt:contains(?list, 2)) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/contains-03.rq b/src/test/resources/sparql-cdts/tests/list-functions/contains-03.rq new file mode 100644 index 00000000..56a4bc7b --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/contains-03.rq @@ -0,0 +1,22 @@ +PREFIX cdt: +PREFIX xsd: +# contains equality +ASK { + BIND("[1,'a','b'@en,2.0]"^^cdt:List AS ?list) + + # numeric forms + FILTER(cdt:contains(?list, 1)) + FILTER(cdt:contains(?list, "+1"^^xsd:integer)) + FILTER(cdt:contains(?list, "01"^^xsd:integer)) + FILTER(cdt:contains(?list, 1.0)) + FILTER(cdt:contains(?list, 1.0)) + FILTER(cdt:contains(?list, 1e0)) + FILTER(cdt:contains(?list, 2)) + FILTER(cdt:contains(?list, 2.0)) + FILTER(cdt:contains(?list, 2e0)) + + # string forms + FILTER(cdt:contains(?list, 'a')) + FILTER(cdt:contains(?list, 'b'@en)) + FILTER(!cdt:contains(?list, 'b')) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/contains-04.rq b/src/test/resources/sparql-cdts/tests/list-functions/contains-04.rq new file mode 100644 index 00000000..2ba84d52 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/contains-04.rq @@ -0,0 +1,8 @@ +PREFIX cdt: + +# contains IRIs +ASK { + BIND("[,1]"^^cdt:List AS ?list) + + FILTER(cdt:contains(?list, )) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/contains-05.rq b/src/test/resources/sparql-cdts/tests/list-functions/contains-05.rq new file mode 100644 index 00000000..77856f16 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/contains-05.rq @@ -0,0 +1,11 @@ +PREFIX cdt: + +# contains blank nodes +ASK { + BIND("[_:b,null,'_:b']"^^cdt:List AS ?list) + BIND( BNODE() AS ?b ) + BIND( cdt:contains(?list, ?b) AS ?result ) + + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/contains-06.rq b/src/test/resources/sparql-cdts/tests/list-functions/contains-06.rq new file mode 100644 index 00000000..d731c792 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/contains-06.rq @@ -0,0 +1,11 @@ +PREFIX cdt: + +# contains blank nodes +ASK { + BIND("[_:b,2]"^^cdt:List AS ?list) + BIND( cdt:head(?list) AS ?elmt) + BIND( cdt:contains(?list,?elmt) AS ?result ) + + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/contains-07.rq b/src/test/resources/sparql-cdts/tests/list-functions/contains-07.rq new file mode 100644 index 00000000..2205d51e --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/contains-07.rq @@ -0,0 +1,11 @@ +PREFIX cdt: + +# nested lists +ASK { + BIND("[1,[2]]"^^cdt:List AS ?list) + BIND("[2]"^^cdt:List AS ?list2) + + FILTER(cdt:contains(?list, 1)) + FILTER(!cdt:contains(?list, 2)) + FILTER(cdt:contains(?list, ?list2)) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/contains-08.rq b/src/test/resources/sparql-cdts/tests/list-functions/contains-08.rq new file mode 100644 index 00000000..b25666e7 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/contains-08.rq @@ -0,0 +1,11 @@ +PREFIX cdt: + +# nested lists given as literals +ASK { + BIND("[1,'[2]'^^]"^^cdt:List AS ?list) + BIND("[2]"^^cdt:List AS ?list2) + + FILTER(cdt:contains(?list, 1)) + FILTER(!cdt:contains(?list, 2)) + FILTER(cdt:contains(?list, ?list2)) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/contains-09.rq b/src/test/resources/sparql-cdts/tests/list-functions/contains-09.rq new file mode 100644 index 00000000..98ab9c6c --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/contains-09.rq @@ -0,0 +1,12 @@ +PREFIX cdt: + +# nested lists +ASK { + BIND("[1,{2:3}]"^^cdt:List AS ?list) + BIND("{2:3}"^^cdt:Map AS ?map) + + FILTER(cdt:contains(?list, 1)) + FILTER(!cdt:contains(?list, 2)) + FILTER(!cdt:contains(?list, 3)) + FILTER(cdt:contains(?list, ?map)) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/contains-10.rq b/src/test/resources/sparql-cdts/tests/list-functions/contains-10.rq new file mode 100644 index 00000000..19f75b7d --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/contains-10.rq @@ -0,0 +1,12 @@ +PREFIX cdt: + +# nested lists given as literals +ASK { + BIND("[1,'{2:3}'^^]"^^cdt:List AS ?list) + BIND("{2:3}"^^cdt:Map AS ?map) + + FILTER(cdt:contains(?list, 1)) + FILTER(!cdt:contains(?list, 2)) + FILTER(!cdt:contains(?list, 3)) + FILTER(cdt:contains(?list, ?map)) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/contains-error-01.rq b/src/test/resources/sparql-cdts/tests/list-functions/contains-error-01.rq new file mode 100644 index 00000000..af072ad7 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/contains-error-01.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND("[1]" AS ?list) + BIND(cdt:contains(?list, 1) AS ?result) + FILTER(!BOUND(?result)) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/contains-null-01.rq b/src/test/resources/sparql-cdts/tests/list-functions/contains-null-01.rq new file mode 100644 index 00000000..cf8c964a --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/contains-null-01.rq @@ -0,0 +1,9 @@ +PREFIX cdt: +PREFIX xsd: + +# empty lists +ASK { + BIND("[1,null,2]"^^cdt:List AS ?list) + FILTER(cdt:contains(?list, 1.0)) + FILTER(cdt:contains(?list, 2.0)) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/empty.ttl b/src/test/resources/sparql-cdts/tests/list-functions/empty.ttl new file mode 100644 index 00000000..e69de29b diff --git a/src/test/resources/sparql-cdts/tests/list-functions/get-01.rq b/src/test/resources/sparql-cdts/tests/list-functions/get-01.rq new file mode 100644 index 00000000..18533779 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/get-01.rq @@ -0,0 +1,7 @@ +PREFIX cdt: + +# list with one integer +ASK { + BIND("[1]"^^cdt:List AS ?list) + FILTER(cdt:get(?list, 1) = 1) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/get-02.rq b/src/test/resources/sparql-cdts/tests/list-functions/get-02.rq new file mode 100644 index 00000000..c912a17a --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/get-02.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: +# list with two integers +ASK { + BIND("[1, 3]"^^cdt:List AS ?list) + FILTER(cdt:get(?list, 1) = 1) + FILTER(cdt:get(?list, 2) = 3) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/get-03.rq b/src/test/resources/sparql-cdts/tests/list-functions/get-03.rq new file mode 100644 index 00000000..03e825ab --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/get-03.rq @@ -0,0 +1,7 @@ +PREFIX cdt: +PREFIX xsd: +# list with one string +ASK { + BIND("['a']"^^cdt:List AS ?list) + FILTER(cdt:get(?list, 1) = 'a') +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/get-04.rq b/src/test/resources/sparql-cdts/tests/list-functions/get-04.rq new file mode 100644 index 00000000..02d5638f --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/get-04.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: +# list with two strings +ASK { + BIND("['a', 'b']"^^cdt:List AS ?list) + FILTER(cdt:get(?list, 1) = 'a') + FILTER(cdt:get(?list, 2) = 'b') +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/get-05.rq b/src/test/resources/sparql-cdts/tests/list-functions/get-05.rq new file mode 100644 index 00000000..4e93e233 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/get-05.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: +# list with two mixed types +ASK { + BIND("['a', 1]"^^cdt:List AS ?list) + FILTER(cdt:get(?list, 1) = 'a') + FILTER(cdt:get(?list, 2) = 1) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/get-06.rq b/src/test/resources/sparql-cdts/tests/list-functions/get-06.rq new file mode 100644 index 00000000..2e65a68c --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/get-06.rq @@ -0,0 +1,11 @@ +PREFIX cdt: +PREFIX xsd: +# list with nested empty list +ASK { + BIND("[[]]"^^cdt:List AS ?list) + BIND((cdt:get(?list, 1)) AS ?l0) + BIND((cdt:get(?l0, 1)) AS ?l1) + FILTER(BOUND(?l0)) + FILTER(!BOUND(?l1)) + FILTER(?l0 = "[]"^^cdt:List) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/get-07.rq b/src/test/resources/sparql-cdts/tests/list-functions/get-07.rq new file mode 100644 index 00000000..b7b6ce11 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/get-07.rq @@ -0,0 +1,9 @@ +PREFIX cdt: +PREFIX xsd: +# list with nested list with one integer +ASK { + BIND("[[1]]"^^cdt:List AS ?list) + BIND((cdt:get(?list, 1)) AS ?l0) + BIND((cdt:get(?l0, 1)) AS ?l1) + FILTER(?l1 = 1) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/get-08.rq b/src/test/resources/sparql-cdts/tests/list-functions/get-08.rq new file mode 100644 index 00000000..a953f799 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/get-08.rq @@ -0,0 +1,10 @@ +PREFIX cdt: +PREFIX xsd: +# list with mixed types including nested list +ASK { + BIND("[[1], 3]"^^cdt:List AS ?list) + BIND((cdt:get(?list, 1)) AS ?l0) + BIND((cdt:get(?l0, 1)) AS ?l1) + FILTER(?l1 = 1) + FILTER(cdt:get(?list, 2) = 3) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/get-09.rq b/src/test/resources/sparql-cdts/tests/list-functions/get-09.rq new file mode 100644 index 00000000..2172c821 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/get-09.rq @@ -0,0 +1,9 @@ +PREFIX cdt: +PREFIX xsd: +# list with mixed defined and undefined types +ASK { + BIND("[null, 3]"^^cdt:List AS ?list) + BIND((cdt:get(?list, 1)) AS ?l0) + FILTER(!BOUND(?l0)) + FILTER(cdt:get(?list, 2) = 3) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/get-10.rq b/src/test/resources/sparql-cdts/tests/list-functions/get-10.rq new file mode 100644 index 00000000..35c86c2a --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/get-10.rq @@ -0,0 +1,9 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( "[_:b]"^^cdt:List AS ?list ) + BIND( cdt:get(?list, 1) AS ?e1 ) + + FILTER( isBLANK(?e1) ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/get-11.rq b/src/test/resources/sparql-cdts/tests/list-functions/get-11.rq new file mode 100644 index 00000000..8f9d3c10 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/get-11.rq @@ -0,0 +1,12 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( "[_:b]"^^cdt:List AS ?list ) + BIND( cdt:get(?list, 1) AS ?e1 ) + BIND( cdt:get(?list, 1) AS ?e1Again ) + + FILTER( isBLANK(?e1) ) + FILTER( isBLANK(?e1Again) ) + FILTER( SAMETERM(?e1, ?e1Again) ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/get-12.rq b/src/test/resources/sparql-cdts/tests/list-functions/get-12.rq new file mode 100644 index 00000000..6157a9d7 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/get-12.rq @@ -0,0 +1,12 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( "[_:b,_:b]"^^cdt:List AS ?list ) + BIND( cdt:get(?list, 1) AS ?e1 ) + BIND( cdt:get(?list, 2) AS ?e2 ) + + FILTER( isBLANK(?e1) ) + FILTER( isBLANK(?e2) ) + FILTER( SAMETERM(?e1, ?e2) ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/get-13.rq b/src/test/resources/sparql-cdts/tests/list-functions/get-13.rq new file mode 100644 index 00000000..52171a40 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/get-13.rq @@ -0,0 +1,12 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( "[_:b1,_:b2]"^^cdt:List AS ?list ) + BIND( cdt:get(?list, 1) AS ?e1 ) + BIND( cdt:get(?list, 2) AS ?e2 ) + + FILTER( isBLANK(?e1) ) + FILTER( isBLANK(?e2) ) + FILTER( ! SAMETERM(?e1, ?e2) ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/get-error-01.rq b/src/test/resources/sparql-cdts/tests/list-functions/get-error-01.rq new file mode 100644 index 00000000..9959a112 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/get-error-01.rq @@ -0,0 +1,7 @@ +PREFIX cdt: + +ASK { + BIND("[1,2,3]" AS ?list) + BIND(cdt:get(?list, 1) AS ?element) + FILTER(!BOUND(?element)) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/get-error-02.rq b/src/test/resources/sparql-cdts/tests/list-functions/get-error-02.rq new file mode 100644 index 00000000..29c589c6 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/get-error-02.rq @@ -0,0 +1,7 @@ +PREFIX cdt: + +ASK { + BIND("[1,2,3]"^^cdt:List AS ?list) + BIND(cdt:get(?list, 10) AS ?element) + FILTER(!BOUND(?element)) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/get-error-03.rq b/src/test/resources/sparql-cdts/tests/list-functions/get-error-03.rq new file mode 100644 index 00000000..4202ba6b --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/get-error-03.rq @@ -0,0 +1,7 @@ +PREFIX cdt: + +ASK { + BIND("[1,2,3]"^^cdt:List AS ?list) + BIND(cdt:get(?list, 0) AS ?element) + FILTER(!BOUND(?element)) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/get-error-04.rq b/src/test/resources/sparql-cdts/tests/list-functions/get-error-04.rq new file mode 100644 index 00000000..cd8ef621 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/get-error-04.rq @@ -0,0 +1,7 @@ +PREFIX cdt: + +ASK { + BIND("[1,2,3]"^^cdt:List AS ?list) + BIND(cdt:get(?list, -1) AS ?element) + FILTER(!BOUND(?element)) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/get-error-05.rq b/src/test/resources/sparql-cdts/tests/list-functions/get-error-05.rq new file mode 100644 index 00000000..8e3a5c47 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/get-error-05.rq @@ -0,0 +1,7 @@ +PREFIX cdt: + +ASK { + BIND("[1,2,3]"^^cdt:List AS ?list) + BIND(cdt:get(?list, "invalid") AS ?element) + FILTER(!BOUND(?element)) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/get-error-06.rq b/src/test/resources/sparql-cdts/tests/list-functions/get-error-06.rq new file mode 100644 index 00000000..c9607998 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/get-error-06.rq @@ -0,0 +1,7 @@ +PREFIX cdt: + +ASK { + BIND("[1,2,3]"^^cdt:List AS ?list) + BIND(cdt:get(?list, 2.0) AS ?element) + FILTER(!BOUND(?element)) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/get-null-01.rq b/src/test/resources/sparql-cdts/tests/list-functions/get-null-01.rq new file mode 100644 index 00000000..76700ebe --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/get-null-01.rq @@ -0,0 +1,7 @@ +PREFIX cdt: + +ASK { + BIND("[null]"^^cdt:List AS ?list) + BIND(cdt:get(?list, 1) AS ?element) + FILTER(!BOUND(?element)) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/get-null-02.rq b/src/test/resources/sparql-cdts/tests/list-functions/get-null-02.rq new file mode 100644 index 00000000..165dfd06 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/get-null-02.rq @@ -0,0 +1,7 @@ +PREFIX cdt: + +ASK { + BIND("[]"^^cdt:List AS ?list) + BIND(cdt:get(?list, 1) AS ?element) + FILTER(!BOUND(?element)) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/head-01.rq b/src/test/resources/sparql-cdts/tests/list-functions/head-01.rq new file mode 100644 index 00000000..bcce6665 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/head-01.rq @@ -0,0 +1,8 @@ +PREFIX cdt: + +# empty list +ASK { + BIND("[]"^^cdt:List AS ?list) + BIND(cdt:head(?list) AS ?head) + FILTER(!BOUND(?head)) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/head-02.rq b/src/test/resources/sparql-cdts/tests/list-functions/head-02.rq new file mode 100644 index 00000000..46c97d6e --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/head-02.rq @@ -0,0 +1,7 @@ +PREFIX cdt: +PREFIX xsd: +# list with one integer +ASK { + BIND("[1]"^^cdt:List AS ?list) + FILTER(cdt:head(?list) = 1) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/head-03.rq b/src/test/resources/sparql-cdts/tests/list-functions/head-03.rq new file mode 100644 index 00000000..e0ace57d --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/head-03.rq @@ -0,0 +1,7 @@ +PREFIX cdt: +PREFIX xsd: +# list with two integers +ASK { + BIND("[1, 2]"^^cdt:List AS ?list) + FILTER(cdt:head(?list) = 1) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/head-04.rq b/src/test/resources/sparql-cdts/tests/list-functions/head-04.rq new file mode 100644 index 00000000..e6ecbfd3 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/head-04.rq @@ -0,0 +1,7 @@ +PREFIX cdt: +PREFIX xsd: +# list with one string +ASK { + BIND("['a']"^^cdt:List AS ?list) + FILTER(cdt:head(?list) = 'a') +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/head-05.rq b/src/test/resources/sparql-cdts/tests/list-functions/head-05.rq new file mode 100644 index 00000000..1c534dce --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/head-05.rq @@ -0,0 +1,7 @@ +PREFIX cdt: +PREFIX xsd: +# list with two strings +ASK { + BIND("['a', 'b']"^^cdt:List AS ?list) + FILTER(cdt:head(?list) = 'a') +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/head-06.rq b/src/test/resources/sparql-cdts/tests/list-functions/head-06.rq new file mode 100644 index 00000000..0d483937 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/head-06.rq @@ -0,0 +1,7 @@ +PREFIX cdt: +PREFIX xsd: +# list with two mixed types +ASK { + BIND("['a', 1]"^^cdt:List AS ?list) + FILTER(cdt:head(?list) = 'a') +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/head-07.rq b/src/test/resources/sparql-cdts/tests/list-functions/head-07.rq new file mode 100644 index 00000000..45a4fcdb --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/head-07.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: +# list with null +ASK { + BIND("[null]"^^cdt:List AS ?list) + BIND(cdt:head(?list) AS ?head) + FILTER(!BOUND(?head)) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/head-08.rq b/src/test/resources/sparql-cdts/tests/list-functions/head-08.rq new file mode 100644 index 00000000..4118dd57 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/head-08.rq @@ -0,0 +1,7 @@ +PREFIX cdt: +PREFIX xsd: +# list with nested empty list +ASK { + BIND("[[]]"^^cdt:List AS ?list) + FILTER(cdt:head(?list) = "[]"^^cdt:List) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/head-09.rq b/src/test/resources/sparql-cdts/tests/list-functions/head-09.rq new file mode 100644 index 00000000..d2507388 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/head-09.rq @@ -0,0 +1,7 @@ +PREFIX cdt: +PREFIX xsd: +# list with mixed types including nested list +ASK { + BIND("[[1], 2]"^^cdt:List AS ?list) + FILTER(cdt:head(?list) = "[1]"^^cdt:List) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/head-10.rq b/src/test/resources/sparql-cdts/tests/list-functions/head-10.rq new file mode 100644 index 00000000..f911d8e3 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/head-10.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: +# list with mixed defined and undefined types +ASK { + BIND("[null, 2]"^^cdt:List AS ?list) + BIND(cdt:head(?list) AS ?head) + FILTER(!BOUND(?head)) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/head-11.rq b/src/test/resources/sparql-cdts/tests/list-functions/head-11.rq new file mode 100644 index 00000000..c0f34d09 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/head-11.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: +# list with mixed defined and undefined types +ASK { + BIND("[_:b]"^^cdt:List AS ?list) + BIND(cdt:head(?list) AS ?head) + FILTER(isBLANK(?head)) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/head-12.rq b/src/test/resources/sparql-cdts/tests/list-functions/head-12.rq new file mode 100644 index 00000000..16728ec5 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/head-12.rq @@ -0,0 +1,11 @@ +PREFIX cdt: +PREFIX xsd: +# list with mixed defined and undefined types +ASK { + BIND("[_:b]"^^cdt:List AS ?list) + BIND(cdt:head(?list) AS ?head) + BIND(cdt:head(?list) AS ?headAgain) + FILTER(isBLANK(?head)) + FILTER(isBLANK(?headAgain)) + FILTER(SAMETERM(?head, ?headAgain)) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/head-error-01.rq b/src/test/resources/sparql-cdts/tests/list-functions/head-error-01.rq new file mode 100644 index 00000000..1f1614ac --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/head-error-01.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND("[1,2]" AS ?list) + BIND(cdt:head(?list) AS ?result) + FILTER(!BOUND(?result)) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/head-null-01.rq b/src/test/resources/sparql-cdts/tests/list-functions/head-null-01.rq new file mode 100644 index 00000000..dfacc458 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/head-null-01.rq @@ -0,0 +1,7 @@ +PREFIX cdt: + +ASK { + BIND("[null]"^^cdt:List AS ?list) + BIND(cdt:head(?list) AS ?head) + FILTER(!BOUND(?head)) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/head-null-02.rq b/src/test/resources/sparql-cdts/tests/list-functions/head-null-02.rq new file mode 100644 index 00000000..80ce6919 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/head-null-02.rq @@ -0,0 +1,7 @@ +PREFIX cdt: + +ASK { + BIND("[]"^^cdt:List AS ?list) + BIND(cdt:head(?list) AS ?head) + FILTER(!BOUND(?head)) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-constructor-01.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-constructor-01.rq new file mode 100644 index 00000000..9850ec55 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-constructor-01.rq @@ -0,0 +1,7 @@ +PREFIX cdt: + +# empty list +ASK { + BIND(cdt:List() AS ?list) + FILTER(?list = "[]"^^cdt:List) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-constructor-02.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-constructor-02.rq new file mode 100644 index 00000000..e779e332 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-constructor-02.rq @@ -0,0 +1,8 @@ +PREFIX cdt: + + +# list with one integer +ASK { + BIND(cdt:List(1) AS ?list) + FILTER(?list = "[1]"^^cdt:List) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-constructor-03.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-constructor-03.rq new file mode 100644 index 00000000..857c1533 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-constructor-03.rq @@ -0,0 +1,8 @@ +PREFIX cdt: + + +# list with two integers +ASK { + BIND(cdt:List(1, 2) AS ?list) + FILTER(?list = "[1, 2]"^^cdt:List) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-constructor-04.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-constructor-04.rq new file mode 100644 index 00000000..3db696f8 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-constructor-04.rq @@ -0,0 +1,8 @@ +PREFIX cdt: + + +# list with one string +ASK { + BIND(cdt:List("a") AS ?list) + FILTER(?list = "['a']"^^cdt:List) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-constructor-05.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-constructor-05.rq new file mode 100644 index 00000000..2032858f --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-constructor-05.rq @@ -0,0 +1,8 @@ +PREFIX cdt: + + +# list with two strings +ASK { + BIND(cdt:List("a", "b") AS ?list) + FILTER(?list = "['a', 'b']"^^cdt:List) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-constructor-06.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-constructor-06.rq new file mode 100644 index 00000000..b14d3857 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-constructor-06.rq @@ -0,0 +1,8 @@ +PREFIX cdt: + + +# list with two mixed types +ASK { + BIND(cdt:List("a", 1) AS ?list) + FILTER(?list = "['a', 1]"^^cdt:List) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-constructor-09.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-constructor-09.rq new file mode 100644 index 00000000..50d0e648 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-constructor-09.rq @@ -0,0 +1,8 @@ +PREFIX cdt: + + +# list with nested empty list +ASK { + BIND(cdt:List(cdt:List()) AS ?list) + FILTER(?list = "[[]]"^^cdt:List) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-constructor-10.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-constructor-10.rq new file mode 100644 index 00000000..bf4fcd7a --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-constructor-10.rq @@ -0,0 +1,8 @@ +PREFIX cdt: + + +# list with nested list with one integer +ASK { + BIND(cdt:List(cdt:List(1)) AS ?list) + FILTER(?list = "[[1]]"^^cdt:List) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-constructor-11.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-constructor-11.rq new file mode 100644 index 00000000..48b8e9e7 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-constructor-11.rq @@ -0,0 +1,8 @@ +PREFIX cdt: + + +# list with mixed types including nested list +ASK { + BIND(cdt:List(cdt:List(1), 2) AS ?list) + FILTER(?list = "[[1], 2]"^^cdt:List) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-constructor-12.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-constructor-12.rq new file mode 100644 index 00000000..235f0bdd --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-constructor-12.rq @@ -0,0 +1,12 @@ +PREFIX cdt: + +# list with mixed defined and undefined types +ASK { + BIND(cdt:List(?unbound, ) AS ?list) + + # We use a REGEX here because we can't directly test equality of lists containing null + # we could use SAMETERM, but that would likely depend on the lexical form produced by + # the system for lists, and not necessarily tell us that the expected terms were actuall + # in the resulting list. + FILTER(REGEX(STR(?list), "\\[\\s*null\\s*,\\s*\\s*\\]")) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-constructor-13.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-constructor-13.rq new file mode 100644 index 00000000..e787aa10 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-constructor-13.rq @@ -0,0 +1,9 @@ +PREFIX cdt: + + +# rdf literal syntax +ASK { + BIND(cdt:List() AS ?list) + BIND("[]"^^cdt:List AS ?expected) + FILTER(?list = ?expected) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-constructor-14.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-constructor-14.rq new file mode 100644 index 00000000..8ccb934a --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-constructor-14.rq @@ -0,0 +1,8 @@ +PREFIX cdt: + + +# STRDT constructor +ASK { + BIND(STRDT("[1]", cdt:List) AS ?list) + FILTER(?list = "[ 1 ]"^^cdt:List) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-constructor-15.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-constructor-15.rq new file mode 100644 index 00000000..e000a173 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-constructor-15.rq @@ -0,0 +1,9 @@ +PREFIX cdt: + + +# list with two integers +ASK { + BIND(3 AS ?x) + BIND(cdt:List(1+4, 1+?x) AS ?list) + FILTER(?list = "[5, 4]"^^cdt:List) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-constructor-16.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-constructor-16.rq new file mode 100644 index 00000000..b12392a8 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-constructor-16.rq @@ -0,0 +1,12 @@ +PREFIX cdt: + +ASK { + BIND( BNODE() AS ?b ) + BIND( cdt:List(?b) AS ?list ) + + FILTER( BOUND(?list) ) # check that there was no error + + BIND( cdt:get(?list,1) AS ?e1 ) + FILTER( isBlank(?e1) ) + FILTER( SAMETERM(?e1, ?b) ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-constructor-null-01.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-constructor-null-01.rq new file mode 100644 index 00000000..bc30ee98 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-constructor-null-01.rq @@ -0,0 +1,12 @@ +PREFIX cdt: + +# list with one integer +ASK { + BIND(cdt:List(?unbound) AS ?list) + + # We use a REGEX here because we can't directly test equality of lists containing null + # we could use SAMETERM, but that would likely depend on the lexical form produced by + # the system for lists, and not necessarily tell us that the expected terms were actually + # in the resulting list. + FILTER(REGEX(STR(?list), "\\[\\s*null\\s*\\]")) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-constructor-null-02.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-constructor-null-02.rq new file mode 100644 index 00000000..0cebf4cc --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-constructor-null-02.rq @@ -0,0 +1,12 @@ +PREFIX cdt: + +# list with error as null +ASK { + BIND(cdt:List(1/0) AS ?list) + + # We use a REGEX here because we can't directly test equality of lists containing null + # we could use SAMETERM, but that would likely depend on the lexical form produced by + # the system for lists, and not necessarily tell us that the expected terms were actually + # in the resulting list. + FILTER(REGEX(STR(?list), "\\[\\s*null\\s*\\]")) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-equals-01.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-equals-01.rq new file mode 100644 index 00000000..21ed12b6 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-equals-01.rq @@ -0,0 +1,6 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + FILTER("[ ]"^^cdt:List = "[]"^^cdt:List) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-equals-02.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-equals-02.rq new file mode 100644 index 00000000..4e25ff13 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-equals-02.rq @@ -0,0 +1,6 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + FILTER("[ 1 ]"^^cdt:List = "[1]"^^cdt:List) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-equals-03.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-equals-03.rq new file mode 100644 index 00000000..d1af3843 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-equals-03.rq @@ -0,0 +1,6 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + FILTER("[1,2]"^^cdt:List = "[ 1, '2'^^ ]"^^cdt:List) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-equals-04.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-equals-04.rq new file mode 100644 index 00000000..beb3ab90 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-equals-04.rq @@ -0,0 +1,6 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + FILTER("[1,2]"^^cdt:List = "['+1'^^, 2.0]"^^cdt:List) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-equals-05.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-equals-05.rq new file mode 100644 index 00000000..d880e2e6 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-equals-05.rq @@ -0,0 +1,6 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + FILTER( "[]"^^cdt:List = "[ ]"^^cdt:List ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-equals-06.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-equals-06.rq new file mode 100644 index 00000000..70c795ce --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-equals-06.rq @@ -0,0 +1,7 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[_:b1]"^^cdt:List = "[_:b2]"^^cdt:List ) AS ?result ) + FILTER( ! BOUND(?result) ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-equals-07.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-equals-07.rq new file mode 100644 index 00000000..3199271d --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-equals-07.rq @@ -0,0 +1,7 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[ _:b ]"^^cdt:List = "[_:b]"^^cdt:List ) AS ?result ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-equals-08.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-equals-08.rq new file mode 100644 index 00000000..0361b5e4 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-equals-08.rq @@ -0,0 +1,9 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( BNODE() AS ?x ) + BIND( BNODE() AS ?y ) + BIND( ( cdt:List(?x) = cdt:List(?y) ) AS ?result ) + FILTER( ! BOUND(?result) ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-equals-09.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-equals-09.rq new file mode 100644 index 00000000..79f3cbb4 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-equals-09.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( BNODE() AS ?x ) + BIND( ( cdt:List(?x) = cdt:List(?x) ) AS ?result ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-equals-null-01.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-equals-null-01.rq new file mode 100644 index 00000000..c1b8a773 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-equals-null-01.rq @@ -0,0 +1,7 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND("[ 1 , null , 2 ]"^^cdt:List = "[1,null,2]"^^cdt:List AS ?result) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-equals-null-02.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-equals-null-02.rq new file mode 100644 index 00000000..443638e7 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-equals-null-02.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND(cdt:List(1, ?undef, 2) AS ?list) + BIND(?list = "[1,44,2]"^^cdt:List AS ?result) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-01.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-01.rq new file mode 100644 index 00000000..70fb26b6 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-01.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[ ]"^^cdt:List >= "[]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-02.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-02.rq new file mode 100644 index 00000000..0db47798 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-02.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[]"^^cdt:List >= "[1]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-03.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-03.rq new file mode 100644 index 00000000..44040d1f --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-03.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[1]"^^cdt:List >= "[]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-04.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-04.rq new file mode 100644 index 00000000..f6778581 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-04.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[ 1]"^^cdt:List >= "[1 ]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-05.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-05.rq new file mode 100644 index 00000000..efe0db13 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-05.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[1]"^^cdt:List >= "[2]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-06.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-06.rq new file mode 100644 index 00000000..00667702 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-06.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[2]"^^cdt:List >= "[1]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-07.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-07.rq new file mode 100644 index 00000000..696e35ec --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-07.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[1,2]"^^cdt:List >= "[1,3]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-08.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-08.rq new file mode 100644 index 00000000..44b0a7c0 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-08.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[1,3]"^^cdt:List >= "[1,2]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-09.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-09.rq new file mode 100644 index 00000000..9d107f74 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-09.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[1,2]"^^cdt:List >= "[1,2,3]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-10.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-10.rq new file mode 100644 index 00000000..3c8505e9 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-10.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[1,2,3]"^^cdt:List >= "[1,2]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-11.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-11.rq new file mode 100644 index 00000000..01af549d --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-11.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[1,1,2]"^^cdt:List >= "[1,2,3]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-12.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-12.rq new file mode 100644 index 00000000..b3c8ad78 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-12.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[1,2,3]"^^cdt:List >= "[1,1,2]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-13.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-13.rq new file mode 100644 index 00000000..1762d705 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-13.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[1,1,1]"^^cdt:List >= "[1,2]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-14.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-14.rq new file mode 100644 index 00000000..02bf5e6f --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-14.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[1,2]"^^cdt:List >= "[1,1,1]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-15.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-15.rq new file mode 100644 index 00000000..1c359a37 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-15.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[true]"^^cdt:List >= "[false]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-16.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-16.rq new file mode 100644 index 00000000..de090e31 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-16.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[false]"^^cdt:List >= "[true]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-19.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-19.rq new file mode 100644 index 00000000..934eede7 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-19.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[1,false]"^^cdt:List >= "[1,true]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-20.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-20.rq new file mode 100644 index 00000000..f58c97f7 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-20.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[1,true]"^^cdt:List >= "[1,false]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-21.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-21.rq new file mode 100644 index 00000000..14e3b647 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-21.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[1,false,2]"^^cdt:List >= "[1,true,1]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-22.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-22.rq new file mode 100644 index 00000000..c9342d38 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-22.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[1,true,1]"^^cdt:List >= "[1,false,2]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-23.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-23.rq new file mode 100644 index 00000000..0f342220 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-23.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[1,false,true]"^^cdt:List >= "[1,true]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-24.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-24.rq new file mode 100644 index 00000000..f404b4ea --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-24.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[1,true]"^^cdt:List >= "[1,false,true]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-25.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-25.rq new file mode 100644 index 00000000..f56080fb --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-25.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[_:b]"^^cdt:List >= "[]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-26.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-26.rq new file mode 100644 index 00000000..027a88c4 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-26.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[]"^^cdt:List >= "[_:b]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-27.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-27.rq new file mode 100644 index 00000000..5b989eaf --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-27.rq @@ -0,0 +1,9 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( BNODE() AS ?x ) + BIND( BNODE() AS ?y ) + BIND( ( cdt:List(?x) >= cdt:List(?y) ) AS ?result ) + FILTER( ! BOUND(?result) ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-28.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-28.rq new file mode 100644 index 00000000..bbced570 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-28.rq @@ -0,0 +1,7 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[_:b]"^^cdt:List >= "[_:b]"^^cdt:List ) AS ?result ) + FILTER( ! BOUND(?result) ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-29.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-29.rq new file mode 100644 index 00000000..f16298b3 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-29.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( BNODE() AS ?x ) + BIND( ( cdt:List(?x) >= cdt:List(?x) ) AS ?result ) + FILTER( ! BOUND(?result) ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-31.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-31.rq new file mode 100644 index 00000000..ade6b0be --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-31.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[ ]"^^cdt:List >= "[]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-error-03.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-error-03.rq new file mode 100644 index 00000000..71ac6d6f --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-error-03.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( cdt:List(2) AS ?list2 ) + BIND( ( "1"^^cdt:List >= ?list2 ) AS ?result ) + FILTER( ! BOUND(?result) ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-error-04.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-error-04.rq new file mode 100644 index 00000000..6a47a8e9 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-error-04.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( cdt:List(1) AS ?list1 ) + BIND( ( ?list1 >= "2"^^cdt:List ) AS ?result ) + FILTER( ! BOUND(?result) ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-null-01.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-null-01.rq new file mode 100644 index 00000000..bd51e9b0 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-null-01.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[null]"^^cdt:List >= "[]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-null-02.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-null-02.rq new file mode 100644 index 00000000..646a58be --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-null-02.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[]"^^cdt:List >= "[null]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-null-03.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-null-03.rq new file mode 100644 index 00000000..caea9ea1 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-null-03.rq @@ -0,0 +1,7 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[ null ]"^^cdt:List >= "[null]"^^cdt:List ) AS ?result ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-null-04.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-null-04.rq new file mode 100644 index 00000000..10843059 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-null-04.rq @@ -0,0 +1,11 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( cdt:List(?x, ?y) AS ?list1 ) + BIND( cdt:List(?z) AS ?list2 ) + BIND( ( ?list1 >= ?list2 ) AS ?result) + + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-null-05.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-null-05.rq new file mode 100644 index 00000000..ce5a2709 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-null-05.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[1,null]"^^cdt:List >= "[2,null]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-null-06.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-null-06.rq new file mode 100644 index 00000000..09bce3ad --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-equal-null-06.rq @@ -0,0 +1,9 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( cdt:List(?x) AS ?list1 ) + BIND( cdt:List(BNODE()) AS ?list2 ) + BIND( ( ?list1 >= ?list2 ) AS ?result ) + FILTER( ! BOUND(?result) ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-01.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-01.rq new file mode 100644 index 00000000..2ff4169f --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-01.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[ ]"^^cdt:List > "[]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-02.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-02.rq new file mode 100644 index 00000000..5ea1b43b --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-02.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[]"^^cdt:List > "[1]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-03.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-03.rq new file mode 100644 index 00000000..041b7d15 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-03.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[1]"^^cdt:List > "[]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-04.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-04.rq new file mode 100644 index 00000000..4428cbc3 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-04.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[ 1 ]"^^cdt:List > "[1]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-05.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-05.rq new file mode 100644 index 00000000..7ff7ee1f --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-05.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[1]"^^cdt:List > "[2]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-06.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-06.rq new file mode 100644 index 00000000..2e37745b --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-06.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[2]"^^cdt:List > "[1]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-07.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-07.rq new file mode 100644 index 00000000..d3c2fd96 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-07.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[1,2]"^^cdt:List > "[1,3]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-08.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-08.rq new file mode 100644 index 00000000..91ecc4de --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-08.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[1,3]"^^cdt:List > "[1,2]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-09.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-09.rq new file mode 100644 index 00000000..697ecb49 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-09.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[1,2]"^^cdt:List > "[1,2,3]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-10.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-10.rq new file mode 100644 index 00000000..37537807 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-10.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[1,2,3]"^^cdt:List > "[1,2]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-11.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-11.rq new file mode 100644 index 00000000..c8992ecb --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-11.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[1,1,2]"^^cdt:List > "[1,2,3]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-12.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-12.rq new file mode 100644 index 00000000..ccadc2f2 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-12.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[1,2,3]"^^cdt:List > "[1,1,2]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-13.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-13.rq new file mode 100644 index 00000000..84e5c673 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-13.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[1,1,1]"^^cdt:List > "[1,2]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-14.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-14.rq new file mode 100644 index 00000000..5af4c5de --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-14.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[1,2]"^^cdt:List > "[1,1,1]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-15.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-15.rq new file mode 100644 index 00000000..a6e3c801 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-15.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[true]"^^cdt:List > "[false]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-16.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-16.rq new file mode 100644 index 00000000..70746cad --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-16.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[false]"^^cdt:List > "[true]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-19.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-19.rq new file mode 100644 index 00000000..f9fd5923 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-19.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[1,false]"^^cdt:List > "[1,true]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-20.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-20.rq new file mode 100644 index 00000000..574324ba --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-20.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[1,true]"^^cdt:List > "[1,false]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-21.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-21.rq new file mode 100644 index 00000000..23f63a1a --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-21.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[1,false,2]"^^cdt:List > "[1,true,1]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-22.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-22.rq new file mode 100644 index 00000000..559c59b0 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-22.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[1,true,1]"^^cdt:List > "[1,false,2]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-23.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-23.rq new file mode 100644 index 00000000..fe3089b0 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-23.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[1,false,true]"^^cdt:List > "[1,true]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-24.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-24.rq new file mode 100644 index 00000000..8b60bd1c --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-24.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[1,true]"^^cdt:List > "[1,false,true]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-25.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-25.rq new file mode 100644 index 00000000..a9b680ab --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-25.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[_:b]"^^cdt:List > "[]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-26.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-26.rq new file mode 100644 index 00000000..59eb320e --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-26.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[]"^^cdt:List > "[_:b]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-27.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-27.rq new file mode 100644 index 00000000..ca2d5b8d --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-27.rq @@ -0,0 +1,9 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( BNODE() AS ?x ) + BIND( BNODE() AS ?y ) + BIND( ( cdt:List(?x) > cdt:List(?y) ) AS ?result ) + FILTER( ! BOUND(?result) ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-28.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-28.rq new file mode 100644 index 00000000..21cbc743 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-28.rq @@ -0,0 +1,7 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[_:b]"^^cdt:List > "[_:b]"^^cdt:List ) AS ?result ) + FILTER( ! BOUND(?result) ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-29.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-29.rq new file mode 100644 index 00000000..28d77bff --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-29.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( BNODE() AS ?x ) + BIND( ( cdt:List(?x) > cdt:List(?x) ) AS ?result ) + FILTER( ! BOUND(?result) ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-31.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-31.rq new file mode 100644 index 00000000..f116c7a5 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-31.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[ ]"^^cdt:List > "[]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-error-03.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-error-03.rq new file mode 100644 index 00000000..44e6d990 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-error-03.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( cdt:List(2) AS ?list2 ) + BIND( ( "1"^^cdt:List > ?list2 ) AS ?result ) + FILTER( ! BOUND(?result) ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-error-04.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-error-04.rq new file mode 100644 index 00000000..e54ea409 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-error-04.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( cdt:List(1) AS ?list1 ) + BIND( ( ?list1 > "2"^^cdt:List ) AS ?result ) + FILTER( ! BOUND(?result) ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-null-01.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-null-01.rq new file mode 100644 index 00000000..49c9dee7 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-null-01.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[null]"^^cdt:List > "[]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-null-02.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-null-02.rq new file mode 100644 index 00000000..680f4acc --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-null-02.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[]"^^cdt:List > "[null]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-null-03.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-null-03.rq new file mode 100644 index 00000000..00e524a1 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-null-03.rq @@ -0,0 +1,9 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[null]"^^cdt:List > "[ null ]"^^cdt:List ) AS ?result ) + + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-null-04.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-null-04.rq new file mode 100644 index 00000000..1cb765ed --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-null-04.rq @@ -0,0 +1,11 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( cdt:List(?x, ?y) AS ?list1 ) + BIND( cdt:List(?z) AS ?list2 ) + BIND( ( ?list1 > ?list2 ) AS ?result) + + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-null-05.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-null-05.rq new file mode 100644 index 00000000..7c4b16f2 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-null-05.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[1,null]"^^cdt:List > "[2,null]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-null-06.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-null-06.rq new file mode 100644 index 00000000..c54b5269 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-greater-than-null-06.rq @@ -0,0 +1,9 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( cdt:List(?x) AS ?list1 ) + BIND( cdt:List(BNODE()) AS ?list2 ) + BIND( ( ?list1 > ?list2 ) AS ?result ) + FILTER( ! BOUND(?result) ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-01.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-01.rq new file mode 100644 index 00000000..c7bf15a9 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-01.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[]"^^cdt:List <= "[ ]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-02.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-02.rq new file mode 100644 index 00000000..fe6a120b --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-02.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[]"^^cdt:List <= "[1]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-03.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-03.rq new file mode 100644 index 00000000..fc4b5623 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-03.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[1]"^^cdt:List <= "[]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-04.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-04.rq new file mode 100644 index 00000000..bfde3249 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-04.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[1]"^^cdt:List <= "[ 1 ]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-05.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-05.rq new file mode 100644 index 00000000..263348cc --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-05.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[1]"^^cdt:List <= "[2]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-06.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-06.rq new file mode 100644 index 00000000..0b34d18f --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-06.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[2]"^^cdt:List <= "[1]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-07.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-07.rq new file mode 100644 index 00000000..6bbf34c5 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-07.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[1,2]"^^cdt:List <= "[1,3]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-08.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-08.rq new file mode 100644 index 00000000..98eeb7b0 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-08.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[1,3]"^^cdt:List <= "[1,2]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-09.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-09.rq new file mode 100644 index 00000000..696948dd --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-09.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[1,2]"^^cdt:List <= "[1,2,3]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-10.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-10.rq new file mode 100644 index 00000000..3dda8d1d --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-10.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[1,2,3]"^^cdt:List <= "[1,2]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-11.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-11.rq new file mode 100644 index 00000000..5afc428c --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-11.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[1,1,2]"^^cdt:List <= "[1,2,3]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-12.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-12.rq new file mode 100644 index 00000000..5b1f702a --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-12.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[1,2,3]"^^cdt:List <= "[1,1,2]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-13.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-13.rq new file mode 100644 index 00000000..8152ba06 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-13.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[1,1,1]"^^cdt:List <= "[1,2]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-14.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-14.rq new file mode 100644 index 00000000..c9494d4f --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-14.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[1,2]"^^cdt:List <= "[1,1,1]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-15.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-15.rq new file mode 100644 index 00000000..b7b6e7b6 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-15.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[true]"^^cdt:List <= "[false]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-16.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-16.rq new file mode 100644 index 00000000..7f05a329 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-16.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[false]"^^cdt:List <= "[true]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-19.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-19.rq new file mode 100644 index 00000000..2b6b3f88 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-19.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[1,false]"^^cdt:List <= "[1,true]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-20.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-20.rq new file mode 100644 index 00000000..a20d7ede --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-20.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[1,true]"^^cdt:List <= "[1,false]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-21.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-21.rq new file mode 100644 index 00000000..24750063 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-21.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[1,false,2]"^^cdt:List <= "[1,true,1]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-22.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-22.rq new file mode 100644 index 00000000..63cc444d --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-22.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[1,true,1]"^^cdt:List <= "[1,false,2]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-23.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-23.rq new file mode 100644 index 00000000..e73130ed --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-23.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[1,false,true]"^^cdt:List <= "[1,true]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-24.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-24.rq new file mode 100644 index 00000000..d95dc680 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-24.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[1,true]"^^cdt:List <= "[1,false,true]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-25.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-25.rq new file mode 100644 index 00000000..c2136e74 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-25.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[_:b]"^^cdt:List <= "[]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-26.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-26.rq new file mode 100644 index 00000000..31fdfeee --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-26.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[]"^^cdt:List <= "[_:b]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-27.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-27.rq new file mode 100644 index 00000000..8bb4fa6f --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-27.rq @@ -0,0 +1,9 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( BNODE() AS ?x ) + BIND( BNODE() AS ?y ) + BIND( ( cdt:List(?x) <= cdt:List(?y) ) AS ?result ) + FILTER( ! BOUND(?result) ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-28.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-28.rq new file mode 100644 index 00000000..452f1481 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-28.rq @@ -0,0 +1,7 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[_:b]"^^cdt:List <= "[_:b]"^^cdt:List ) AS ?result ) + FILTER( ! BOUND(?result) ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-29.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-29.rq new file mode 100644 index 00000000..9240476d --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-29.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( BNODE() AS ?x ) + BIND( ( cdt:List(?x) <= cdt:List(?x) ) AS ?result ) + FILTER( ! BOUND(?result) ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-31.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-31.rq new file mode 100644 index 00000000..a7ac105f --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-31.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[]"^^cdt:List <= "[ ]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-error-03.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-error-03.rq new file mode 100644 index 00000000..6cd0ea6a --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-error-03.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( cdt:List(2) AS ?list2 ) + BIND( ( "1"^^cdt:List <= ?list2 ) AS ?result ) + FILTER( ! BOUND(?result) ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-error-04.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-error-04.rq new file mode 100644 index 00000000..bcea3634 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-error-04.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( cdt:List(1) AS ?list1 ) + BIND( ( ?list1 <= "2"^^cdt:List ) AS ?result ) + FILTER( ! BOUND(?result) ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-null-01.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-null-01.rq new file mode 100644 index 00000000..99ea40a1 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-null-01.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[null]"^^cdt:List <= "[]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-null-02.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-null-02.rq new file mode 100644 index 00000000..315af88e --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-null-02.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[]"^^cdt:List <= "[null]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-null-03.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-null-03.rq new file mode 100644 index 00000000..d26f3c43 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-null-03.rq @@ -0,0 +1,9 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[null]"^^cdt:List <= "[ null ]"^^cdt:List ) AS ?result ) + + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-null-04.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-null-04.rq new file mode 100644 index 00000000..9f234743 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-null-04.rq @@ -0,0 +1,11 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( cdt:List(?x, ?y) AS ?list1 ) + BIND( cdt:List(?z) AS ?list2 ) + BIND( ( ?list1 <= ?list2 ) AS ?result) + + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-null-05.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-null-05.rq new file mode 100644 index 00000000..d48a2c8f --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-null-05.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[1,null]"^^cdt:List <= "[2,null]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-null-06.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-null-06.rq new file mode 100644 index 00000000..873d0f08 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-less-equal-null-06.rq @@ -0,0 +1,9 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( cdt:List(?x) AS ?list1 ) + BIND( cdt:List(BNODE()) AS ?list2 ) + BIND( ( ?list1 <= ?list2 ) AS ?result ) + FILTER( ! BOUND(?result) ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-01.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-01.rq new file mode 100644 index 00000000..015346b0 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-01.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[]"^^cdt:List < "[ ]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-02.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-02.rq new file mode 100644 index 00000000..9b308f1d --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-02.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[]"^^cdt:List < "[1]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-03.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-03.rq new file mode 100644 index 00000000..6aa465d8 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-03.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[1]"^^cdt:List < "[]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-04.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-04.rq new file mode 100644 index 00000000..bf68893b --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-04.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[ 1 ]"^^cdt:List < "[1]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-05.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-05.rq new file mode 100644 index 00000000..483db5c7 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-05.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[1]"^^cdt:List < "[2]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-06.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-06.rq new file mode 100644 index 00000000..986db126 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-06.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[2]"^^cdt:List < "[1]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-07.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-07.rq new file mode 100644 index 00000000..5c07e9cd --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-07.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[1,2]"^^cdt:List < "[1,3]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-08.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-08.rq new file mode 100644 index 00000000..d3486828 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-08.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[1,3]"^^cdt:List < "[1,2]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-09.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-09.rq new file mode 100644 index 00000000..12849092 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-09.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[1,2]"^^cdt:List < "[1,2,3]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-10.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-10.rq new file mode 100644 index 00000000..8125c2f6 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-10.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[1,2,3]"^^cdt:List < "[1,2]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-11.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-11.rq new file mode 100644 index 00000000..46076dba --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-11.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[1,1,2]"^^cdt:List < "[1,2,3]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-12.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-12.rq new file mode 100644 index 00000000..1901a319 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-12.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[1,2,3]"^^cdt:List < "[1,1,2]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-13.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-13.rq new file mode 100644 index 00000000..237779e1 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-13.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[1,1,1]"^^cdt:List < "[1,2]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-14.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-14.rq new file mode 100644 index 00000000..8bc915fb --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-14.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[1,2]"^^cdt:List < "[1,1,1]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-15.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-15.rq new file mode 100644 index 00000000..ad5d0c55 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-15.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[true]"^^cdt:List < "[false]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-16.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-16.rq new file mode 100644 index 00000000..7b2dc2f5 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-16.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[false]"^^cdt:List < "[true]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-19.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-19.rq new file mode 100644 index 00000000..7092cde5 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-19.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[1,false]"^^cdt:List < "[1,true]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-20.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-20.rq new file mode 100644 index 00000000..52a449a1 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-20.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[1,true]"^^cdt:List < "[1,false]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-21.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-21.rq new file mode 100644 index 00000000..1b5193ce --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-21.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[1,false,2]"^^cdt:List < "[1,true,1]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-22.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-22.rq new file mode 100644 index 00000000..844b3466 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-22.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[1,true,1]"^^cdt:List < "[1,false,2]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-23.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-23.rq new file mode 100644 index 00000000..ed01b6f6 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-23.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[1,false,true]"^^cdt:List < "[1,true]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-24.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-24.rq new file mode 100644 index 00000000..8b64322a --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-24.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[1,true]"^^cdt:List < "[1,false,true]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-25.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-25.rq new file mode 100644 index 00000000..2a58b286 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-25.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[_:b]"^^cdt:List < "[]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-26.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-26.rq new file mode 100644 index 00000000..b07c7ce7 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-26.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[]"^^cdt:List < "[_:b]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-27.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-27.rq new file mode 100644 index 00000000..a64437ae --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-27.rq @@ -0,0 +1,9 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( BNODE() AS ?x ) + BIND( BNODE() AS ?y ) + BIND( ( cdt:List(?x) < cdt:List(?y) ) AS ?result ) + FILTER( ! BOUND(?result) ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-28.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-28.rq new file mode 100644 index 00000000..f0c06258 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-28.rq @@ -0,0 +1,7 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[_:b]"^^cdt:List < "[_:b]"^^cdt:List ) AS ?result ) + FILTER( ! BOUND(?result) ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-29.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-29.rq new file mode 100644 index 00000000..366a422d --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-29.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( BNODE() AS ?x ) + BIND( ( cdt:List(?x) < cdt:List(?x) ) AS ?result ) + FILTER( ! BOUND(?result) ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-31.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-31.rq new file mode 100644 index 00000000..cd2c36ca --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-31.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[ ]"^^cdt:List < "[]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-error-03.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-error-03.rq new file mode 100644 index 00000000..2f889ce9 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-error-03.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( cdt:List(2) AS ?list2 ) + BIND( ( "1"^^cdt:List < ?list2 ) AS ?result ) + FILTER( ! BOUND(?result) ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-error-04.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-error-04.rq new file mode 100644 index 00000000..9f3e6207 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-error-04.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( cdt:List(1) AS ?list1 ) + BIND( ( ?list1 < "2"^^cdt:List ) AS ?result ) + FILTER( ! BOUND(?result) ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-null-01.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-null-01.rq new file mode 100644 index 00000000..d734a727 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-null-01.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[null]"^^cdt:List < "[]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-null-02.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-null-02.rq new file mode 100644 index 00000000..7821aa35 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-null-02.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[]"^^cdt:List < "[null]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-null-03.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-null-03.rq new file mode 100644 index 00000000..5603303d --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-null-03.rq @@ -0,0 +1,9 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[ null ]"^^cdt:List < "[null]"^^cdt:List ) AS ?result ) + + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-null-04.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-null-04.rq new file mode 100644 index 00000000..1f858de7 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-null-04.rq @@ -0,0 +1,11 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( cdt:List(?x, ?y) AS ?list1 ) + BIND( cdt:List(?z) AS ?list2 ) + BIND( ( ?list1 < ?list2 ) AS ?result) + + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-null-05.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-null-05.rq new file mode 100644 index 00000000..775245cd --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-null-05.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "[1,null]"^^cdt:List < "[2,null]"^^cdt:List ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-null-06.rq b/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-null-06.rq new file mode 100644 index 00000000..d488c08e --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/list-less-than-null-06.rq @@ -0,0 +1,9 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( cdt:List(?x) AS ?list1 ) + BIND( cdt:List(BNODE()) AS ?list2 ) + BIND( ( ?list1 < ?list2 ) AS ?result ) + FILTER( ! BOUND(?result) ) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/manifest.ttl b/src/test/resources/sparql-cdts/tests/list-functions/manifest.ttl new file mode 100644 index 00000000..9347cc46 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/manifest.ttl @@ -0,0 +1,3226 @@ +@prefix rdf: . +@prefix : . +@prefix rdfs: . +@prefix mf: . +@prefix qt: . +@prefix dawgt: . +@prefix sparql: . +@prefix cdt: . + +<> rdf:type mf:Manifest ; + rdfs:label "Functions for cdt:List Literals" ; + mf:entries + ( + :list-constructor-01 + :list-constructor-02 + :list-constructor-03 + :list-constructor-04 + :list-constructor-05 + :list-constructor-06 + :list-constructor-09 + :list-constructor-10 + :list-constructor-11 + :list-constructor-12 + :list-constructor-13 + :list-constructor-14 + :list-constructor-15 + :list-constructor-16 + + :concat-01 + :concat-02 + :concat-03 + :concat-04 + :concat-05 + :concat-06 + :concat-07 + :concat-08 + :concat-09 + :concat-10 + + :contains-01 + :contains-02 + :contains-03 + :contains-04 + :contains-05 + :contains-06 + :contains-07 + :contains-08 + :contains-09 + :contains-10 + + :get-01 + :get-02 + :get-03 + :get-04 + :get-05 + :get-06 + :get-07 + :get-08 + :get-09 + :get-10 + :get-11 + :get-12 + :get-13 + + :head-01 + :head-02 + :head-03 + :head-04 + :head-05 + :head-06 + :head-07 + :head-08 + :head-09 + :head-10 + :head-11 + :head-12 + + :tail-01 + :tail-02 + :tail-03 + :tail-04 + :tail-05 + :tail-06 + :tail-07 + :tail-08 + :tail-09 + :tail-10 + + :reverse-01 + :reverse-02 + :reverse-03 + :reverse-04 + :reverse-05 + :reverse-06 + :reverse-07 + :reverse-08 + :reverse-09 + :reverse-10 + + :size-01 + :size-02 + :size-03 + :size-04 + :size-05 + :size-06 + :size-07 + :size-08 + :size-09 + :size-10 + :size-11 + :size-12 + + :subseq-01 + :subseq-02 + :subseq-03 + :subseq-04 + :subseq-05 + :subseq-06 + :subseq-07 + :subseq-08 + :subseq-09 + :subseq-10 + :subseq-11 + :subseq-12 + :subseq-13 + + # Null-values + + :list-constructor-null-01 + :list-constructor-null-02 + :concat-null-01 + :contains-null-01 + :get-null-01 + :get-null-02 + :head-null-01 + :head-null-02 + + # Errors + :get-error-01 # non-list argument + :get-error-02 # invalid index (greater than size) + :get-error-03 # invalid index (zero) + :get-error-04 # invalid index (negative) + :get-error-05 # (non-integer) string index + :get-error-06 # (non-integer) decimal index + :subseq-error-01 # non-list argument + :subseq-error-02 # non-integer index + :concat-error-01 # non-list argument + :concat-error-02 # non-list argument + :contains-error-01 # non-list argument + :head-error-01 # non-list argument + :tail-error-01 # non-list argument + :reverse-error-01 # non-list argument + :size-error-01 # non-list argument + + # Equality Tests for Lists + :list-equals-01 # empty list + :list-equals-02 # single-element + :list-equals-03 # multiple-element + :list-equals-04 # multiple-element, value-space comparison + :list-equals-05 # same IRI + :list-equals-06 # blank nodes + :list-equals-07 # blank nodes + :list-equals-08 # blank nodes + :list-equals-09 # blank nodes + :list-equals-null-01 + :list-equals-null-02 + + # Comparison Tests for Lists + :list-less-than-01 + :list-less-than-02 + :list-less-than-03 + :list-less-than-04 + :list-less-than-05 + :list-less-than-06 + :list-less-than-07 + :list-less-than-08 + :list-less-than-09 + :list-less-than-10 + :list-less-than-11 + :list-less-than-12 + :list-less-than-13 + :list-less-than-14 + :list-less-than-15 + :list-less-than-16 + :list-less-than-19 + :list-less-than-20 + :list-less-than-21 + :list-less-than-22 + :list-less-than-23 + :list-less-than-24 + :list-less-than-25 + :list-less-than-26 + :list-less-than-27 + :list-less-than-28 + :list-less-than-29 + :list-less-than-31 + :list-less-than-null-01 + :list-less-than-null-02 + :list-less-than-null-03 + :list-less-than-null-04 + :list-less-than-null-05 + :list-less-than-null-06 + :list-less-than-error-03 + :list-less-than-error-04 + :list-less-equal-01 + :list-less-equal-02 + :list-less-equal-03 + :list-less-equal-04 + :list-less-equal-05 + :list-less-equal-06 + :list-less-equal-07 + :list-less-equal-08 + :list-less-equal-09 + :list-less-equal-10 + :list-less-equal-11 + :list-less-equal-12 + :list-less-equal-13 + :list-less-equal-14 + :list-less-equal-15 + :list-less-equal-16 + :list-less-equal-19 + :list-less-equal-20 + :list-less-equal-21 + :list-less-equal-22 + :list-less-equal-23 + :list-less-equal-24 + :list-less-equal-25 + :list-less-equal-26 + :list-less-equal-27 + :list-less-equal-28 + :list-less-equal-29 + :list-less-equal-31 + :list-less-equal-null-01 + :list-less-equal-null-02 + :list-less-equal-null-03 + :list-less-equal-null-04 + :list-less-equal-null-05 + :list-less-equal-null-06 + :list-less-equal-error-03 + :list-less-equal-error-04 + :list-greater-than-01 + :list-greater-than-02 + :list-greater-than-03 + :list-greater-than-04 + :list-greater-than-05 + :list-greater-than-06 + :list-greater-than-07 + :list-greater-than-08 + :list-greater-than-09 + :list-greater-than-10 + :list-greater-than-11 + :list-greater-than-12 + :list-greater-than-13 + :list-greater-than-14 + :list-greater-than-15 + :list-greater-than-16 + :list-greater-than-19 + :list-greater-than-20 + :list-greater-than-21 + :list-greater-than-22 + :list-greater-than-23 + :list-greater-than-24 + :list-greater-than-25 + :list-greater-than-26 + :list-greater-than-27 + :list-greater-than-28 + :list-greater-than-29 + :list-greater-than-31 + :list-greater-than-null-01 + :list-greater-than-null-02 + :list-greater-than-null-03 + :list-greater-than-null-04 + :list-greater-than-null-05 + :list-greater-than-null-06 + :list-greater-than-error-03 + :list-greater-than-error-04 + :list-greater-equal-01 + :list-greater-equal-02 + :list-greater-equal-03 + :list-greater-equal-04 + :list-greater-equal-05 + :list-greater-equal-06 + :list-greater-equal-07 + :list-greater-equal-08 + :list-greater-equal-09 + :list-greater-equal-10 + :list-greater-equal-11 + :list-greater-equal-12 + :list-greater-equal-13 + :list-greater-equal-14 + :list-greater-equal-15 + :list-greater-equal-16 + :list-greater-equal-19 + :list-greater-equal-20 + :list-greater-equal-21 + :list-greater-equal-22 + :list-greater-equal-23 + :list-greater-equal-24 + :list-greater-equal-25 + :list-greater-equal-26 + :list-greater-equal-27 + :list-greater-equal-28 + :list-greater-equal-29 + :list-greater-equal-31 + :list-greater-equal-null-01 + :list-greater-equal-null-02 + :list-greater-equal-null-03 + :list-greater-equal-null-04 + :list-greater-equal-null-05 + :list-greater-equal-null-06 + :list-greater-equal-error-03 + :list-greater-equal-error-04 + + # sameTerm Tests for Lists + :sameterm-01 # empty list + :sameterm-02 # single-element + :sameterm-03 # multiple-element + :sameterm-04 # multiple-element, different lexical-space, same value-space elements (!sameTerm) + :sameterm-null-01 # list with null (allowed since the test is on the list lexical, not the elements) + ) . + +:list-constructor-01 rdf:type mf:QueryEvaluationTest ; + mf:name "list-constructor-01" ; + rdfs:comment "construct an empty list" ; + mf:feature cdt:list-constructor ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-constructor-02 rdf:type mf:QueryEvaluationTest ; + mf:name "list-constructor-02" ; + rdfs:comment "construct a list with a single integer element" ; + mf:feature cdt:list-constructor ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-constructor-03 rdf:type mf:QueryEvaluationTest ; + mf:name "list-constructor-03" ; + rdfs:comment "construct a list with two integer elements" ; + mf:feature cdt:list-constructor ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-constructor-04 rdf:type mf:QueryEvaluationTest ; + mf:name "list-constructor-04" ; + rdfs:comment "construct a list with a single string element" ; + mf:feature cdt:list-constructor ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-constructor-05 rdf:type mf:QueryEvaluationTest ; + mf:name "list-constructor-05" ; + rdfs:comment "construct a list with two string elements" ; + mf:feature cdt:list-constructor ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-constructor-06 rdf:type mf:QueryEvaluationTest ; + mf:name "list-constructor-06" ; + rdfs:comment "construct a list with two elements of differing type" ; + mf:feature cdt:list-constructor ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-constructor-09 rdf:type mf:QueryEvaluationTest ; + mf:name "list-constructor-09" ; + rdfs:comment "construct a list with a nested, empty list element" ; + mf:feature cdt:list-constructor ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-constructor-10 rdf:type mf:QueryEvaluationTest ; + mf:name "list-constructor-10" ; + rdfs:comment "construct a list with a nested list with a single integer element" ; + mf:feature cdt:list-constructor ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-constructor-11 rdf:type mf:QueryEvaluationTest ; + mf:name "list-constructor-11" ; + rdfs:comment "construct a list with two elements of different type, one being a nested list" ; + mf:feature cdt:list-constructor ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-constructor-12 rdf:type mf:QueryEvaluationTest ; + mf:name "list-constructor-12" ; + rdfs:comment "construct a list with two elements of different type, one being a null element produced by unbound variable error" ; + mf:feature cdt:list-constructor ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-constructor-13 rdf:type mf:QueryEvaluationTest ; + mf:name "list-constructor-13" ; + rdfs:comment "construct two equal lists, one by list constructor and the other by literal syntax" ; + mf:feature cdt:list-constructor ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-constructor-14 rdf:type mf:QueryEvaluationTest ; + mf:name "list-constructor-14" ; + rdfs:comment "construct a list using STRDT" ; + mf:feature cdt:list-constructor ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-constructor-15 rdf:type mf:QueryEvaluationTest ; + mf:name "list-constructor-15" ; + rdfs:comment "construct a list with two integer elements that are the results of evaluating sub-expression including operators" ; + mf:feature cdt:list-constructor ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-constructor-16 rdf:type mf:QueryEvaluationTest ; + mf:name "list-constructor-16" ; + rdfs:comment "construct a list with a blank node and check that the identity of the blank node is preserved" ; + mf:feature cdt:list-constructor ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:concat-01 rdf:type mf:QueryEvaluationTest ; + mf:name "concat-01" ; + mf:feature cdt:concat ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:concat-02 rdf:type mf:QueryEvaluationTest ; + mf:name "concat-02" ; + mf:feature cdt:concat ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:concat-03 rdf:type mf:QueryEvaluationTest ; + mf:name "concat-03" ; + mf:feature cdt:concat ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:concat-04 rdf:type mf:QueryEvaluationTest ; + mf:name "concat-04" ; + mf:feature cdt:concat ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:concat-05 rdf:type mf:QueryEvaluationTest ; + mf:name "concat-05" ; + mf:feature cdt:concat ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:concat-06 rdf:type mf:QueryEvaluationTest ; + mf:name "concat-06" ; + mf:feature cdt:concat ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:concat-07 rdf:type mf:QueryEvaluationTest ; + mf:name "concat-07" ; + mf:feature cdt:concat ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:concat-08 rdf:type mf:QueryEvaluationTest ; + mf:name "concat-08" ; + mf:feature cdt:concat ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:concat-09 rdf:type mf:QueryEvaluationTest ; + mf:name "concat-09" ; + mf:feature cdt:concat ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:concat-10 rdf:type mf:QueryEvaluationTest ; + mf:name "concat-10" ; + mf:feature cdt:concat ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:contains-01 rdf:type mf:QueryEvaluationTest ; + mf:name "contains-01" ; + mf:feature cdt:contains ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:contains-02 rdf:type mf:QueryEvaluationTest ; + mf:name "contains-02" ; + mf:feature cdt:contains ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:contains-03 rdf:type mf:QueryEvaluationTest ; + mf:name "contains-03" ; + mf:feature cdt:contains ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:contains-04 rdf:type mf:QueryEvaluationTest ; + mf:name "contains-04" ; + mf:feature cdt:contains ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:contains-05 rdf:type mf:QueryEvaluationTest ; + mf:name "contains-05" ; + mf:feature cdt:contains ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:contains-06 rdf:type mf:QueryEvaluationTest ; + mf:name "contains-06" ; + mf:feature cdt:contains ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:contains-07 rdf:type mf:QueryEvaluationTest ; + mf:name "contains-07" ; + mf:feature cdt:contains ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:contains-08 rdf:type mf:QueryEvaluationTest ; + mf:name "contains-08" ; + mf:feature cdt:contains ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:contains-09 rdf:type mf:QueryEvaluationTest ; + mf:name "contains-09" ; + mf:feature cdt:contains ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:contains-10 rdf:type mf:QueryEvaluationTest ; + mf:name "contains-10" ; + mf:feature cdt:contains ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:get-01 rdf:type mf:QueryEvaluationTest ; + mf:name "get-01" ; + mf:feature cdt:get ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:get-02 rdf:type mf:QueryEvaluationTest ; + mf:name "get-02" ; + mf:feature cdt:get ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:get-03 rdf:type mf:QueryEvaluationTest ; + mf:name "get-03" ; + mf:feature cdt:get ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:get-04 rdf:type mf:QueryEvaluationTest ; + mf:name "get-04" ; + mf:feature cdt:get ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:get-05 rdf:type mf:QueryEvaluationTest ; + mf:name "get-05" ; + mf:feature cdt:get ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:get-06 rdf:type mf:QueryEvaluationTest ; + mf:name "get-06" ; + mf:feature cdt:get ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:get-07 rdf:type mf:QueryEvaluationTest ; + mf:name "get-07" ; + mf:feature cdt:get ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:get-08 rdf:type mf:QueryEvaluationTest ; + mf:name "get-08" ; + mf:feature cdt:get ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:get-09 rdf:type mf:QueryEvaluationTest ; + mf:name "get-09" ; + mf:feature cdt:get ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:get-10 rdf:type mf:QueryEvaluationTest ; + mf:name "get-10" ; + mf:feature cdt:get ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:get-11 rdf:type mf:QueryEvaluationTest ; + mf:name "get-11" ; + mf:feature cdt:get ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:get-12 rdf:type mf:QueryEvaluationTest ; + mf:name "get-12" ; + mf:feature cdt:get ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:get-13 rdf:type mf:QueryEvaluationTest ; + mf:name "get-13" ; + mf:feature cdt:get ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:head-01 rdf:type mf:QueryEvaluationTest ; + mf:name "head-01" ; + mf:feature cdt:head ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:head-02 rdf:type mf:QueryEvaluationTest ; + mf:name "head-02" ; + mf:feature cdt:head ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:head-03 rdf:type mf:QueryEvaluationTest ; + mf:name "head-03" ; + mf:feature cdt:head ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:head-04 rdf:type mf:QueryEvaluationTest ; + mf:name "head-04" ; + mf:feature cdt:head ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:head-05 rdf:type mf:QueryEvaluationTest ; + mf:name "head-05" ; + mf:feature cdt:head ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:head-06 rdf:type mf:QueryEvaluationTest ; + mf:name "head-06" ; + mf:feature cdt:head ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:head-07 rdf:type mf:QueryEvaluationTest ; + mf:name "head-07" ; + mf:feature cdt:head ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:head-08 rdf:type mf:QueryEvaluationTest ; + mf:name "head-08" ; + mf:feature cdt:head ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:head-09 rdf:type mf:QueryEvaluationTest ; + mf:name "head-09" ; + mf:feature cdt:head ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:head-10 rdf:type mf:QueryEvaluationTest ; + mf:name "head-10" ; + mf:feature cdt:head ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:head-11 rdf:type mf:QueryEvaluationTest ; + mf:name "head-11" ; + mf:feature cdt:head ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:head-12 rdf:type mf:QueryEvaluationTest ; + mf:name "head-12" ; + mf:feature cdt:head ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:tail-01 rdf:type mf:QueryEvaluationTest ; + mf:name "tail-01" ; + mf:feature cdt:tail ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:tail-02 rdf:type mf:QueryEvaluationTest ; + mf:name "tail-02" ; + mf:feature cdt:tail ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:tail-03 rdf:type mf:QueryEvaluationTest ; + mf:name "tail-03" ; + mf:feature cdt:tail ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:tail-04 rdf:type mf:QueryEvaluationTest ; + mf:name "tail-04" ; + mf:feature cdt:tail ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:tail-05 rdf:type mf:QueryEvaluationTest ; + mf:name "tail-05" ; + mf:feature cdt:tail ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:tail-06 rdf:type mf:QueryEvaluationTest ; + mf:name "tail-06" ; + mf:feature cdt:tail ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:tail-07 rdf:type mf:QueryEvaluationTest ; + mf:name "tail-07" ; + mf:feature cdt:tail ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:tail-08 rdf:type mf:QueryEvaluationTest ; + mf:name "tail-08" ; + mf:feature cdt:tail ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:tail-09 rdf:type mf:QueryEvaluationTest ; + mf:name "tail-09" ; + mf:feature cdt:tail ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:tail-10 rdf:type mf:QueryEvaluationTest ; + mf:name "tail-10" ; + mf:feature cdt:tail ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:reverse-01 rdf:type mf:QueryEvaluationTest ; + mf:name "reverse-01" ; + mf:feature cdt:reverse ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:reverse-02 rdf:type mf:QueryEvaluationTest ; + mf:name "reverse-02" ; + mf:feature cdt:reverse ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:reverse-03 rdf:type mf:QueryEvaluationTest ; + mf:name "reverse-03" ; + mf:feature cdt:reverse ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:reverse-04 rdf:type mf:QueryEvaluationTest ; + mf:name "reverse-04" ; + mf:feature cdt:reverse ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:reverse-05 rdf:type mf:QueryEvaluationTest ; + mf:name "reverse-05" ; + mf:feature cdt:reverse ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:reverse-06 rdf:type mf:QueryEvaluationTest ; + mf:name "reverse-06" ; + mf:feature cdt:reverse ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:reverse-07 rdf:type mf:QueryEvaluationTest ; + mf:name "reverse-07" ; + mf:feature cdt:reverse ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:reverse-08 rdf:type mf:QueryEvaluationTest ; + mf:name "reverse-08" ; + mf:feature cdt:reverse ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:reverse-09 rdf:type mf:QueryEvaluationTest ; + mf:name "reverse-09" ; + mf:feature cdt:reverse ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:reverse-10 rdf:type mf:QueryEvaluationTest ; + mf:name "reverse-10" ; + mf:feature cdt:reverse ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:size-01 rdf:type mf:QueryEvaluationTest ; + mf:name "size-01" ; + mf:feature cdt:size ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:size-02 rdf:type mf:QueryEvaluationTest ; + mf:name "size-02" ; + mf:feature cdt:size ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:size-03 rdf:type mf:QueryEvaluationTest ; + mf:name "size-03" ; + mf:feature cdt:size ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:size-04 rdf:type mf:QueryEvaluationTest ; + mf:name "size-04" ; + mf:feature cdt:size ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:size-05 rdf:type mf:QueryEvaluationTest ; + mf:name "size-05" ; + mf:feature cdt:size ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:size-06 rdf:type mf:QueryEvaluationTest ; + mf:name "size-06" ; + mf:feature cdt:size ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:size-07 rdf:type mf:QueryEvaluationTest ; + mf:name "size-07" ; + mf:feature cdt:size ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:size-08 rdf:type mf:QueryEvaluationTest ; + mf:name "size-08" ; + mf:feature cdt:size ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:size-09 rdf:type mf:QueryEvaluationTest ; + mf:name "size-09" ; + mf:feature cdt:size ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:size-10 rdf:type mf:QueryEvaluationTest ; + mf:name "size-10" ; + mf:feature cdt:size ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:size-11 rdf:type mf:QueryEvaluationTest ; + mf:name "size-11" ; + mf:feature cdt:size ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:size-12 rdf:type mf:QueryEvaluationTest ; + mf:name "size-12" ; + mf:feature cdt:size ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:subseq-01 rdf:type mf:QueryEvaluationTest ; + mf:name "subseq-01" ; + mf:feature cdt:subseq ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:subseq-02 rdf:type mf:QueryEvaluationTest ; + mf:name "subseq-02" ; + mf:feature cdt:subseq ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:subseq-03 rdf:type mf:QueryEvaluationTest ; + mf:name "subseq-03" ; + mf:feature cdt:subseq ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:subseq-04 rdf:type mf:QueryEvaluationTest ; + mf:name "subseq-04" ; + mf:feature cdt:subseq ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:subseq-05 rdf:type mf:QueryEvaluationTest ; + mf:name "subseq-05" ; + mf:feature cdt:subseq ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:subseq-06 rdf:type mf:QueryEvaluationTest ; + mf:name "subseq-06" ; + mf:feature cdt:subseq ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:subseq-07 rdf:type mf:QueryEvaluationTest ; + mf:name "subseq-07" ; + mf:feature cdt:subseq ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:subseq-08 rdf:type mf:QueryEvaluationTest ; + mf:name "subseq-08" ; + mf:feature cdt:subseq ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:subseq-09 rdf:type mf:QueryEvaluationTest ; + mf:name "subseq-09" ; + mf:feature cdt:subseq ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:subseq-10 rdf:type mf:QueryEvaluationTest ; + mf:name "subseq-10" ; + mf:feature cdt:subseq ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:subseq-11 rdf:type mf:QueryEvaluationTest ; + mf:name "subseq-11" ; + mf:feature cdt:subseq ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:subseq-12 rdf:type mf:QueryEvaluationTest ; + mf:name "subseq-12" ; + mf:feature cdt:subseq ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:subseq-13 rdf:type mf:QueryEvaluationTest ; + mf:name "subseq-13" ; + mf:feature cdt:subseq ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-constructor-null-01 rdf:type mf:QueryEvaluationTest ; + mf:name "list-constructor-null-01" ; + rdfs:comment "list constructor on null argument" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-constructor-null-02 rdf:type mf:QueryEvaluationTest ; + mf:name "list-constructor-null-02" ; + rdfs:comment "construct a list one null element produced by expression evaluation error" ; + mf:feature cdt:list-constructor ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:concat-null-01 rdf:type mf:QueryEvaluationTest ; + mf:name "concat-null-01" ; + rdfs:comment "concat with null" ; + mf:feature cdt:concat ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:contains-null-01 rdf:type mf:QueryEvaluationTest ; + mf:name "contains-null-01" ; + rdfs:comment "contains over list containing null" ; + mf:feature cdt:contains ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:get-null-01 rdf:type mf:QueryEvaluationTest ; + mf:name "get-null-01" ; + rdfs:comment "get returning null" ; + mf:feature cdt:get ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:get-null-02 rdf:type mf:QueryEvaluationTest ; + mf:name "get-null-02" ; + rdfs:comment "get on empty list" ; + mf:feature cdt:get ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:head-null-01 rdf:type mf:QueryEvaluationTest ; + mf:name "head-null-01" ; + rdfs:comment "head returning null" ; + mf:feature cdt:head ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:head-null-02 rdf:type mf:QueryEvaluationTest ; + mf:name "head-null-02" ; + rdfs:comment "head on empty list" ; + mf:feature cdt:head ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:get-error-01 rdf:type mf:QueryEvaluationTest ; + mf:name "get-error-01" ; + rdfs:comment "get on invalid index" ; + mf:feature cdt:get ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:get-error-02 rdf:type mf:QueryEvaluationTest ; + mf:name "get-error-02" ; + rdfs:comment "get with non-integer index" ; + mf:feature cdt:get ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:get-error-03 rdf:type mf:QueryEvaluationTest ; + mf:name "get-error-03" ; + rdfs:comment "get with non-list argument" ; + mf:feature cdt:get ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:get-error-04 rdf:type mf:QueryEvaluationTest ; + mf:name "get-error-04" ; + rdfs:comment "get with non-list argument" ; + mf:feature cdt:get ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:get-error-05 rdf:type mf:QueryEvaluationTest ; + mf:name "get-error-05" ; + rdfs:comment "get with non-list argument" ; + mf:feature cdt:get ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:get-error-06 rdf:type mf:QueryEvaluationTest ; + mf:name "get-error-06" ; + rdfs:comment "get with non-list argument" ; + mf:feature cdt:get ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:subseq-error-01 rdf:type mf:QueryEvaluationTest ; + mf:name "subseq-error-01" ; + rdfs:comment "subseq with non-list argument" ; + mf:feature cdt:subseq ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:subseq-error-02 rdf:type mf:QueryEvaluationTest ; + mf:name "subseq-error-02" ; + rdfs:comment "subseq with non-integer index" ; + mf:feature cdt:subseq ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:concat-error-01 rdf:type mf:QueryEvaluationTest ; + mf:name "concat-error-01" ; + rdfs:comment "concat with non-list argument" ; + mf:feature cdt:concat ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:concat-error-02 rdf:type mf:QueryEvaluationTest ; + mf:name "concat-error-02" ; + rdfs:comment "concat with non-list argument" ; + mf:feature cdt:concat ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:contains-error-01 rdf:type mf:QueryEvaluationTest ; + mf:name "contains-error-01" ; + rdfs:comment "contains with non-list argument" ; + mf:feature cdt:contains ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:head-error-01 rdf:type mf:QueryEvaluationTest ; + mf:name "head-error-01" ; + rdfs:comment "head with non-list argument" ; + mf:feature cdt:head ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:tail-error-01 rdf:type mf:QueryEvaluationTest ; + mf:name "tail-error-01" ; + rdfs:comment "tail with non-list argument" ; + mf:feature cdt:tail ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:reverse-error-01 rdf:type mf:QueryEvaluationTest ; + mf:name "reverse-error-01" ; + rdfs:comment "reverse with non-list argument" ; + mf:feature cdt:reverse ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:size-error-01 rdf:type mf:QueryEvaluationTest ; + mf:name "size-error-01" ; + rdfs:comment "size with non-list argument" ; + mf:feature cdt:size ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-equals-01 rdf:type mf:QueryEvaluationTest ; + mf:name "list-equals-01" ; + rdfs:comment "equals test on empty list" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-equals-02 rdf:type mf:QueryEvaluationTest ; + mf:name "list-equals-02" ; + rdfs:comment "equals test on single-element" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-equals-03 rdf:type mf:QueryEvaluationTest ; + mf:name "list-equals-03" ; + rdfs:comment "equals test on multiple-element" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-equals-04 rdf:type mf:QueryEvaluationTest ; + mf:name "list-equals-04" ; + rdfs:comment "equals test on multiple-element, value-space comparison" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-equals-05 rdf:type mf:QueryEvaluationTest ; + mf:name "list-equals-05" ; + rdfs:comment "equals test on lists with same IRI" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-equals-06 rdf:type mf:QueryEvaluationTest ; + mf:name "list-equals-06" ; + rdfs:comment "equals test on lists with blank nodes" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-equals-07 rdf:type mf:QueryEvaluationTest ; + mf:name "list-equals-07" ; + rdfs:comment "equals test on lists with blank nodes" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-equals-08 rdf:type mf:QueryEvaluationTest ; + mf:name "list-equals-08" ; + rdfs:comment "equals test on lists with blank nodes" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-equals-09 rdf:type mf:QueryEvaluationTest ; + mf:name "list-equals-09" ; + rdfs:comment "equals test on lists with blank nodes" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-equals-null-01 rdf:type mf:QueryEvaluationTest ; + mf:name "list-equals-null-01" ; + rdfs:comment "equality of pairs of null within lists" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-equals-null-02 rdf:type mf:QueryEvaluationTest ; + mf:name "list-equals-null-02" ; + rdfs:comment "null is not equal to any RDF term" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-less-than-01 rdf:type mf:QueryEvaluationTest ; + mf:name "list-less-than-01" ; + rdfs:comment "less-than test on two empty lists" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-less-than-02 rdf:type mf:QueryEvaluationTest ; + mf:name "list-less-than-02" ; + rdfs:comment "less-than test with one empty list" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-less-than-03 rdf:type mf:QueryEvaluationTest ; + mf:name "list-less-than-03" ; + rdfs:comment "less-than test with one empty list" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-less-than-04 rdf:type mf:QueryEvaluationTest ; + mf:name "list-less-than-04" ; + rdfs:comment "less-than test with equal lists" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-less-than-05 rdf:type mf:QueryEvaluationTest ; + mf:name "list-less-than-05" ; + rdfs:comment "less-than test with integers" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-less-than-06 rdf:type mf:QueryEvaluationTest ; + mf:name "list-less-than-06" ; + rdfs:comment "less-than test with integers" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-less-than-07 rdf:type mf:QueryEvaluationTest ; + mf:name "list-less-than-07" ; + rdfs:comment "less-than test with integers" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-less-than-08 rdf:type mf:QueryEvaluationTest ; + mf:name "list-less-than-08" ; + rdfs:comment "less-than test with integers" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-less-than-09 rdf:type mf:QueryEvaluationTest ; + mf:name "list-less-than-09" ; + rdfs:comment "less-than test with integers" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-less-than-10 rdf:type mf:QueryEvaluationTest ; + mf:name "list-less-than-10" ; + rdfs:comment "less-than test with integers" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-less-than-11 rdf:type mf:QueryEvaluationTest ; + mf:name "list-less-than-11" ; + rdfs:comment "less-than test with integers" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-less-than-12 rdf:type mf:QueryEvaluationTest ; + mf:name "list-less-than-12" ; + rdfs:comment "less-than test with integers" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-less-than-13 rdf:type mf:QueryEvaluationTest ; + mf:name "list-less-than-13" ; + rdfs:comment "less-than test with integers" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-less-than-14 rdf:type mf:QueryEvaluationTest ; + mf:name "list-less-than-14" ; + rdfs:comment "less-than test with integers" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-less-than-15 rdf:type mf:QueryEvaluationTest ; + mf:name "list-less-than-15" ; + rdfs:comment "less-than test with booleans" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-less-than-16 rdf:type mf:QueryEvaluationTest ; + mf:name "list-less-than-16" ; + rdfs:comment "less-than test with booleans" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-less-than-19 rdf:type mf:QueryEvaluationTest ; + mf:name "list-less-than-19" ; + rdfs:comment "less-than test with mixed types" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-less-than-20 rdf:type mf:QueryEvaluationTest ; + mf:name "list-less-than-20" ; + rdfs:comment "less-than test with mixed types" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-less-than-21 rdf:type mf:QueryEvaluationTest ; + mf:name "list-less-than-21" ; + rdfs:comment "less-than test with mixed types" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-less-than-22 rdf:type mf:QueryEvaluationTest ; + mf:name "list-less-than-22" ; + rdfs:comment "less-than test with mixed types" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-less-than-23 rdf:type mf:QueryEvaluationTest ; + mf:name "list-less-than-23" ; + rdfs:comment "less-than test with mixed types" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-less-than-24 rdf:type mf:QueryEvaluationTest ; + mf:name "list-less-than-24" ; + rdfs:comment "less-than test with mixed types" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-less-than-25 rdf:type mf:QueryEvaluationTest ; + mf:name "list-less-than-25" ; + rdfs:comment "less-than test with blank nodes" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-less-than-26 rdf:type mf:QueryEvaluationTest ; + mf:name "list-less-than-26" ; + rdfs:comment "less-than test with blank nodes" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-less-than-27 rdf:type mf:QueryEvaluationTest ; + mf:name "list-less-than-27" ; + rdfs:comment "less-than test with blank nodes" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-less-than-28 rdf:type mf:QueryEvaluationTest ; + mf:name "list-less-than-28" ; + rdfs:comment "less-than test with blank nodes" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-less-than-29 rdf:type mf:QueryEvaluationTest ; + mf:name "list-less-than-29" ; + rdfs:comment "less-than test with blank nodes" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-less-than-31 rdf:type mf:QueryEvaluationTest ; + mf:name "list-less-than-31" ; + rdfs:comment "less-than test with IRIs" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-less-than-null-01 rdf:type mf:QueryEvaluationTest ; + mf:name "list-less-than-null-01" ; + rdfs:comment "less-than test with nulls" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-less-than-null-02 rdf:type mf:QueryEvaluationTest ; + mf:name "list-less-than-null-02" ; + rdfs:comment "less-than test with nulls" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-less-than-null-03 rdf:type mf:QueryEvaluationTest ; + mf:name "list-less-than-null-03" ; + rdfs:comment "less-than test with nulls" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-less-than-null-04 rdf:type mf:QueryEvaluationTest ; + mf:name "list-less-than-null-04" ; + rdfs:comment "less-than test with nulls" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-less-than-null-05 rdf:type mf:QueryEvaluationTest ; + mf:name "list-less-than-null-05" ; + rdfs:comment "less-than test with nulls" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-less-than-null-06 rdf:type mf:QueryEvaluationTest ; + mf:name "list-less-than-null-06" ; + rdfs:comment "less-than test with null and blank node" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-less-than-error-03 rdf:type mf:QueryEvaluationTest ; + mf:name "list-less-than-error-03" ; + rdfs:comment "less-than test with ill-formed literal" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-less-than-error-04 rdf:type mf:QueryEvaluationTest ; + mf:name "list-less-than-error-04" ; + rdfs:comment "less-than test with ill-formed literal" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-less-equal-01 rdf:type mf:QueryEvaluationTest ; + mf:name "list-less-equal-01" ; + rdfs:comment "less-equal test on two empty lists" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-less-equal-02 rdf:type mf:QueryEvaluationTest ; + mf:name "list-less-equal-02" ; + rdfs:comment "less-equal test with one empty list" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-less-equal-03 rdf:type mf:QueryEvaluationTest ; + mf:name "list-less-equal-03" ; + rdfs:comment "less-equal test with one empty list" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-less-equal-04 rdf:type mf:QueryEvaluationTest ; + mf:name "list-less-equal-04" ; + rdfs:comment "less-equal test with equal lists" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-less-equal-05 rdf:type mf:QueryEvaluationTest ; + mf:name "list-less-equal-05" ; + rdfs:comment "less-equal test with integers" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-less-equal-06 rdf:type mf:QueryEvaluationTest ; + mf:name "list-less-equal-06" ; + rdfs:comment "less-equal test with integers" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-less-equal-07 rdf:type mf:QueryEvaluationTest ; + mf:name "list-less-equal-07" ; + rdfs:comment "less-equal test with integers" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-less-equal-08 rdf:type mf:QueryEvaluationTest ; + mf:name "list-less-equal-08" ; + rdfs:comment "less-equal test with integers" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-less-equal-09 rdf:type mf:QueryEvaluationTest ; + mf:name "list-less-equal-09" ; + rdfs:comment "less-equal test with integers" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-less-equal-10 rdf:type mf:QueryEvaluationTest ; + mf:name "list-less-equal-10" ; + rdfs:comment "less-equal test with integers" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-less-equal-11 rdf:type mf:QueryEvaluationTest ; + mf:name "list-less-equal-11" ; + rdfs:comment "less-equal test with integers" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-less-equal-12 rdf:type mf:QueryEvaluationTest ; + mf:name "list-less-equal-12" ; + rdfs:comment "less-equal test with integers" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-less-equal-13 rdf:type mf:QueryEvaluationTest ; + mf:name "list-less-equal-13" ; + rdfs:comment "less-equal test with integers" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-less-equal-14 rdf:type mf:QueryEvaluationTest ; + mf:name "list-less-equal-14" ; + rdfs:comment "less-equal test with integers" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-less-equal-15 rdf:type mf:QueryEvaluationTest ; + mf:name "list-less-equal-15" ; + rdfs:comment "less-equal test with booleans" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-less-equal-16 rdf:type mf:QueryEvaluationTest ; + mf:name "list-less-equal-16" ; + rdfs:comment "less-equal test with booleans" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-less-equal-19 rdf:type mf:QueryEvaluationTest ; + mf:name "list-less-equal-19" ; + rdfs:comment "less-equal test with mixed types" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-less-equal-20 rdf:type mf:QueryEvaluationTest ; + mf:name "list-less-equal-20" ; + rdfs:comment "less-equal test with mixed types" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-less-equal-21 rdf:type mf:QueryEvaluationTest ; + mf:name "list-less-equal-21" ; + rdfs:comment "less-equal test with mixed types" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-less-equal-22 rdf:type mf:QueryEvaluationTest ; + mf:name "list-less-equal-22" ; + rdfs:comment "less-equal test with mixed types" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-less-equal-23 rdf:type mf:QueryEvaluationTest ; + mf:name "list-less-equal-23" ; + rdfs:comment "less-equal test with mixed types" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-less-equal-24 rdf:type mf:QueryEvaluationTest ; + mf:name "list-less-equal-24" ; + rdfs:comment "less-equal test with mixed types" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-less-equal-25 rdf:type mf:QueryEvaluationTest ; + mf:name "list-less-equal-25" ; + rdfs:comment "less-equal test with blank nodes" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-less-equal-26 rdf:type mf:QueryEvaluationTest ; + mf:name "list-less-equal-26" ; + rdfs:comment "less-equal test with blank nodes" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-less-equal-27 rdf:type mf:QueryEvaluationTest ; + mf:name "list-less-equal-27" ; + rdfs:comment "less-equal test with blank nodes" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-less-equal-28 rdf:type mf:QueryEvaluationTest ; + mf:name "list-less-equal-28" ; + rdfs:comment "less-equal test with blank nodes" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-less-equal-29 rdf:type mf:QueryEvaluationTest ; + mf:name "list-less-equal-29" ; + rdfs:comment "less-equal test with blank nodes" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-less-equal-31 rdf:type mf:QueryEvaluationTest ; + mf:name "list-less-equal-31" ; + rdfs:comment "less-equal test with IRIs" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-less-equal-null-01 rdf:type mf:QueryEvaluationTest ; + mf:name "list-less-equal-null-01" ; + rdfs:comment "less-equal test with nulls" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-less-equal-null-02 rdf:type mf:QueryEvaluationTest ; + mf:name "list-less-equal-null-02" ; + rdfs:comment "less-equal test with nulls" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-less-equal-null-03 rdf:type mf:QueryEvaluationTest ; + mf:name "list-less-equal-null-03" ; + rdfs:comment "less-equal test with nulls" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-less-equal-null-04 rdf:type mf:QueryEvaluationTest ; + mf:name "list-less-equal-null-04" ; + rdfs:comment "less-equal test with nulls" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-less-equal-null-05 rdf:type mf:QueryEvaluationTest ; + mf:name "list-less-equal-null-05" ; + rdfs:comment "less-equal test with nulls" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-less-equal-null-06 rdf:type mf:QueryEvaluationTest ; + mf:name "list-less-equal-null-06" ; + rdfs:comment "less-equal test with null and blank node" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-less-equal-error-03 rdf:type mf:QueryEvaluationTest ; + mf:name "list-less-equal-error-03" ; + rdfs:comment "less-equal test with ill-formed literal" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-less-equal-error-04 rdf:type mf:QueryEvaluationTest ; + mf:name "list-less-equal-error-04" ; + rdfs:comment "less-equal test with ill-formed literal" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-greater-than-01 rdf:type mf:QueryEvaluationTest ; + mf:name "list-greater-than-01" ; + rdfs:comment "greater-than test on two empty lists" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-greater-than-02 rdf:type mf:QueryEvaluationTest ; + mf:name "list-greater-than-02" ; + rdfs:comment "greater-than test with one empty list" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-greater-than-03 rdf:type mf:QueryEvaluationTest ; + mf:name "list-greater-than-03" ; + rdfs:comment "greater-than test with one empty list" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-greater-than-04 rdf:type mf:QueryEvaluationTest ; + mf:name "list-greater-than-04" ; + rdfs:comment "greater-than test with equal lists" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-greater-than-05 rdf:type mf:QueryEvaluationTest ; + mf:name "list-greater-than-05" ; + rdfs:comment "greater-than test with integers" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-greater-than-06 rdf:type mf:QueryEvaluationTest ; + mf:name "list-greater-than-06" ; + rdfs:comment "greater-than test with integers" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-greater-than-07 rdf:type mf:QueryEvaluationTest ; + mf:name "list-greater-than-07" ; + rdfs:comment "greater-than test with integers" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-greater-than-08 rdf:type mf:QueryEvaluationTest ; + mf:name "list-greater-than-08" ; + rdfs:comment "greater-than test with integers" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-greater-than-09 rdf:type mf:QueryEvaluationTest ; + mf:name "list-greater-than-09" ; + rdfs:comment "greater-than test with integers" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-greater-than-10 rdf:type mf:QueryEvaluationTest ; + mf:name "list-greater-than-10" ; + rdfs:comment "greater-than test with integers" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-greater-than-11 rdf:type mf:QueryEvaluationTest ; + mf:name "list-greater-than-11" ; + rdfs:comment "greater-than test with integers" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-greater-than-12 rdf:type mf:QueryEvaluationTest ; + mf:name "list-greater-than-12" ; + rdfs:comment "greater-than test with integers" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-greater-than-13 rdf:type mf:QueryEvaluationTest ; + mf:name "list-greater-than-13" ; + rdfs:comment "greater-than test with integers" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-greater-than-14 rdf:type mf:QueryEvaluationTest ; + mf:name "list-greater-than-14" ; + rdfs:comment "greater-than test with integers" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-greater-than-15 rdf:type mf:QueryEvaluationTest ; + mf:name "list-greater-than-15" ; + rdfs:comment "greater-than test with booleans" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-greater-than-16 rdf:type mf:QueryEvaluationTest ; + mf:name "list-greater-than-16" ; + rdfs:comment "greater-than test with booleans" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-greater-than-19 rdf:type mf:QueryEvaluationTest ; + mf:name "list-greater-than-19" ; + rdfs:comment "greater-than test with mixed types" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-greater-than-20 rdf:type mf:QueryEvaluationTest ; + mf:name "list-greater-than-20" ; + rdfs:comment "greater-than test with mixed types" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-greater-than-21 rdf:type mf:QueryEvaluationTest ; + mf:name "list-greater-than-21" ; + rdfs:comment "greater-than test with mixed types" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-greater-than-22 rdf:type mf:QueryEvaluationTest ; + mf:name "list-greater-than-22" ; + rdfs:comment "greater-than test with mixed types" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-greater-than-23 rdf:type mf:QueryEvaluationTest ; + mf:name "list-greater-than-23" ; + rdfs:comment "greater-than test with mixed types" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-greater-than-24 rdf:type mf:QueryEvaluationTest ; + mf:name "list-greater-than-24" ; + rdfs:comment "greater-than test with mixed types" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-greater-than-25 rdf:type mf:QueryEvaluationTest ; + mf:name "list-greater-than-25" ; + rdfs:comment "greater-than test with blank nodes" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-greater-than-26 rdf:type mf:QueryEvaluationTest ; + mf:name "list-greater-than-26" ; + rdfs:comment "greater-than test with blank nodes" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-greater-than-27 rdf:type mf:QueryEvaluationTest ; + mf:name "list-greater-than-27" ; + rdfs:comment "greater-than test with blank nodes" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-greater-than-28 rdf:type mf:QueryEvaluationTest ; + mf:name "list-greater-than-28" ; + rdfs:comment "greater-than test with blank nodes" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-greater-than-29 rdf:type mf:QueryEvaluationTest ; + mf:name "list-greater-than-29" ; + rdfs:comment "greater-than test with blank nodes" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-greater-than-31 rdf:type mf:QueryEvaluationTest ; + mf:name "list-greater-than-31" ; + rdfs:comment "greater-than test with IRIs" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-greater-than-null-01 rdf:type mf:QueryEvaluationTest ; + mf:name "list-greater-than-null-01" ; + rdfs:comment "greater-than test with nulls" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-greater-than-null-02 rdf:type mf:QueryEvaluationTest ; + mf:name "list-greater-than-null-02" ; + rdfs:comment "greater-than test with nulls" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-greater-than-null-03 rdf:type mf:QueryEvaluationTest ; + mf:name "list-greater-than-null-03" ; + rdfs:comment "greater-than test with nulls" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-greater-than-null-04 rdf:type mf:QueryEvaluationTest ; + mf:name "list-greater-than-null-04" ; + rdfs:comment "greater-than test with nulls" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-greater-than-null-05 rdf:type mf:QueryEvaluationTest ; + mf:name "list-greater-than-null-05" ; + rdfs:comment "greater-than test with nulls" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-greater-than-null-06 rdf:type mf:QueryEvaluationTest ; + mf:name "list-greater-than-null-06" ; + rdfs:comment "greater-than test with null and blank node" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-greater-than-error-03 rdf:type mf:QueryEvaluationTest ; + mf:name "list-greater-than-error-03" ; + rdfs:comment "greater-than test with ill-formed literal" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-greater-than-error-04 rdf:type mf:QueryEvaluationTest ; + mf:name "list-greater-than-error-04" ; + rdfs:comment "greater-than test with ill-formed literal" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-greater-equal-01 rdf:type mf:QueryEvaluationTest ; + mf:name "list-greater-equal-01" ; + rdfs:comment "greater-equal test on two empty lists" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-greater-equal-02 rdf:type mf:QueryEvaluationTest ; + mf:name "list-greater-equal-02" ; + rdfs:comment "greater-equal test with one empty list" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-greater-equal-03 rdf:type mf:QueryEvaluationTest ; + mf:name "list-greater-equal-03" ; + rdfs:comment "greater-equal test with one empty list" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-greater-equal-04 rdf:type mf:QueryEvaluationTest ; + mf:name "list-greater-equal-04" ; + rdfs:comment "greater-equal test with equal lists" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-greater-equal-05 rdf:type mf:QueryEvaluationTest ; + mf:name "list-greater-equal-05" ; + rdfs:comment "greater-equal test with integers" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-greater-equal-06 rdf:type mf:QueryEvaluationTest ; + mf:name "list-greater-equal-06" ; + rdfs:comment "greater-equal test with integers" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-greater-equal-07 rdf:type mf:QueryEvaluationTest ; + mf:name "list-greater-equal-07" ; + rdfs:comment "greater-equal test with integers" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-greater-equal-08 rdf:type mf:QueryEvaluationTest ; + mf:name "list-greater-equal-08" ; + rdfs:comment "greater-equal test with integers" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-greater-equal-09 rdf:type mf:QueryEvaluationTest ; + mf:name "list-greater-equal-09" ; + rdfs:comment "greater-equal test with integers" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-greater-equal-10 rdf:type mf:QueryEvaluationTest ; + mf:name "list-greater-equal-10" ; + rdfs:comment "greater-equal test with integers" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-greater-equal-11 rdf:type mf:QueryEvaluationTest ; + mf:name "list-greater-equal-11" ; + rdfs:comment "greater-equal test with integers" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-greater-equal-12 rdf:type mf:QueryEvaluationTest ; + mf:name "list-greater-equal-12" ; + rdfs:comment "greater-equal test with integers" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-greater-equal-13 rdf:type mf:QueryEvaluationTest ; + mf:name "list-greater-equal-13" ; + rdfs:comment "greater-equal test with integers" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-greater-equal-14 rdf:type mf:QueryEvaluationTest ; + mf:name "list-greater-equal-14" ; + rdfs:comment "greater-equal test with integers" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-greater-equal-15 rdf:type mf:QueryEvaluationTest ; + mf:name "list-greater-equal-15" ; + rdfs:comment "greater-equal test with booleans" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-greater-equal-16 rdf:type mf:QueryEvaluationTest ; + mf:name "list-greater-equal-16" ; + rdfs:comment "greater-equal test with booleans" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-greater-equal-19 rdf:type mf:QueryEvaluationTest ; + mf:name "list-greater-equal-19" ; + rdfs:comment "greater-equal test with mixed types" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-greater-equal-20 rdf:type mf:QueryEvaluationTest ; + mf:name "list-greater-equal-20" ; + rdfs:comment "greater-equal test with mixed types" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-greater-equal-21 rdf:type mf:QueryEvaluationTest ; + mf:name "list-greater-equal-21" ; + rdfs:comment "greater-equal test with mixed types" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-greater-equal-22 rdf:type mf:QueryEvaluationTest ; + mf:name "list-greater-equal-22" ; + rdfs:comment "greater-equal test with mixed types" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-greater-equal-23 rdf:type mf:QueryEvaluationTest ; + mf:name "list-greater-equal-23" ; + rdfs:comment "greater-equal test with mixed types" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-greater-equal-24 rdf:type mf:QueryEvaluationTest ; + mf:name "list-greater-equal-24" ; + rdfs:comment "greater-equal test with mixed types" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-greater-equal-25 rdf:type mf:QueryEvaluationTest ; + mf:name "list-greater-equal-25" ; + rdfs:comment "greater-equal test with blank nodes" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-greater-equal-26 rdf:type mf:QueryEvaluationTest ; + mf:name "list-greater-equal-26" ; + rdfs:comment "greater-equal test with blank nodes" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-greater-equal-27 rdf:type mf:QueryEvaluationTest ; + mf:name "list-greater-equal-27" ; + rdfs:comment "greater-equal test with blank nodes" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-greater-equal-28 rdf:type mf:QueryEvaluationTest ; + mf:name "list-greater-equal-28" ; + rdfs:comment "greater-equal test with blank nodes" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-greater-equal-29 rdf:type mf:QueryEvaluationTest ; + mf:name "list-greater-equal-29" ; + rdfs:comment "greater-equal test with blank nodes" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-greater-equal-31 rdf:type mf:QueryEvaluationTest ; + mf:name "list-greater-equal-31" ; + rdfs:comment "greater-equal test with IRIs" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-greater-equal-null-01 rdf:type mf:QueryEvaluationTest ; + mf:name "list-greater-equal-null-01" ; + rdfs:comment "greater-equal test with nulls" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-greater-equal-null-02 rdf:type mf:QueryEvaluationTest ; + mf:name "list-greater-equal-null-02" ; + rdfs:comment "greater-equal test with nulls" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-greater-equal-null-03 rdf:type mf:QueryEvaluationTest ; + mf:name "list-greater-equal-null-03" ; + rdfs:comment "greater-equal test with nulls" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-greater-equal-null-04 rdf:type mf:QueryEvaluationTest ; + mf:name "list-greater-equal-null-04" ; + rdfs:comment "greater-equal test with nulls" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-greater-equal-null-05 rdf:type mf:QueryEvaluationTest ; + mf:name "list-greater-equal-null-05" ; + rdfs:comment "greater-equal test with nulls" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-greater-equal-null-06 rdf:type mf:QueryEvaluationTest ; + mf:name "list-greater-equal-null-06" ; + rdfs:comment "greater-equal test with null and blank node" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-greater-equal-error-03 rdf:type mf:QueryEvaluationTest ; + mf:name "list-greater-equal-error-03" ; + rdfs:comment "greater-equal test with ill-formed literal" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:list-greater-equal-error-04 rdf:type mf:QueryEvaluationTest ; + mf:name "list-greater-equal-error-04" ; + rdfs:comment "greater-equal test with ill-formed literal" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:sameterm-01 rdf:type mf:QueryEvaluationTest ; + mf:name "sameterm-01" ; + rdfs:comment "sameterm test on empty list" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:sameterm-02 rdf:type mf:QueryEvaluationTest ; + mf:name "sameterm-02" ; + rdfs:comment "sameterm test on single-element" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:sameterm-03 rdf:type mf:QueryEvaluationTest ; + mf:name "sameterm-03" ; + rdfs:comment "sameterm test on multiple-element" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:sameterm-04 rdf:type mf:QueryEvaluationTest ; + mf:name "sameterm-04" ; + rdfs:comment "sameterm test on multiple-element, lexical-space comparison" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:sameterm-null-01 rdf:type mf:QueryEvaluationTest ; + mf:name "sameterm-null-01" ; + rdfs:comment "sameterm test on list with null (allowed since the test is on the list lexical, not the elements)" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . diff --git a/src/test/resources/sparql-cdts/tests/list-functions/reverse-01.rq b/src/test/resources/sparql-cdts/tests/list-functions/reverse-01.rq new file mode 100644 index 00000000..4383d70e --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/reverse-01.rq @@ -0,0 +1,7 @@ +PREFIX cdt: + +# empty list +ASK { + BIND("[]"^^cdt:List AS ?list) + FILTER(cdt:reverse(?list) = ?list) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/reverse-02.rq b/src/test/resources/sparql-cdts/tests/list-functions/reverse-02.rq new file mode 100644 index 00000000..4a3b1111 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/reverse-02.rq @@ -0,0 +1,7 @@ +PREFIX cdt: +PREFIX xsd: +# list with one integer +ASK { + BIND("[1]"^^cdt:List AS ?list) + FILTER(cdt:reverse(?list) = ?list) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/reverse-03.rq b/src/test/resources/sparql-cdts/tests/list-functions/reverse-03.rq new file mode 100644 index 00000000..77a4d485 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/reverse-03.rq @@ -0,0 +1,7 @@ +PREFIX cdt: +PREFIX xsd: +# list with two integers +ASK { + BIND("[1, 2]"^^cdt:List AS ?list) + FILTER(cdt:reverse(?list) = "[2,1]"^^cdt:List) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/reverse-04.rq b/src/test/resources/sparql-cdts/tests/list-functions/reverse-04.rq new file mode 100644 index 00000000..a62b3b6c --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/reverse-04.rq @@ -0,0 +1,7 @@ +PREFIX cdt: +PREFIX xsd: +# list with one string +ASK { + BIND("['a']"^^cdt:List AS ?list) + FILTER(cdt:reverse(?list) = "['a']"^^cdt:List) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/reverse-05.rq b/src/test/resources/sparql-cdts/tests/list-functions/reverse-05.rq new file mode 100644 index 00000000..8c96fc10 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/reverse-05.rq @@ -0,0 +1,7 @@ +PREFIX cdt: +PREFIX xsd: +# list with two strings +ASK { + BIND("['a', 'b']"^^cdt:List AS ?list) + FILTER(cdt:reverse(?list) = "['b','a']"^^cdt:List) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/reverse-06.rq b/src/test/resources/sparql-cdts/tests/list-functions/reverse-06.rq new file mode 100644 index 00000000..ed3589bb --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/reverse-06.rq @@ -0,0 +1,7 @@ +PREFIX cdt: +PREFIX xsd: +# list with two mixed types +ASK { + BIND("['a', 1]"^^cdt:List AS ?list) + FILTER(cdt:reverse(?list) = "[1,'a']"^^cdt:List) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/reverse-07.rq b/src/test/resources/sparql-cdts/tests/list-functions/reverse-07.rq new file mode 100644 index 00000000..06e8abc6 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/reverse-07.rq @@ -0,0 +1,9 @@ +PREFIX cdt: +PREFIX xsd: +# list with null +ASK { + BIND("[null]"^^cdt:List AS ?list) + BIND(cdt:reverse(?list) AS ?result) + BIND(cdt:List(?unbound) AS ?expected) + FILTER(SAMETERM(?result, ?expected)) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/reverse-08.rq b/src/test/resources/sparql-cdts/tests/list-functions/reverse-08.rq new file mode 100644 index 00000000..8f3c294e --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/reverse-08.rq @@ -0,0 +1,7 @@ +PREFIX cdt: +PREFIX xsd: +# list with nested empty list +ASK { + BIND("[[]]"^^cdt:List AS ?list) + FILTER(cdt:reverse(?list) = ?list) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/reverse-09.rq b/src/test/resources/sparql-cdts/tests/list-functions/reverse-09.rq new file mode 100644 index 00000000..1517911b --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/reverse-09.rq @@ -0,0 +1,7 @@ +PREFIX cdt: +PREFIX xsd: +# list with mixed types including nested list +ASK { + BIND("[[1], 2]"^^cdt:List AS ?list) + FILTER(cdt:reverse(?list) = "[2,[1]]"^^cdt:List) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/reverse-10.rq b/src/test/resources/sparql-cdts/tests/list-functions/reverse-10.rq new file mode 100644 index 00000000..4bce4827 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/reverse-10.rq @@ -0,0 +1,9 @@ +PREFIX cdt: +PREFIX xsd: +# list with mixed defined and undefined types +ASK { + BIND("[null, 2]"^^cdt:List AS ?list) + BIND(cdt:reverse(?list) AS ?result) + BIND(cdt:List(2, ?unbound) AS ?expected) + FILTER(SAMETERM(?result, ?expected)) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/reverse-error-01.rq b/src/test/resources/sparql-cdts/tests/list-functions/reverse-error-01.rq new file mode 100644 index 00000000..81e6110b --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/reverse-error-01.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND("[1,2]" AS ?list) + BIND(cdt:reverse(?list) AS ?result) + FILTER(!BOUND(?result)) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/sameterm-01.rq b/src/test/resources/sparql-cdts/tests/list-functions/sameterm-01.rq new file mode 100644 index 00000000..db9e63f7 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/sameterm-01.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND(cdt:List() AS ?list1) + BIND(cdt:List() AS ?list2) + FILTER(SAMETERM(?list1, ?list2)) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/sameterm-02.rq b/src/test/resources/sparql-cdts/tests/list-functions/sameterm-02.rq new file mode 100644 index 00000000..68e6fe45 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/sameterm-02.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND(cdt:List(1) AS ?list1) + BIND(cdt:List(1) AS ?list2) + FILTER(SAMETERM(?list1, ?list2)) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/sameterm-03.rq b/src/test/resources/sparql-cdts/tests/list-functions/sameterm-03.rq new file mode 100644 index 00000000..e94ffd26 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/sameterm-03.rq @@ -0,0 +1,7 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND(cdt:List(1,2) AS ?list) + FILTER(!SAMETERM(?list, "[1,'2'^^]"^^cdt:List)) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/sameterm-04.rq b/src/test/resources/sparql-cdts/tests/list-functions/sameterm-04.rq new file mode 100644 index 00000000..1c0388d0 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/sameterm-04.rq @@ -0,0 +1,7 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND(cdt:List(1,2,3) AS ?list) + FILTER(!SAMETERM(?list, "[ 1 , 2 , 3 ]"^^cdt:List)) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/sameterm-null-01.rq b/src/test/resources/sparql-cdts/tests/list-functions/sameterm-null-01.rq new file mode 100644 index 00000000..f75d41dd --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/sameterm-null-01.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND(cdt:List(1, ?undef1, 2) AS ?list1) + BIND(cdt:List(1, ?undef2, 2) AS ?list2) + FILTER(SAMETERM(?list1, ?list2)) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/size-01.rq b/src/test/resources/sparql-cdts/tests/list-functions/size-01.rq new file mode 100644 index 00000000..2d040c01 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/size-01.rq @@ -0,0 +1,7 @@ +PREFIX cdt: + +# empty list +ASK { + BIND("[]"^^cdt:List AS ?list) + FILTER(cdt:size(?list) = 0) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/size-02.rq b/src/test/resources/sparql-cdts/tests/list-functions/size-02.rq new file mode 100644 index 00000000..9633d1dc --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/size-02.rq @@ -0,0 +1,7 @@ +PREFIX cdt: +PREFIX xsd: +# list with one integer +ASK { + BIND("[1]"^^cdt:List AS ?list) + FILTER(cdt:size(?list) = 1) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/size-03.rq b/src/test/resources/sparql-cdts/tests/list-functions/size-03.rq new file mode 100644 index 00000000..a1ec1532 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/size-03.rq @@ -0,0 +1,7 @@ +PREFIX cdt: +PREFIX xsd: +# list with two integers +ASK { + BIND("[1, 2]"^^cdt:List AS ?list) + FILTER(cdt:size(?list) = 2) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/size-04.rq b/src/test/resources/sparql-cdts/tests/list-functions/size-04.rq new file mode 100644 index 00000000..5733686e --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/size-04.rq @@ -0,0 +1,7 @@ +PREFIX cdt: +PREFIX xsd: +# list with one string +ASK { + BIND("['a']"^^cdt:List AS ?list) + FILTER(cdt:size(?list) = 1) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/size-05.rq b/src/test/resources/sparql-cdts/tests/list-functions/size-05.rq new file mode 100644 index 00000000..27fe8449 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/size-05.rq @@ -0,0 +1,7 @@ +PREFIX cdt: +PREFIX xsd: +# list with two strings +ASK { + BIND("['a', 'b']"^^cdt:List AS ?list) + FILTER(cdt:size(?list) = 2) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/size-06.rq b/src/test/resources/sparql-cdts/tests/list-functions/size-06.rq new file mode 100644 index 00000000..5bc76373 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/size-06.rq @@ -0,0 +1,7 @@ +PREFIX cdt: +PREFIX xsd: +# list with two mixed types +ASK { + BIND("['a', 1]"^^cdt:List AS ?list) + FILTER(cdt:size(?list) = 2) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/size-07.rq b/src/test/resources/sparql-cdts/tests/list-functions/size-07.rq new file mode 100644 index 00000000..c39f1949 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/size-07.rq @@ -0,0 +1,7 @@ +PREFIX cdt: +PREFIX xsd: +# list with error as null +ASK { + BIND("[null]"^^cdt:List AS ?list) + FILTER(cdt:size(?list) = 1) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/size-08.rq b/src/test/resources/sparql-cdts/tests/list-functions/size-08.rq new file mode 100644 index 00000000..920e6979 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/size-08.rq @@ -0,0 +1,7 @@ +PREFIX cdt: +PREFIX xsd: +# list with unbound as null +ASK { + BIND("[null]"^^cdt:List AS ?list) + FILTER(cdt:size(?list) = 1) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/size-09.rq b/src/test/resources/sparql-cdts/tests/list-functions/size-09.rq new file mode 100644 index 00000000..ac57087e --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/size-09.rq @@ -0,0 +1,7 @@ +PREFIX cdt: +PREFIX xsd: +# list with nested empty list +ASK { + BIND("[[]]"^^cdt:List AS ?list) + FILTER(cdt:size(?list) = 1) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/size-10.rq b/src/test/resources/sparql-cdts/tests/list-functions/size-10.rq new file mode 100644 index 00000000..88f02e4e --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/size-10.rq @@ -0,0 +1,7 @@ +PREFIX cdt: +PREFIX xsd: +# list with nested list with one integer +ASK { + BIND("[[1]]"^^cdt:List AS ?list) + FILTER(cdt:size(?list) = 1) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/size-11.rq b/src/test/resources/sparql-cdts/tests/list-functions/size-11.rq new file mode 100644 index 00000000..dca93e3a --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/size-11.rq @@ -0,0 +1,7 @@ +PREFIX cdt: +PREFIX xsd: +# list with mixed types including nested list +ASK { + BIND("[[1], 2]"^^cdt:List AS ?list) + FILTER(cdt:size(?list) = 2) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/size-12.rq b/src/test/resources/sparql-cdts/tests/list-functions/size-12.rq new file mode 100644 index 00000000..ea68b510 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/size-12.rq @@ -0,0 +1,7 @@ +PREFIX cdt: +PREFIX xsd: +# list with mixed defined and undefined types +ASK { + BIND("[null, 2]"^^cdt:List AS ?list) + FILTER(cdt:size(?list) = 2) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/size-error-01.rq b/src/test/resources/sparql-cdts/tests/list-functions/size-error-01.rq new file mode 100644 index 00000000..47db4e0b --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/size-error-01.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND("[1,2]" AS ?list) + BIND(cdt:size(?list) AS ?result) + FILTER(!BOUND(?result)) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/subseq-01.rq b/src/test/resources/sparql-cdts/tests/list-functions/subseq-01.rq new file mode 100644 index 00000000..36b419f8 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/subseq-01.rq @@ -0,0 +1,7 @@ +PREFIX cdt: +PREFIX xsd: +# subseq 1-1 +ASK { + BIND("[1,2,3,4,5,6,7,8,9,10]"^^cdt:List AS ?list) + FILTER(cdt:subseq(?list, 1, 1) = "[1]"^^cdt:List) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/subseq-02.rq b/src/test/resources/sparql-cdts/tests/list-functions/subseq-02.rq new file mode 100644 index 00000000..44a6b730 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/subseq-02.rq @@ -0,0 +1,7 @@ +PREFIX cdt: +PREFIX xsd: +# subseq 2-3 +ASK { + BIND("[1,2,3,4,5,6,7,8,9,10]"^^cdt:List AS ?list) + FILTER(cdt:subseq(?list, 2, 3) = "[2, 3, 4]"^^cdt:List) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/subseq-03.rq b/src/test/resources/sparql-cdts/tests/list-functions/subseq-03.rq new file mode 100644 index 00000000..74c14694 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/subseq-03.rq @@ -0,0 +1,7 @@ +PREFIX cdt: +PREFIX xsd: +# subseq 1-arg +ASK { + BIND("[1,2,3,4,5,6,7,8,9,10]"^^cdt:List AS ?list) + FILTER(cdt:subseq(?list, 7) = "[7,8,9,10]"^^cdt:List) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/subseq-04.rq b/src/test/resources/sparql-cdts/tests/list-functions/subseq-04.rq new file mode 100644 index 00000000..5c99f6d5 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/subseq-04.rq @@ -0,0 +1,7 @@ +PREFIX cdt: + +# empty list +ASK { + BIND("[]"^^cdt:List AS ?list) + FILTER(cdt:subseq(?list, 1, 0) = ?list) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/subseq-05.rq b/src/test/resources/sparql-cdts/tests/list-functions/subseq-05.rq new file mode 100644 index 00000000..0f9b0212 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/subseq-05.rq @@ -0,0 +1,7 @@ +PREFIX cdt: + +# empty list +ASK { + BIND("[]"^^cdt:List AS ?list) + FILTER(cdt:subseq(?list, 1) = ?list) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/subseq-06.rq b/src/test/resources/sparql-cdts/tests/list-functions/subseq-06.rq new file mode 100644 index 00000000..6e9c696d --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/subseq-06.rq @@ -0,0 +1,7 @@ +PREFIX cdt: + +# special case: idx = size+1 and length=0 +ASK { + BIND("[1,2,3]"^^cdt:List AS ?list) + FILTER(cdt:subseq(?list, 4, 0) = "[]"^^cdt:List) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/subseq-07.rq b/src/test/resources/sparql-cdts/tests/list-functions/subseq-07.rq new file mode 100644 index 00000000..d91de2a7 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/subseq-07.rq @@ -0,0 +1,7 @@ +PREFIX cdt: + +# special case: idx = size+1 and no length given +ASK { + BIND("[1,2,3]"^^cdt:List AS ?list) + FILTER(cdt:subseq(?list, 4) = "[]"^^cdt:List) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/subseq-08.rq b/src/test/resources/sparql-cdts/tests/list-functions/subseq-08.rq new file mode 100644 index 00000000..fed22c3a --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/subseq-08.rq @@ -0,0 +1,8 @@ +PREFIX cdt: + +# 1 arg overrun +ASK { + BIND("[1,2,3]"^^cdt:List AS ?list) + BIND(cdt:subseq(?list, 5) AS ?result) + FILTER(!BOUND(?result)) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/subseq-09.rq b/src/test/resources/sparql-cdts/tests/list-functions/subseq-09.rq new file mode 100644 index 00000000..5283078f --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/subseq-09.rq @@ -0,0 +1,8 @@ +PREFIX cdt: + +# 2 args overrun +ASK { + BIND("[1,2,3]"^^cdt:List AS ?list) + BIND(cdt:subseq(?list, 5, 0) AS ?result) + FILTER(!BOUND(?result)) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/subseq-10.rq b/src/test/resources/sparql-cdts/tests/list-functions/subseq-10.rq new file mode 100644 index 00000000..2f6bbac1 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/subseq-10.rq @@ -0,0 +1,8 @@ +PREFIX cdt: + +# 2 args overrun +ASK { + BIND("[1,2,3]"^^cdt:List AS ?list) + BIND(cdt:subseq(?list, 4, 1) AS ?result) + FILTER(!BOUND(?result)) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/subseq-11.rq b/src/test/resources/sparql-cdts/tests/list-functions/subseq-11.rq new file mode 100644 index 00000000..d48851f4 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/subseq-11.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: +# subseq overrun 10-2 +ASK { + BIND("[1,2,3,4,5,6,7,8,9,10]"^^cdt:List AS ?list) + BIND(cdt:subseq(?list, 10, 2) AS ?result) + FILTER(!BOUND(?result)) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/subseq-12.rq b/src/test/resources/sparql-cdts/tests/list-functions/subseq-12.rq new file mode 100644 index 00000000..ded71ce5 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/subseq-12.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: +# subseq underrun 0-2 +ASK { + BIND("[1,2,3,4,5,6,7,8,9,10]"^^cdt:List AS ?list) + BIND(cdt:subseq(?list, 0, 2) AS ?result) + FILTER(!BOUND(?result)) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/subseq-13.rq b/src/test/resources/sparql-cdts/tests/list-functions/subseq-13.rq new file mode 100644 index 00000000..ae90166f --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/subseq-13.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: +# subseq 1-arg underrun +ASK { + BIND("[1,2,3,4,5,6,7,8,9,10]"^^cdt:List AS ?list) + BIND(cdt:subseq(?list, -2) AS ?result) + FILTER(!BOUND(?result)) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/subseq-error-01.rq b/src/test/resources/sparql-cdts/tests/list-functions/subseq-error-01.rq new file mode 100644 index 00000000..d3be2861 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/subseq-error-01.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND("[1,2,3,4,5,6,7,8,9,10]" AS ?list) + BIND(cdt:subseq(?list, 2, 3) AS ?result) + FILTER(!BOUND(?result)) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/subseq-error-02.rq b/src/test/resources/sparql-cdts/tests/list-functions/subseq-error-02.rq new file mode 100644 index 00000000..fcb525eb --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/subseq-error-02.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND("[1,2,3,4,5,6,7,8,9,10]"^^cdt:List AS ?list) + BIND(cdt:subseq(?list, "invalid", 3) AS ?result) + FILTER(!BOUND(?result)) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/tail-01.rq b/src/test/resources/sparql-cdts/tests/list-functions/tail-01.rq new file mode 100644 index 00000000..b48227cc --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/tail-01.rq @@ -0,0 +1,8 @@ +PREFIX cdt: + +# empty list +ASK { + BIND("[]"^^cdt:List AS ?list) + BIND(cdt:tail(?list) AS ?result) + FILTER(!BOUND(?result)) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/tail-02.rq b/src/test/resources/sparql-cdts/tests/list-functions/tail-02.rq new file mode 100644 index 00000000..f3a67b08 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/tail-02.rq @@ -0,0 +1,7 @@ +PREFIX cdt: +PREFIX xsd: +# list with one integer +ASK { + BIND("[1]"^^cdt:List AS ?list) + FILTER(cdt:tail(?list) = "[]"^^cdt:List) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/tail-03.rq b/src/test/resources/sparql-cdts/tests/list-functions/tail-03.rq new file mode 100644 index 00000000..f8f53db3 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/tail-03.rq @@ -0,0 +1,7 @@ +PREFIX cdt: +PREFIX xsd: +# list with two integers +ASK { + BIND("[1, 2]"^^cdt:List AS ?list) + FILTER(cdt:tail(?list) = "[2]"^^cdt:List) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/tail-04.rq b/src/test/resources/sparql-cdts/tests/list-functions/tail-04.rq new file mode 100644 index 00000000..e74541ca --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/tail-04.rq @@ -0,0 +1,7 @@ +PREFIX cdt: +PREFIX xsd: +# list with one string +ASK { + BIND("['a']"^^cdt:List AS ?list) + FILTER(cdt:tail(?list) = "[]"^^cdt:List) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/tail-05.rq b/src/test/resources/sparql-cdts/tests/list-functions/tail-05.rq new file mode 100644 index 00000000..c58486a4 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/tail-05.rq @@ -0,0 +1,7 @@ +PREFIX cdt: +PREFIX xsd: +# list with two strings +ASK { + BIND("['a', 'b']"^^cdt:List AS ?list) + FILTER(cdt:tail(?list) = "['b']"^^cdt:List) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/tail-06.rq b/src/test/resources/sparql-cdts/tests/list-functions/tail-06.rq new file mode 100644 index 00000000..590df7ae --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/tail-06.rq @@ -0,0 +1,7 @@ +PREFIX cdt: +PREFIX xsd: +# list with two mixed types +ASK { + BIND("['a', 1]"^^cdt:List AS ?list) + FILTER(cdt:tail(?list) = "[1]"^^cdt:List) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/tail-07.rq b/src/test/resources/sparql-cdts/tests/list-functions/tail-07.rq new file mode 100644 index 00000000..857124b6 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/tail-07.rq @@ -0,0 +1,7 @@ +PREFIX cdt: +PREFIX xsd: +# list with null +ASK { + BIND("[null]"^^cdt:List AS ?list) + FILTER(cdt:tail(?list) = "[]"^^cdt:List) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/tail-08.rq b/src/test/resources/sparql-cdts/tests/list-functions/tail-08.rq new file mode 100644 index 00000000..acf1633c --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/tail-08.rq @@ -0,0 +1,7 @@ +PREFIX cdt: +PREFIX xsd: +# list with nested empty list +ASK { + BIND("[[]]"^^cdt:List AS ?list) + FILTER(cdt:tail(?list) = "[]"^^cdt:List) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/tail-09.rq b/src/test/resources/sparql-cdts/tests/list-functions/tail-09.rq new file mode 100644 index 00000000..4e66669f --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/tail-09.rq @@ -0,0 +1,7 @@ +PREFIX cdt: +PREFIX xsd: +# list with mixed types including nested list +ASK { + BIND("[[1], 2]"^^cdt:List AS ?list) + FILTER(cdt:tail(?list) = "[2]"^^cdt:List) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/tail-10.rq b/src/test/resources/sparql-cdts/tests/list-functions/tail-10.rq new file mode 100644 index 00000000..f307c909 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/tail-10.rq @@ -0,0 +1,7 @@ +PREFIX cdt: +PREFIX xsd: +# list with mixed defined and undefined types +ASK { + BIND("[null, 2]"^^cdt:List AS ?list) + FILTER(cdt:tail(?list) = "[2]"^^cdt:List) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/tail-error-01.rq b/src/test/resources/sparql-cdts/tests/list-functions/tail-error-01.rq new file mode 100644 index 00000000..8d2be93f --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/tail-error-01.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND("[1,2]" AS ?list) + BIND(cdt:tail(?list) AS ?result) + FILTER(!BOUND(?result)) +} diff --git a/src/test/resources/sparql-cdts/tests/list-functions/true.srx b/src/test/resources/sparql-cdts/tests/list-functions/true.srx new file mode 100644 index 00000000..c187f066 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/list-functions/true.srx @@ -0,0 +1,5 @@ + + + + true + diff --git a/src/test/resources/sparql-cdts/tests/manifest-all.ttl b/src/test/resources/sparql-cdts/tests/manifest-all.ttl new file mode 100644 index 00000000..f352dd7c --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/manifest-all.ttl @@ -0,0 +1,16 @@ +@prefix rdf: . +@prefix rdfs: . +@prefix mf: . +@prefix qt: . + +<> a mf:Manifest ; + rdfs:label "SPARQL Composite Datatype tests" ; + mf:include ( + + + + + + + ) ; +. diff --git a/src/test/resources/sparql-cdts/tests/map-functions/containsKey-01.rq b/src/test/resources/sparql-cdts/tests/map-functions/containsKey-01.rq new file mode 100644 index 00000000..04941676 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/containsKey-01.rq @@ -0,0 +1,9 @@ +PREFIX cdt: + +# empty map +ASK { + BIND("{}"^^cdt:Map AS ?map) + BIND(cdt:containsKey(?map, 1) AS ?result) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/containsKey-02.rq b/src/test/resources/sparql-cdts/tests/map-functions/containsKey-02.rq new file mode 100644 index 00000000..3734ca2c --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/containsKey-02.rq @@ -0,0 +1,9 @@ +PREFIX cdt: +PREFIX xsd: + +# 1-entry map +ASK { + BIND("{1: 'one'}"^^cdt:Map AS ?map) + FILTER(cdt:containsKey(?map, 1)) + FILTER(!cdt:containsKey(?map, "01"^^xsd:integer)) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/containsKey-03.rq b/src/test/resources/sparql-cdts/tests/map-functions/containsKey-03.rq new file mode 100644 index 00000000..ef81a3de --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/containsKey-03.rq @@ -0,0 +1,11 @@ +PREFIX cdt: + +# 2-entry map +ASK { + BIND("{1: 'one', 2: 'two'}"^^cdt:Map AS ?map) + FILTER(cdt:containsKey(?map, 1)) + FILTER(cdt:containsKey(?map, 2)) + + FILTER(!cdt:containsKey(?map, 'one')) + FILTER(!cdt:containsKey(?map, 'two')) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/empty.ttl b/src/test/resources/sparql-cdts/tests/map-functions/empty.ttl new file mode 100644 index 00000000..e69de29b diff --git a/src/test/resources/sparql-cdts/tests/map-functions/get-01.rq b/src/test/resources/sparql-cdts/tests/map-functions/get-01.rq new file mode 100644 index 00000000..820a6157 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/get-01.rq @@ -0,0 +1,9 @@ +PREFIX cdt: + +# list with one integer +ASK { + BIND("{'hello'@en:'there'@en,1:'one',2:'two'}"^^cdt:Map AS ?map) + FILTER(cdt:get(?map, 1) = "one") + FILTER(cdt:get(?map, 2) = "two") + FILTER(cdt:get(?map, 'hello'@en) = "there"@en) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/get-02.rq b/src/test/resources/sparql-cdts/tests/map-functions/get-02.rq new file mode 100644 index 00000000..98acf81c --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/get-02.rq @@ -0,0 +1,9 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND("{1:'one', 2:'two', '02'^^: 'also two'}"^^cdt:Map AS ?map) + FILTER(cdt:get(?map, 1) = "one") + FILTER(cdt:get(?map, 2) = "two") + FILTER(cdt:get(?map, "02"^^xsd:integer) = "also two") +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/get-03.rq b/src/test/resources/sparql-cdts/tests/map-functions/get-03.rq new file mode 100644 index 00000000..69de1689 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/get-03.rq @@ -0,0 +1,12 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( "{ 1: _:b, 2: _:b }"^^cdt:Map AS ?map ) + BIND( cdt:get(?map, 1) AS ?v1 ) + BIND( cdt:get(?map, 2) AS ?v2 ) + + FILTER( isBLANK(?v1) ) + FILTER( isBLANK(?v2) ) + FILTER( SAMETERM(?v1, ?v2) ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/get-04.rq b/src/test/resources/sparql-cdts/tests/map-functions/get-04.rq new file mode 100644 index 00000000..54133e0a --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/get-04.rq @@ -0,0 +1,12 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( "{ 1: _:b1, 2: _:b2 }"^^cdt:Map AS ?map ) + BIND( cdt:get(?map, 1) AS ?v1 ) + BIND( cdt:get(?map, 2) AS ?v2 ) + + FILTER( isBLANK(?v1) ) + FILTER( isBLANK(?v2) ) + FILTER( ! SAMETERM(?v1, ?v2) ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/get-error-01.rq b/src/test/resources/sparql-cdts/tests/map-functions/get-error-01.rq new file mode 100644 index 00000000..3e755e64 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/get-error-01.rq @@ -0,0 +1,8 @@ +PREFIX cdt: + +# list with one integer +ASK { + BIND("{1:'one',2:'two',4:'four'}"^^cdt:Map AS ?map) + BIND(cdt:get(?map, 3) AS ?null) + FILTER(!BOUND(?null)) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/get-null-01.rq b/src/test/resources/sparql-cdts/tests/map-functions/get-null-01.rq new file mode 100644 index 00000000..910a4e9e --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/get-null-01.rq @@ -0,0 +1,8 @@ +PREFIX cdt: + +# list with one integer +ASK { + BIND("{1:'one',2:'two',3:null,4:'four'}"^^cdt:Map AS ?map) + BIND(cdt:get(?map, 3) AS ?null) + FILTER(!BOUND(?null)) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/keys-01.rq b/src/test/resources/sparql-cdts/tests/map-functions/keys-01.rq new file mode 100644 index 00000000..523fde77 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/keys-01.rq @@ -0,0 +1,7 @@ +PREFIX cdt: + +# empty map +ASK { + BIND("{}"^^cdt:Map AS ?map) + FILTER(cdt:keys(?map) = "[]"^^cdt:List) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/keys-02.rq b/src/test/resources/sparql-cdts/tests/map-functions/keys-02.rq new file mode 100644 index 00000000..d658ae5d --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/keys-02.rq @@ -0,0 +1,7 @@ +PREFIX cdt: + +# 1-entry map +ASK { + BIND("{1: 'one'}"^^cdt:Map AS ?map) + FILTER(cdt:keys(?map) = "[1]"^^cdt:List) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/keys-03.rq b/src/test/resources/sparql-cdts/tests/map-functions/keys-03.rq new file mode 100644 index 00000000..8bdfd43f --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/keys-03.rq @@ -0,0 +1,10 @@ +PREFIX cdt: + +# 2-entry map +ASK { + BIND("{1: 'one', 2: 'two'}"^^cdt:Map AS ?map) + BIND(cdt:keys(?map) AS ?keys) + FILTER(cdt:size(?keys) = 2) + FILTER(cdt:contains(?keys, 1)) + FILTER(cdt:contains(?keys, 2)) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/manifest.ttl b/src/test/resources/sparql-cdts/tests/map-functions/manifest.ttl new file mode 100644 index 00000000..3496be5d --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/manifest.ttl @@ -0,0 +1,2081 @@ +@prefix rdf: . +@prefix : . +@prefix rdfs: . +@prefix mf: . +@prefix qt: . +@prefix dawgt: . +@prefix sparql: . +@prefix cdt: . + +<> rdf:type mf:Manifest ; + rdfs:label "Functions for cdt:Map Literals" ; + mf:entries + ( + :get-01 + :get-02 + :get-03 + :get-04 + :get-null-01 + :get-error-01 + + :size-01 + :size-02 + :size-03 + :size-04 + :size-05 + + :keys-01 + :keys-02 + :keys-03 + + :containsKey-01 + :containsKey-02 + :containsKey-03 + + :map-constructor-01 + :map-constructor-02 + :map-constructor-03 + :map-constructor-04 + :map-constructor-05 + :map-constructor-06 + :map-constructor-07 + :map-constructor-08 + :map-constructor-09 + :map-constructor-10 + :map-constructor-11 + + :map-equals-01 # empty map + :map-equals-02 # single-element + :map-equals-03 # single-entry, integer shortcut syntax + :map-equals-04 # single-entry, keys with different lexical form but same value + :map-equals-05 # same IRI + :map-equals-06 # blank nodes + :map-equals-07 # blank nodes + :map-equals-08 # blank nodes + :map-equals-09 # blank nodes + :map-equals-null-01 + :map-equals-null-02 + + :map-less-than-01 + :map-less-than-02 + :map-less-than-03 + :map-less-than-04 + :map-less-than-05 + :map-less-than-06 + :map-less-than-07 + :map-less-than-08 + :map-less-than-09 + :map-less-than-10 + :map-less-than-11 + :map-less-than-12 + :map-less-than-13 + :map-less-than-14 + :map-less-than-15 + :map-less-than-16 + :map-less-than-17 + :map-less-than-18 + :map-less-than-19 + :map-less-than-20 + :map-less-than-21 + + :map-less-than-error-01 + :map-less-than-error-02 + :map-less-than-null-01 + :map-less-than-null-02 + :map-less-than-null-03 + :map-less-than-null-04 + + :map-less-equal-01 + :map-less-equal-02 + :map-less-equal-03 + :map-less-equal-04 + :map-less-equal-05 + :map-less-equal-06 + :map-less-equal-07 + :map-less-equal-08 + :map-less-equal-09 + :map-less-equal-10 + :map-less-equal-11 + :map-less-equal-12 + :map-less-equal-13 + :map-less-equal-14 + :map-less-equal-15 + :map-less-equal-16 + :map-less-equal-17 + :map-less-equal-18 + :map-less-equal-19 + :map-less-equal-20 + :map-less-equal-21 + + :map-less-equal-error-01 + :map-less-equal-error-02 + :map-less-equal-null-01 + :map-less-equal-null-02 + :map-less-equal-null-03 + :map-less-equal-null-04 + + :map-greater-than-01 + :map-greater-than-02 + :map-greater-than-03 + :map-greater-than-04 + :map-greater-than-05 + :map-greater-than-06 + :map-greater-than-07 + :map-greater-than-08 + :map-greater-than-09 + :map-greater-than-10 + :map-greater-than-11 + :map-greater-than-12 + :map-greater-than-13 + :map-greater-than-14 + :map-greater-than-15 + :map-greater-than-16 + :map-greater-than-17 + :map-greater-than-18 + :map-greater-than-19 + :map-greater-than-20 + :map-greater-than-21 + + :map-greater-than-error-01 + :map-greater-than-error-02 + :map-greater-than-null-01 + :map-greater-than-null-02 + :map-greater-than-null-03 + :map-greater-than-null-04 + + :map-greater-equal-01 + :map-greater-equal-02 + :map-greater-equal-03 + :map-greater-equal-04 + :map-greater-equal-05 + :map-greater-equal-06 + :map-greater-equal-07 + :map-greater-equal-08 + :map-greater-equal-09 + :map-greater-equal-10 + :map-greater-equal-11 + :map-greater-equal-12 + :map-greater-equal-13 + :map-greater-equal-14 + :map-greater-equal-15 + :map-greater-equal-16 + :map-greater-equal-17 + :map-greater-equal-18 + :map-greater-equal-19 + :map-greater-equal-20 + :map-greater-equal-21 + + :map-greater-equal-error-01 + :map-greater-equal-error-02 + :map-greater-equal-null-01 + :map-greater-equal-null-02 + :map-greater-equal-null-03 + :map-greater-equal-null-04 + + :merge-01 + :merge-02 + :merge-03 + :merge-04 + :merge-05 + :merge-06 + :merge-07 + :merge-08 + :merge-null-01 + :merge-null-02 + :merge-null-03 + :merge-null-04 + + :put-01 + :put-02 + :put-03 + :put-04 + :put-05 + :put-06 + :put-07 + :put-08 + :put-09 + :put-10 + :put-11 + :put-12 + :put-13 + :put-14 + :put-15 + + :put-error-01 + :put-error-02 + :put-error-03 + :put-error-04 + :put-error-05 + + :remove-01 + :remove-02 + :remove-03 + :remove-04 + :remove-05 + :remove-06 + :remove-07 + :remove-08 + :remove-09 + :remove-10 + :remove-11 + + # sameTerm Tests for Maps + :sameterm-01 # empty list + :sameterm-02 # single-pair + :sameterm-03 # single-pair, same entry, but different lexical form for integers + :sameterm-04 # single-pair, same entry, but different lexical form for whitespace + :sameterm-05 # single-pair, same entry with blank node + :sameterm-null-01 # map with null + ) . + +:get-01 rdf:type mf:QueryEvaluationTest ; + mf:name "get-01" ; + mf:feature cdt:get ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:get-02 rdf:type mf:QueryEvaluationTest ; + mf:name "get-02" ; + mf:feature cdt:get ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:get-03 rdf:type mf:QueryEvaluationTest ; + mf:name "get-03" ; + mf:feature cdt:get ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:get-04 rdf:type mf:QueryEvaluationTest ; + mf:name "get-04" ; + mf:feature cdt:get ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:get-null-01 rdf:type mf:QueryEvaluationTest ; + mf:name "get-null-01" ; + mf:feature cdt:get ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:get-error-01 rdf:type mf:QueryEvaluationTest ; + mf:name "get-error-01" ; + mf:feature cdt:get ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:size-01 rdf:type mf:QueryEvaluationTest ; + mf:name "size-01" ; + mf:feature cdt:size ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:size-02 rdf:type mf:QueryEvaluationTest ; + mf:name "size-02" ; + mf:feature cdt:size ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:size-03 rdf:type mf:QueryEvaluationTest ; + mf:name "size-03" ; + mf:feature cdt:size ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:size-04 rdf:type mf:QueryEvaluationTest ; + mf:name "size-04" ; + mf:feature cdt:size ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:size-05 rdf:type mf:QueryEvaluationTest ; + mf:name "size-05" ; + mf:feature cdt:size ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:keys-01 rdf:type mf:QueryEvaluationTest ; + mf:name "keys-01" ; + mf:feature cdt:size ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:keys-02 rdf:type mf:QueryEvaluationTest ; + mf:name "keys-02" ; + mf:feature cdt:size ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:keys-03 rdf:type mf:QueryEvaluationTest ; + mf:name "keys-03" ; + mf:feature cdt:size ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:containsKey-01 rdf:type mf:QueryEvaluationTest ; + mf:name "containsKey-01" ; + mf:feature cdt:containsKey ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:containsKey-02 rdf:type mf:QueryEvaluationTest ; + mf:name "containsKey-02" ; + mf:feature cdt:containsKey ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:containsKey-03 rdf:type mf:QueryEvaluationTest ; + mf:name "containsKey-03" ; + mf:feature cdt:containsKey ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-constructor-01 rdf:type mf:QueryEvaluationTest ; + mf:name "map-constructor-01" ; + mf:feature cdt:Map ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-constructor-02 rdf:type mf:QueryEvaluationTest ; + mf:name "map-constructor-02" ; + mf:feature cdt:Map ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-constructor-03 rdf:type mf:QueryEvaluationTest ; + mf:name "map-constructor-03" ; + mf:feature cdt:Map ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-constructor-04 rdf:type mf:QueryEvaluationTest ; + mf:name "map-constructor-04" ; + mf:feature cdt:Map ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-constructor-05 rdf:type mf:QueryEvaluationTest ; + mf:name "map-constructor-05" ; + mf:feature cdt:Map ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-constructor-06 rdf:type mf:QueryEvaluationTest ; + mf:name "map-constructor-06" ; + mf:feature cdt:Map ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-constructor-07 rdf:type mf:QueryEvaluationTest ; + mf:name "map-constructor-07" ; + mf:feature cdt:Map ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-constructor-08 rdf:type mf:QueryEvaluationTest ; + mf:name "map-constructor-08" ; + mf:feature cdt:Map ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-constructor-09 rdf:type mf:QueryEvaluationTest ; + mf:name "map-constructor-09" ; + mf:feature cdt:Map ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-constructor-10 rdf:type mf:QueryEvaluationTest ; + mf:name "map-constructor-10" ; + mf:feature cdt:Map ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-constructor-11 rdf:type mf:QueryEvaluationTest ; + mf:name "map-constructor-11" ; + mf:feature cdt:Map ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-equals-01 rdf:type mf:QueryEvaluationTest ; + mf:name "map-equals-01" ; + rdfs:comment "equals test on empty list" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-equals-02 rdf:type mf:QueryEvaluationTest ; + mf:name "map-equals-02" ; + rdfs:comment "equals test on single-element" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-equals-03 rdf:type mf:QueryEvaluationTest ; + mf:name "map-equals-03" ; + rdfs:comment "equals test on single-element, integer shortcut syntax" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-equals-04 rdf:type mf:QueryEvaluationTest ; + mf:name "map-equals-04" ; + rdfs:comment "equals test on single-element, keys with different lexical form but same value" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-equals-05 rdf:type mf:QueryEvaluationTest ; + mf:name "map-equals-05" ; + rdfs:comment "equals test on lists with same IRI" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-equals-06 rdf:type mf:QueryEvaluationTest ; + mf:name "map-equals-06" ; + rdfs:comment "equals test on lists with blank nodes" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-equals-07 rdf:type mf:QueryEvaluationTest ; + mf:name "map-equals-07" ; + rdfs:comment "equals test on lists with blank nodes" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-equals-08 rdf:type mf:QueryEvaluationTest ; + mf:name "map-equals-08" ; + rdfs:comment "equals test on lists with blank nodes" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-equals-09 rdf:type mf:QueryEvaluationTest ; + mf:name "map-equals-09" ; + rdfs:comment "equals test on lists with blank nodes" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-equals-null-01 rdf:type mf:QueryEvaluationTest ; + mf:name "map-equals-null-01" ; + rdfs:comment "equality of pairs of null within maps" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-equals-null-02 rdf:type mf:QueryEvaluationTest ; + mf:name "map-equals-null-02" ; + rdfs:comment "null is not equal to any RDF term" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-less-than-01 rdf:type mf:QueryEvaluationTest ; + mf:name "map-less-than-01" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-less-than-02 rdf:type mf:QueryEvaluationTest ; + mf:name "map-less-than-02" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-less-than-03 rdf:type mf:QueryEvaluationTest ; + mf:name "map-less-than-03" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-less-than-04 rdf:type mf:QueryEvaluationTest ; + mf:name "map-less-than-04" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-less-than-05 rdf:type mf:QueryEvaluationTest ; + mf:name "map-less-than-05" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-less-than-06 rdf:type mf:QueryEvaluationTest ; + mf:name "map-less-than-06" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-less-than-07 rdf:type mf:QueryEvaluationTest ; + mf:name "map-less-than-07" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-less-than-08 rdf:type mf:QueryEvaluationTest ; + mf:name "map-less-than-08" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-less-than-09 rdf:type mf:QueryEvaluationTest ; + mf:name "map-less-than-09" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-less-than-10 rdf:type mf:QueryEvaluationTest ; + mf:name "map-less-than-10" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-less-than-11 rdf:type mf:QueryEvaluationTest ; + mf:name "map-less-than-11" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-less-than-12 rdf:type mf:QueryEvaluationTest ; + mf:name "map-less-than-12" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-less-than-13 rdf:type mf:QueryEvaluationTest ; + mf:name "map-less-than-13" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-less-than-14 rdf:type mf:QueryEvaluationTest ; + mf:name "map-less-than-14" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-less-than-15 rdf:type mf:QueryEvaluationTest ; + mf:name "map-less-than-15" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-less-than-16 rdf:type mf:QueryEvaluationTest ; + mf:name "map-less-than-16" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-less-than-17 rdf:type mf:QueryEvaluationTest ; + mf:name "map-less-than-17" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-less-than-18 rdf:type mf:QueryEvaluationTest ; + mf:name "map-less-than-18" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-less-than-19 rdf:type mf:QueryEvaluationTest ; + mf:name "map-less-than-19" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-less-than-20 rdf:type mf:QueryEvaluationTest ; + mf:name "map-less-than-20" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-less-than-21 rdf:type mf:QueryEvaluationTest ; + mf:name "map-less-than-21" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-less-than-error-01 rdf:type mf:QueryEvaluationTest ; + mf:name "map-less-than-error-01" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-less-than-error-02 rdf:type mf:QueryEvaluationTest ; + mf:name "map-less-than-error-02" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-less-than-null-01 rdf:type mf:QueryEvaluationTest ; + mf:name "map-less-than-null-01" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-less-than-null-02 rdf:type mf:QueryEvaluationTest ; + mf:name "map-less-than-null-02" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-less-than-null-03 rdf:type mf:QueryEvaluationTest ; + mf:name "map-less-than-null-03" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-less-than-null-04 rdf:type mf:QueryEvaluationTest ; + mf:name "map-less-than-null-04" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-less-equal-01 rdf:type mf:QueryEvaluationTest ; + mf:name "map-less-equal-01" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-less-equal-02 rdf:type mf:QueryEvaluationTest ; + mf:name "map-less-equal-02" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-less-equal-03 rdf:type mf:QueryEvaluationTest ; + mf:name "map-less-equal-03" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-less-equal-04 rdf:type mf:QueryEvaluationTest ; + mf:name "map-less-equal-04" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-less-equal-05 rdf:type mf:QueryEvaluationTest ; + mf:name "map-less-equal-05" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-less-equal-06 rdf:type mf:QueryEvaluationTest ; + mf:name "map-less-equal-06" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-less-equal-07 rdf:type mf:QueryEvaluationTest ; + mf:name "map-less-equal-07" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-less-equal-08 rdf:type mf:QueryEvaluationTest ; + mf:name "map-less-equal-08" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-less-equal-09 rdf:type mf:QueryEvaluationTest ; + mf:name "map-less-equal-09" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-less-equal-10 rdf:type mf:QueryEvaluationTest ; + mf:name "map-less-equal-10" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-less-equal-11 rdf:type mf:QueryEvaluationTest ; + mf:name "map-less-equal-11" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-less-equal-12 rdf:type mf:QueryEvaluationTest ; + mf:name "map-less-equal-12" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-less-equal-13 rdf:type mf:QueryEvaluationTest ; + mf:name "map-less-equal-13" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-less-equal-14 rdf:type mf:QueryEvaluationTest ; + mf:name "map-less-equal-14" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-less-equal-15 rdf:type mf:QueryEvaluationTest ; + mf:name "map-less-equal-15" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-less-equal-16 rdf:type mf:QueryEvaluationTest ; + mf:name "map-less-equal-16" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-less-equal-17 rdf:type mf:QueryEvaluationTest ; + mf:name "map-less-equal-17" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-less-equal-18 rdf:type mf:QueryEvaluationTest ; + mf:name "map-less-equal-18" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-less-equal-19 rdf:type mf:QueryEvaluationTest ; + mf:name "map-less-equal-19" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-less-equal-20 rdf:type mf:QueryEvaluationTest ; + mf:name "map-less-equal-20" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-less-equal-21 rdf:type mf:QueryEvaluationTest ; + mf:name "map-less-equal-21" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-less-equal-error-01 rdf:type mf:QueryEvaluationTest ; + mf:name "map-less-equal-error-01" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-less-equal-error-02 rdf:type mf:QueryEvaluationTest ; + mf:name "map-less-equal-error-02" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-less-equal-null-01 rdf:type mf:QueryEvaluationTest ; + mf:name "map-less-equal-null-01" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-less-equal-null-02 rdf:type mf:QueryEvaluationTest ; + mf:name "map-less-equal-null-02" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-less-equal-null-03 rdf:type mf:QueryEvaluationTest ; + mf:name "map-less-equal-null-03" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-less-equal-null-04 rdf:type mf:QueryEvaluationTest ; + mf:name "map-less-equal-null-04" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-greater-than-01 rdf:type mf:QueryEvaluationTest ; + mf:name "map-greater-than-01" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-greater-than-02 rdf:type mf:QueryEvaluationTest ; + mf:name "map-greater-than-02" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-greater-than-03 rdf:type mf:QueryEvaluationTest ; + mf:name "map-greater-than-03" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-greater-than-04 rdf:type mf:QueryEvaluationTest ; + mf:name "map-greater-than-04" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-greater-than-05 rdf:type mf:QueryEvaluationTest ; + mf:name "map-greater-than-05" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-greater-than-06 rdf:type mf:QueryEvaluationTest ; + mf:name "map-greater-than-06" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-greater-than-07 rdf:type mf:QueryEvaluationTest ; + mf:name "map-greater-than-07" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-greater-than-08 rdf:type mf:QueryEvaluationTest ; + mf:name "map-greater-than-08" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-greater-than-09 rdf:type mf:QueryEvaluationTest ; + mf:name "map-greater-than-09" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-greater-than-10 rdf:type mf:QueryEvaluationTest ; + mf:name "map-greater-than-10" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-greater-than-11 rdf:type mf:QueryEvaluationTest ; + mf:name "map-greater-than-11" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-greater-than-12 rdf:type mf:QueryEvaluationTest ; + mf:name "map-greater-than-12" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-greater-than-13 rdf:type mf:QueryEvaluationTest ; + mf:name "map-greater-than-13" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-greater-than-14 rdf:type mf:QueryEvaluationTest ; + mf:name "map-greater-than-14" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-greater-than-15 rdf:type mf:QueryEvaluationTest ; + mf:name "map-greater-than-15" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-greater-than-16 rdf:type mf:QueryEvaluationTest ; + mf:name "map-greater-than-16" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-greater-than-17 rdf:type mf:QueryEvaluationTest ; + mf:name "map-greater-than-17" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-greater-than-18 rdf:type mf:QueryEvaluationTest ; + mf:name "map-greater-than-18" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-greater-than-19 rdf:type mf:QueryEvaluationTest ; + mf:name "map-greater-than-19" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-greater-than-20 rdf:type mf:QueryEvaluationTest ; + mf:name "map-greater-than-20" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-greater-than-21 rdf:type mf:QueryEvaluationTest ; + mf:name "map-greater-than-21" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-greater-than-error-01 rdf:type mf:QueryEvaluationTest ; + mf:name "map-greater-than-error-01" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-greater-than-error-02 rdf:type mf:QueryEvaluationTest ; + mf:name "map-greater-than-error-02" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-greater-than-null-01 rdf:type mf:QueryEvaluationTest ; + mf:name "map-greater-than-null-01" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-greater-than-null-02 rdf:type mf:QueryEvaluationTest ; + mf:name "map-greater-than-null-02" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-greater-than-null-03 rdf:type mf:QueryEvaluationTest ; + mf:name "map-greater-than-null-03" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-greater-than-null-04 rdf:type mf:QueryEvaluationTest ; + mf:name "map-greater-than-null-04" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-greater-equal-01 rdf:type mf:QueryEvaluationTest ; + mf:name "map-greater-equal-01" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-greater-equal-02 rdf:type mf:QueryEvaluationTest ; + mf:name "map-greater-equal-02" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-greater-equal-03 rdf:type mf:QueryEvaluationTest ; + mf:name "map-greater-equal-03" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-greater-equal-04 rdf:type mf:QueryEvaluationTest ; + mf:name "map-greater-equal-04" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-greater-equal-05 rdf:type mf:QueryEvaluationTest ; + mf:name "map-greater-equal-05" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-greater-equal-06 rdf:type mf:QueryEvaluationTest ; + mf:name "map-greater-equal-06" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-greater-equal-07 rdf:type mf:QueryEvaluationTest ; + mf:name "map-greater-equal-07" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-greater-equal-08 rdf:type mf:QueryEvaluationTest ; + mf:name "map-greater-equal-08" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-greater-equal-09 rdf:type mf:QueryEvaluationTest ; + mf:name "map-greater-equal-09" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-greater-equal-10 rdf:type mf:QueryEvaluationTest ; + mf:name "map-greater-equal-10" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-greater-equal-11 rdf:type mf:QueryEvaluationTest ; + mf:name "map-greater-equal-11" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-greater-equal-12 rdf:type mf:QueryEvaluationTest ; + mf:name "map-greater-equal-12" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-greater-equal-13 rdf:type mf:QueryEvaluationTest ; + mf:name "map-greater-equal-13" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-greater-equal-14 rdf:type mf:QueryEvaluationTest ; + mf:name "map-greater-equal-14" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-greater-equal-15 rdf:type mf:QueryEvaluationTest ; + mf:name "map-greater-equal-15" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-greater-equal-16 rdf:type mf:QueryEvaluationTest ; + mf:name "map-greater-equal-16" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-greater-equal-17 rdf:type mf:QueryEvaluationTest ; + mf:name "map-greater-equal-17" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-greater-equal-18 rdf:type mf:QueryEvaluationTest ; + mf:name "map-greater-equal-18" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-greater-equal-19 rdf:type mf:QueryEvaluationTest ; + mf:name "map-greater-equal-19" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-greater-equal-20 rdf:type mf:QueryEvaluationTest ; + mf:name "map-greater-equal-20" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-greater-equal-21 rdf:type mf:QueryEvaluationTest ; + mf:name "map-greater-equal-21" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-greater-equal-error-01 rdf:type mf:QueryEvaluationTest ; + mf:name "map-greater-equal-error-01" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-greater-equal-error-02 rdf:type mf:QueryEvaluationTest ; + mf:name "map-greater-equal-error-02" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-greater-equal-null-01 rdf:type mf:QueryEvaluationTest ; + mf:name "map-greater-equal-null-01" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-greater-equal-null-02 rdf:type mf:QueryEvaluationTest ; + mf:name "map-greater-equal-null-02" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-greater-equal-null-03 rdf:type mf:QueryEvaluationTest ; + mf:name "map-greater-equal-null-03" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:map-greater-equal-null-04 rdf:type mf:QueryEvaluationTest ; + mf:name "map-greater-equal-null-04" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:merge-01 rdf:type mf:QueryEvaluationTest ; + mf:name "merge-01" ; + mf:feature cdt:merge ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:merge-02 rdf:type mf:QueryEvaluationTest ; + mf:name "merge-02" ; + mf:feature cdt:merge ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:merge-03 rdf:type mf:QueryEvaluationTest ; + mf:name "merge-03" ; + mf:feature cdt:merge ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:merge-04 rdf:type mf:QueryEvaluationTest ; + mf:name "merge-04" ; + mf:feature cdt:merge ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:merge-05 rdf:type mf:QueryEvaluationTest ; + mf:name "merge-05" ; + mf:feature cdt:merge ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:merge-06 rdf:type mf:QueryEvaluationTest ; + mf:name "merge-06" ; + mf:feature cdt:merge ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:merge-07 rdf:type mf:QueryEvaluationTest ; + mf:name "merge-07" ; + mf:feature cdt:merge ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:merge-08 rdf:type mf:QueryEvaluationTest ; + mf:name "merge-08" ; + mf:feature cdt:merge ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:merge-null-01 rdf:type mf:QueryEvaluationTest ; + mf:name "merge-null-01" ; + mf:feature cdt:merge ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:merge-null-02 rdf:type mf:QueryEvaluationTest ; + mf:name "merge-null-02" ; + mf:feature cdt:merge ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:merge-null-03 rdf:type mf:QueryEvaluationTest ; + mf:name "merge-null-03" ; + mf:feature cdt:merge ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:merge-null-04 rdf:type mf:QueryEvaluationTest ; + mf:name "merge-null-04" ; + mf:feature cdt:merge ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:put-01 rdf:type mf:QueryEvaluationTest ; + mf:name "put-01" ; + mf:feature cdt:put ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:put-02 rdf:type mf:QueryEvaluationTest ; + mf:name "put-02" ; + mf:feature cdt:put ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:put-03 rdf:type mf:QueryEvaluationTest ; + mf:name "put-03" ; + mf:feature cdt:put ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:put-04 rdf:type mf:QueryEvaluationTest ; + mf:name "put-04" ; + mf:feature cdt:put ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:put-05 rdf:type mf:QueryEvaluationTest ; + mf:name "put-05" ; + mf:feature cdt:put ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:put-06 rdf:type mf:QueryEvaluationTest ; + mf:name "put-06" ; + mf:feature cdt:put ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:put-07 rdf:type mf:QueryEvaluationTest ; + mf:name "put-07" ; + mf:feature cdt:put ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:put-08 rdf:type mf:QueryEvaluationTest ; + mf:name "put-08" ; + mf:feature cdt:put ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:put-09 rdf:type mf:QueryEvaluationTest ; + mf:name "put-09" ; + mf:feature cdt:put ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:put-10 rdf:type mf:QueryEvaluationTest ; + mf:name "put-10" ; + mf:feature cdt:put ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:put-11 rdf:type mf:QueryEvaluationTest ; + mf:name "put-11" ; + mf:feature cdt:put ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:put-12 rdf:type mf:QueryEvaluationTest ; + mf:name "put-12" ; + mf:feature cdt:put ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:put-13 rdf:type mf:QueryEvaluationTest ; + mf:name "put-13" ; + mf:feature cdt:put ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:put-14 rdf:type mf:QueryEvaluationTest ; + mf:name "put-14" ; + mf:feature cdt:put ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:put-15 rdf:type mf:QueryEvaluationTest ; + mf:name "put-15" ; + mf:feature cdt:put ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:put-error-01 rdf:type mf:QueryEvaluationTest ; + mf:name "put-error-01" ; + mf:feature cdt:put ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:put-error-02 rdf:type mf:QueryEvaluationTest ; + mf:name "put-error-02" ; + mf:feature cdt:put ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:put-error-03 rdf:type mf:QueryEvaluationTest ; + mf:name "put-error-03" ; + mf:feature cdt:put ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:put-error-04 rdf:type mf:QueryEvaluationTest ; + mf:name "put-error-04" ; + mf:feature cdt:put ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:put-error-05 rdf:type mf:QueryEvaluationTest ; + mf:name "put-error-05" ; + mf:feature cdt:put ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:remove-01 rdf:type mf:QueryEvaluationTest ; + mf:name "remove-01" ; + mf:feature cdt:remove ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:remove-02 rdf:type mf:QueryEvaluationTest ; + mf:name "remove-02" ; + mf:feature cdt:remove ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:remove-03 rdf:type mf:QueryEvaluationTest ; + mf:name "remove-03" ; + mf:feature cdt:remove ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:remove-04 rdf:type mf:QueryEvaluationTest ; + mf:name "remove-04" ; + mf:feature cdt:remove ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:remove-05 rdf:type mf:QueryEvaluationTest ; + mf:name "remove-05" ; + mf:feature cdt:remove ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:remove-06 rdf:type mf:QueryEvaluationTest ; + mf:name "remove-06" ; + mf:feature cdt:remove ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:remove-07 rdf:type mf:QueryEvaluationTest ; + mf:name "remove-07" ; + mf:feature cdt:remove ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:remove-08 rdf:type mf:QueryEvaluationTest ; + mf:name "remove-08" ; + mf:feature cdt:remove ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:remove-09 rdf:type mf:QueryEvaluationTest ; + mf:name "remove-09" ; + mf:feature cdt:remove ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:remove-10 rdf:type mf:QueryEvaluationTest ; + mf:name "remove-10" ; + mf:feature cdt:remove ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:remove-11 rdf:type mf:QueryEvaluationTest ; + mf:name "remove-11" ; + mf:feature cdt:remove ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:sameterm-01 rdf:type mf:QueryEvaluationTest ; + mf:name "sameterm-01" ; + rdfs:comment "sameterm test on empty map" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:sameterm-02 rdf:type mf:QueryEvaluationTest ; + mf:name "sameterm-02" ; + rdfs:comment "sameterm test on single-pair" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:sameterm-03 rdf:type mf:QueryEvaluationTest ; + mf:name "sameterm-03" ; + rdfs:comment "sameterm test on same entry, but different lexical form for integers" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:sameterm-04 rdf:type mf:QueryEvaluationTest ; + mf:name "sameterm-04" ; + rdfs:comment "sameterm test on same entry, but different lexical form for whitespace" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:sameterm-05 rdf:type mf:QueryEvaluationTest ; + mf:name "sameterm-05" ; + rdfs:comment "sameterm test on same entry with blank node" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:sameterm-null-01 rdf:type mf:QueryEvaluationTest ; + mf:name "sameterm-null-01" ; + rdfs:comment "sameterm test on list with null (allowed since the test is on the list lexical, not the elements)" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-constructor-01.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-constructor-01.rq new file mode 100644 index 00000000..24c7ceee --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-constructor-01.rq @@ -0,0 +1,7 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( cdt:Map() AS ?map ) + FILTER( ?map = "{}"^^cdt:Map ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-constructor-02.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-constructor-02.rq new file mode 100644 index 00000000..dfee4418 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-constructor-02.rq @@ -0,0 +1,7 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( cdt:Map(1,2,3,4) AS ?map ) + FILTER( ?map = "{1:2, 3:4}"^^cdt:Map ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-constructor-03.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-constructor-03.rq new file mode 100644 index 00000000..b3922cb8 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-constructor-03.rq @@ -0,0 +1,7 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( cdt:Map(1,2,1,4) AS ?map ) + FILTER( ?map = "{1:4}"^^cdt:Map ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-constructor-04.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-constructor-04.rq new file mode 100644 index 00000000..15578009 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-constructor-04.rq @@ -0,0 +1,7 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( cdt:Map(1,"one", '01'^^xsd:integer, "also one") AS ?map ) + FILTER( ?map = "{1:'one', '01'^^: 'also one'}"^^cdt:Map ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-constructor-05.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-constructor-05.rq new file mode 100644 index 00000000..00ce460d --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-constructor-05.rq @@ -0,0 +1,7 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( cdt:Map(1,"one", '01'^^xsd:integer, "also one", 1,"one again") AS ?map ) + FILTER( ?map = "{1:'one again', '01'^^: 'also one'}"^^cdt:Map ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-constructor-06.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-constructor-06.rq new file mode 100644 index 00000000..141e12a3 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-constructor-06.rq @@ -0,0 +1,7 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( cdt:Map("hello"@en,"one", "hello", "also one") AS ?map ) + FILTER( ?map = "{'hello'@en:'one', 'hello':'also one'}"^^cdt:Map ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-constructor-07.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-constructor-07.rq new file mode 100644 index 00000000..152af33f --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-constructor-07.rq @@ -0,0 +1,7 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( cdt:Map(,"uri", "hello", ) AS ?map ) + FILTER( ?map = "{:'uri', 'hello':}"^^cdt:Map ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-constructor-08.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-constructor-08.rq new file mode 100644 index 00000000..44d9c1f6 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-constructor-08.rq @@ -0,0 +1,7 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( cdt:Map(1,2, ?unbound, 4, 5,6) AS ?map ) + FILTER( ?map = "{1:2, 5:6}"^^cdt:Map ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-constructor-09.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-constructor-09.rq new file mode 100644 index 00000000..ab2f4bda --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-constructor-09.rq @@ -0,0 +1,7 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( cdt:Map(1,2, BNODE(), 4, 5,6) AS ?map ) + FILTER( ?map = "{1:2, 5:6}"^^cdt:Map ) # a blank node is not a valid map key +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-constructor-10.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-constructor-10.rq new file mode 100644 index 00000000..3a64f2c8 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-constructor-10.rq @@ -0,0 +1,15 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( cdt:Map(1,2, 3,?unbound) AS ?map ) + + FILTER( BOUND(?map) ) # check that there was no error + FILTER( cdt:size(?map) = 2 ) + + FILTER( cdt:get(?map,1) = 2 ) + + FILTER( cdt:containsKey(?map,3) ) + BIND( cdt:get(?map,3) AS ?v2 ) + FILTER( ! BOUND(?v2) ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-constructor-11.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-constructor-11.rq new file mode 100644 index 00000000..b3451610 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-constructor-11.rq @@ -0,0 +1,17 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( BNODE() AS ?bnode ) + BIND( cdt:Map(1,2, 3,?bnode) AS ?map ) + + FILTER( BOUND(?map) ) # check that there was no error + FILTER( cdt:size(?map) = 2 ) + + FILTER( cdt:get(?map,1) = 2 ) + + FILTER( cdt:containsKey(?map,3) ) + BIND( cdt:get(?map,3) AS ?v2 ) + FILTER( isBlank(?v2) ) + FILTER( SAMETERM(?v2, ?bnode) ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-equals-01.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-equals-01.rq new file mode 100644 index 00000000..67240ba0 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-equals-01.rq @@ -0,0 +1,6 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + FILTER("{ }"^^cdt:Map = "{}"^^cdt:Map) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-equals-02.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-equals-02.rq new file mode 100644 index 00000000..b0159821 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-equals-02.rq @@ -0,0 +1,6 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + FILTER("{ 1: 1 }"^^cdt:Map = "{1:1}"^^cdt:Map) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-equals-03.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-equals-03.rq new file mode 100644 index 00000000..28e6fcde --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-equals-03.rq @@ -0,0 +1,6 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + FILTER("{1:2}"^^cdt:Map = "{ 1 : '2'^^ }"^^cdt:Map) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-equals-04.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-equals-04.rq new file mode 100644 index 00000000..2f794502 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-equals-04.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( cdt:Map(1,2) AS ?map) + BIND( ?map = "{'+1'^^ : 2.0}"^^cdt:Map AS ?result) + FILTER( ! ?result ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-equals-05.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-equals-05.rq new file mode 100644 index 00000000..e1a47e0b --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-equals-05.rq @@ -0,0 +1,6 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + FILTER( "{:true}"^^cdt:Map = "{ : true }"^^cdt:Map ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-equals-06.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-equals-06.rq new file mode 100644 index 00000000..83306e17 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-equals-06.rq @@ -0,0 +1,7 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "{ 1 : _:b1 }"^^cdt:Map = "{1:_:b1}"^^cdt:Map ) AS ?result ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-equals-07.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-equals-07.rq new file mode 100644 index 00000000..9364290b --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-equals-07.rq @@ -0,0 +1,7 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "{1:_:b1}"^^cdt:Map = "{1:_:b2}"^^cdt:Map ) AS ?result ) + FILTER( ! BOUND(?result) ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-equals-08.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-equals-08.rq new file mode 100644 index 00000000..528eebd5 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-equals-08.rq @@ -0,0 +1,9 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( BNODE() AS ?x ) + BIND( BNODE() AS ?y ) + BIND( ( cdt:Map(1, ?x) = cdt:Map(1, ?y) ) AS ?result ) + FILTER( ! BOUND(?result) ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-equals-09.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-equals-09.rq new file mode 100644 index 00000000..323c37be --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-equals-09.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( BNODE() AS ?x ) + BIND( ( cdt:Map(1, ?x) = cdt:Map(1, ?x) ) AS ?result ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-equals-null-01.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-equals-null-01.rq new file mode 100644 index 00000000..939ad2aa --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-equals-null-01.rq @@ -0,0 +1,9 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND("{ 1 : null }"^^cdt:Map = "{1:null}"^^cdt:Map AS ?result) + + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-equals-null-02.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-equals-null-02.rq new file mode 100644 index 00000000..3ab12665 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-equals-null-02.rq @@ -0,0 +1,10 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( cdt:Map(1, 44) AS ?map ) + BIND("{1:null}"^^cdt:Map = ?map AS ?result) + + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-01.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-01.rq new file mode 100644 index 00000000..d6070ad3 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-01.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "{}"^^cdt:Map >= "{ }"^^cdt:Map ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-02.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-02.rq new file mode 100644 index 00000000..cdca9fe7 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-02.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "{}"^^cdt:Map >= "{1:42}"^^cdt:Map ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-03.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-03.rq new file mode 100644 index 00000000..52a9b41e --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-03.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "{1:42}"^^cdt:Map >= "{}"^^cdt:Map ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-04.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-04.rq new file mode 100644 index 00000000..3cd6db24 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-04.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "{1:42}"^^cdt:Map >= "{ 1:42 }"^^cdt:Map ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-05.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-05.rq new file mode 100644 index 00000000..8f90f42c --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-05.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "{1:42}"^^cdt:Map >= "{2:42}"^^cdt:Map ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-06.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-06.rq new file mode 100644 index 00000000..5e5feae5 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-06.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "{2:42}"^^cdt:Map >= "{1:42}"^^cdt:Map ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-07.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-07.rq new file mode 100644 index 00000000..e7754c89 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-07.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "{1:42}"^^cdt:Map >= "{1:43}"^^cdt:Map ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-08.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-08.rq new file mode 100644 index 00000000..b5a8ad27 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-08.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "{1:43}"^^cdt:Map >= "{1:42}"^^cdt:Map ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-09.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-09.rq new file mode 100644 index 00000000..6b25434e --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-09.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "{1:42, 2:42}"^^cdt:Map >= "{2:42, 1:43}"^^cdt:Map ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-10.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-10.rq new file mode 100644 index 00000000..4657dea4 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-10.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "{1:42, 2:42}"^^cdt:Map >= "{2:43, 1:42}"^^cdt:Map ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-11.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-11.rq new file mode 100644 index 00000000..bc9e7749 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-11.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "{1:42, 2:43}"^^cdt:Map >= "{2:42, 1:42}"^^cdt:Map ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-12.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-12.rq new file mode 100644 index 00000000..0b440bee --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-12.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "{1:42}"^^cdt:Map >= "{2:43, 1:42}"^^cdt:Map ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-13.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-13.rq new file mode 100644 index 00000000..5aac5cb6 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-13.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "{1:42, 2:43}"^^cdt:Map >= "{1:42}"^^cdt:Map ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-14.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-14.rq new file mode 100644 index 00000000..2d85c9c0 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-14.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "{1:41, 2:43}"^^cdt:Map >= "{1:42}"^^cdt:Map ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-15.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-15.rq new file mode 100644 index 00000000..586856eb --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-15.rq @@ -0,0 +1,10 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( "{'001'^^ : 41}"^^cdt:Map AS ?map1 ) + BIND( "{'01'^^ : 41}"^^cdt:Map AS ?map2 ) + BIND( (?map1 >= ?map2 ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-16.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-16.rq new file mode 100644 index 00000000..cee7618d --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-16.rq @@ -0,0 +1,10 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( "{1: '001'^^ }"^^cdt:Map AS ?map1 ) + BIND( "{1: '01'^^ }"^^cdt:Map AS ?map2 ) + BIND( (?map1 >= ?map2 ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-17.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-17.rq new file mode 100644 index 00000000..ff892fdf --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-17.rq @@ -0,0 +1,10 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( "{'2'^^ : 41}"^^cdt:Map AS ?map1 ) + BIND( "{'1'^^ : 41}"^^cdt:Map AS ?map2 ) + BIND( (?map1 >= ?map2 ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-18.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-18.rq new file mode 100644 index 00000000..44f4dddc --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-18.rq @@ -0,0 +1,10 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( "{'1'@sv : 41}"^^cdt:Map AS ?map1 ) + BIND( "{'2'@en : 41}"^^cdt:Map AS ?map2 ) + BIND( (?map1 >= ?map2 ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-19.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-19.rq new file mode 100644 index 00000000..b39aa6a4 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-19.rq @@ -0,0 +1,10 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( "{'1'@sv : 41}"^^cdt:Map AS ?map1 ) + BIND( "{'1'@en : 41}"^^cdt:Map AS ?map2 ) + BIND( (?map1 >= ?map2 ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-20.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-20.rq new file mode 100644 index 00000000..cf55e6c1 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-20.rq @@ -0,0 +1,10 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( "{1 : 41}"^^cdt:Map AS ?map1 ) + BIND( "{ : 41}"^^cdt:Map AS ?map2 ) + BIND( (?map1 >= ?map2 ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-21.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-21.rq new file mode 100644 index 00000000..cba0a92f --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-21.rq @@ -0,0 +1,10 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( "{ : 41}"^^cdt:Map AS ?map1 ) + BIND( "{ : 41}"^^cdt:Map AS ?map2 ) + BIND( (?map1 >= ?map2 ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-error-01.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-error-01.rq new file mode 100644 index 00000000..0211b94e --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-error-01.rq @@ -0,0 +1,10 @@ +PREFIX cdt: +PREFIX xsd: + +# IRIs as map values cannot be compared based on < +ASK { + BIND( cdt:Map( 1, ) AS ?map1 ) + BIND( cdt:Map( 1, ) AS ?map2 ) + BIND( (?map1 >= ?map2 ) AS ?result ) + FILTER( ! BOUND(?result) ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-error-02.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-error-02.rq new file mode 100644 index 00000000..850dfecf --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-error-02.rq @@ -0,0 +1,10 @@ +PREFIX cdt: +PREFIX xsd: + +# IRIs as map values cannot be compared to literals +ASK { + BIND( cdt:Map( 1, ) AS ?map1 ) + BIND( cdt:Map( 1, 42 ) AS ?map2 ) + BIND( (?map1 >= ?map2 ) AS ?result ) + FILTER( ! BOUND(?result) ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-null-01.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-null-01.rq new file mode 100644 index 00000000..978b03aa --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-null-01.rq @@ -0,0 +1,9 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( cdt:Map( 1, ?undef ) AS ?map1 ) + BIND( cdt:Map( 1, 42 ) AS ?map2 ) + BIND( ( ?map1 >= ?map2 ) AS ?result ) + FILTER( ! BOUND(?result) ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-null-02.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-null-02.rq new file mode 100644 index 00000000..b5d45b30 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-null-02.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "{1:42, 2:null}"^^cdt:Map >= "{1:43, 2:42}"^^cdt:Map ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-null-03.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-null-03.rq new file mode 100644 index 00000000..31dc9171 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-null-03.rq @@ -0,0 +1,12 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( cdt:Map(1, ?undef1) AS ?map1 ) + BIND( cdt:Map(1, ?undef2) AS ?map2 ) + + BIND( ( ?map1 >= ?map2 ) AS ?result ) + + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-null-04.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-null-04.rq new file mode 100644 index 00000000..c92b1fae --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-equal-null-04.rq @@ -0,0 +1,9 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "{1:null}"^^cdt:Map >= "{1:null, 2:42}"^^cdt:Map ) AS ?result ) + + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-01.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-01.rq new file mode 100644 index 00000000..b7b05e78 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-01.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "{}"^^cdt:Map > "{ }"^^cdt:Map ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-02.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-02.rq new file mode 100644 index 00000000..ec3ec47d --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-02.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "{}"^^cdt:Map > "{1:42}"^^cdt:Map ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-03.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-03.rq new file mode 100644 index 00000000..8035cdd5 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-03.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "{1:42}"^^cdt:Map > "{}"^^cdt:Map ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-04.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-04.rq new file mode 100644 index 00000000..4508c72f --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-04.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "{1:42}"^^cdt:Map > "{ 1:42 }"^^cdt:Map ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-05.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-05.rq new file mode 100644 index 00000000..e278f31d --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-05.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "{1:42}"^^cdt:Map > "{2:42}"^^cdt:Map ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-06.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-06.rq new file mode 100644 index 00000000..d6170aad --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-06.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "{2:42}"^^cdt:Map > "{1:42}"^^cdt:Map ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-07.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-07.rq new file mode 100644 index 00000000..a10c9100 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-07.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "{1:42}"^^cdt:Map > "{1:43}"^^cdt:Map ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-08.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-08.rq new file mode 100644 index 00000000..6b00305e --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-08.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "{1:43}"^^cdt:Map > "{1:42}"^^cdt:Map ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-09.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-09.rq new file mode 100644 index 00000000..0cc5ce6d --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-09.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "{1:42, 2:42}"^^cdt:Map > "{2:42, 1:43}"^^cdt:Map ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-10.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-10.rq new file mode 100644 index 00000000..65015f81 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-10.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "{1:42, 2:42}"^^cdt:Map > "{2:43, 1:42}"^^cdt:Map ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-11.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-11.rq new file mode 100644 index 00000000..bb865cff --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-11.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "{1:42, 2:43}"^^cdt:Map > "{2:42, 1:42}"^^cdt:Map ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-12.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-12.rq new file mode 100644 index 00000000..7661faa2 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-12.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "{1:42}"^^cdt:Map > "{2:43, 1:42}"^^cdt:Map ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-13.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-13.rq new file mode 100644 index 00000000..709105e2 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-13.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "{1:42, 2:43}"^^cdt:Map > "{1:42}"^^cdt:Map ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-14.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-14.rq new file mode 100644 index 00000000..6f0fe6ee --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-14.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "{1:41, 2:43}"^^cdt:Map > "{1:42}"^^cdt:Map ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-15.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-15.rq new file mode 100644 index 00000000..41c1f787 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-15.rq @@ -0,0 +1,10 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( "{'001'^^ : 41}"^^cdt:Map AS ?map1 ) + BIND( "{'01'^^ : 41}"^^cdt:Map AS ?map2 ) + BIND( (?map1 > ?map2 ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-16.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-16.rq new file mode 100644 index 00000000..9d93b5ed --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-16.rq @@ -0,0 +1,10 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( "{1: '001'^^ }"^^cdt:Map AS ?map1 ) + BIND( "{1: '01'^^ }"^^cdt:Map AS ?map2 ) + BIND( (?map1 > ?map2 ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-17.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-17.rq new file mode 100644 index 00000000..0ef9f033 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-17.rq @@ -0,0 +1,10 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( "{'2'^^ : 41}"^^cdt:Map AS ?map1 ) + BIND( "{'1'^^ : 41}"^^cdt:Map AS ?map2 ) + BIND( (?map1 > ?map2 ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-18.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-18.rq new file mode 100644 index 00000000..6b446e74 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-18.rq @@ -0,0 +1,10 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( "{'1'@sv : 41}"^^cdt:Map AS ?map1 ) + BIND( "{'2'@en : 41}"^^cdt:Map AS ?map2 ) + BIND( (?map1 > ?map2 ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-19.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-19.rq new file mode 100644 index 00000000..c93b6592 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-19.rq @@ -0,0 +1,10 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( "{'1'@sv : 41}"^^cdt:Map AS ?map1 ) + BIND( "{'1'@en : 41}"^^cdt:Map AS ?map2 ) + BIND( (?map1 > ?map2 ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-20.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-20.rq new file mode 100644 index 00000000..4cd9c949 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-20.rq @@ -0,0 +1,10 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( "{1 : 41}"^^cdt:Map AS ?map1 ) + BIND( "{ : 41}"^^cdt:Map AS ?map2 ) + BIND( (?map1 > ?map2 ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-21.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-21.rq new file mode 100644 index 00000000..08e1cd30 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-21.rq @@ -0,0 +1,10 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( "{ : 41}"^^cdt:Map AS ?map1 ) + BIND( "{ : 41}"^^cdt:Map AS ?map2 ) + BIND( (?map1 > ?map2 ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-error-01.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-error-01.rq new file mode 100644 index 00000000..f660f545 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-error-01.rq @@ -0,0 +1,10 @@ +PREFIX cdt: +PREFIX xsd: + +# IRIs as map values cannot be compared based on < +ASK { + BIND( cdt:Map(1, ) AS ?map1 ) + BIND( "{1, }"^^cdt:Map AS ?map2 ) + BIND( (?map1 > ?map2) AS ?result ) + FILTER( ! BOUND(?result) ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-error-02.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-error-02.rq new file mode 100644 index 00000000..d7f7981a --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-error-02.rq @@ -0,0 +1,10 @@ +PREFIX cdt: +PREFIX xsd: + +# IRIs as map values cannot be compared to literals +ASK { + BIND( cdt:Map(1, ) AS ?map1 ) + BIND( "{1: 42}"^^cdt:Map AS ?map2 ) + BIND( (?map1 > ?map2 ) AS ?result ) + FILTER( ! BOUND(?result) ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-null-01.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-null-01.rq new file mode 100644 index 00000000..baca62c2 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-null-01.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( cdt:Map(1, ?undef) AS ?map1 ) + BIND( ( ?map1 > "{1:42}"^^cdt:Map ) AS ?result ) + FILTER( ! BOUND(?result) ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-null-02.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-null-02.rq new file mode 100644 index 00000000..c73288ba --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-null-02.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "{1:42, 2:null}"^^cdt:Map > "{1:43, 2:42}"^^cdt:Map ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-null-03.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-null-03.rq new file mode 100644 index 00000000..ad0ef387 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-null-03.rq @@ -0,0 +1,10 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( cdt:Map(1, ?undef) AS ?map1 ) + BIND( ( ?map1 > "{1:null}"^^cdt:Map ) AS ?result ) + + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-null-04.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-null-04.rq new file mode 100644 index 00000000..812e032e --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-greater-than-null-04.rq @@ -0,0 +1,9 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "{1:null}"^^cdt:Map > "{1:null, 2:42}"^^cdt:Map ) AS ?result ) + + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-01.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-01.rq new file mode 100644 index 00000000..495f5f3c --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-01.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "{}"^^cdt:Map <= "{ }"^^cdt:Map ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-02.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-02.rq new file mode 100644 index 00000000..f7ed335f --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-02.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "{}"^^cdt:Map <= "{1:42}"^^cdt:Map ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-03.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-03.rq new file mode 100644 index 00000000..732181a5 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-03.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "{1:42}"^^cdt:Map <= "{}"^^cdt:Map ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-04.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-04.rq new file mode 100644 index 00000000..d6a1b95b --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-04.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "{1:42}"^^cdt:Map <= "{ 1:42 }"^^cdt:Map ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-05.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-05.rq new file mode 100644 index 00000000..bb808d6d --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-05.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "{1:42}"^^cdt:Map <= "{2:42}"^^cdt:Map ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-06.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-06.rq new file mode 100644 index 00000000..fbd0320b --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-06.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "{2:42}"^^cdt:Map <= "{1:42}"^^cdt:Map ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-07.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-07.rq new file mode 100644 index 00000000..84b26d1d --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-07.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "{1:42}"^^cdt:Map <= "{1:43}"^^cdt:Map ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-08.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-08.rq new file mode 100644 index 00000000..7dfdb4cf --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-08.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "{1:43}"^^cdt:Map <= "{1:42}"^^cdt:Map ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-09.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-09.rq new file mode 100644 index 00000000..fe2a2ba1 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-09.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "{1:42, 2:42}"^^cdt:Map <= "{2:42, 1:43}"^^cdt:Map ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-10.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-10.rq new file mode 100644 index 00000000..1d440990 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-10.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "{1:42, 2:42}"^^cdt:Map <= "{2:43, 1:42}"^^cdt:Map ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-11.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-11.rq new file mode 100644 index 00000000..d8e2bb02 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-11.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "{1:42, 2:43}"^^cdt:Map <= "{2:42, 1:42}"^^cdt:Map ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-12.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-12.rq new file mode 100644 index 00000000..36bd3b10 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-12.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "{1:42}"^^cdt:Map <= "{2:43, 1:42}"^^cdt:Map ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-13.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-13.rq new file mode 100644 index 00000000..7bd85cf7 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-13.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "{1:42, 2:43}"^^cdt:Map <= "{1:42}"^^cdt:Map ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-14.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-14.rq new file mode 100644 index 00000000..0ce22f47 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-14.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "{1:41, 2:43}"^^cdt:Map <= "{1:42}"^^cdt:Map ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-15.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-15.rq new file mode 100644 index 00000000..e0fb8c36 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-15.rq @@ -0,0 +1,10 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( "{'001'^^ : 41}"^^cdt:Map AS ?map1 ) + BIND( "{'01'^^ : 41}"^^cdt:Map AS ?map2 ) + BIND( (?map1 <= ?map2 ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-16.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-16.rq new file mode 100644 index 00000000..fd20e5bb --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-16.rq @@ -0,0 +1,10 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( "{1: '001'^^ }"^^cdt:Map AS ?map1 ) + BIND( "{1: '01'^^ }"^^cdt:Map AS ?map2 ) + BIND( (?map1 <= ?map2 ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-17.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-17.rq new file mode 100644 index 00000000..25a2f798 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-17.rq @@ -0,0 +1,10 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( "{'2'^^ : 41}"^^cdt:Map AS ?map1 ) + BIND( "{'1'^^ : 41}"^^cdt:Map AS ?map2 ) + BIND( (?map1 <= ?map2 ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-18.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-18.rq new file mode 100644 index 00000000..f51f4fac --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-18.rq @@ -0,0 +1,10 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( "{'1'@sv : 41}"^^cdt:Map AS ?map1 ) + BIND( "{'2'@en : 41}"^^cdt:Map AS ?map2 ) + BIND( (?map1 <= ?map2 ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-19.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-19.rq new file mode 100644 index 00000000..6d3b223e --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-19.rq @@ -0,0 +1,10 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( "{'1'@sv : 41}"^^cdt:Map AS ?map1 ) + BIND( "{'1'@en : 41}"^^cdt:Map AS ?map2 ) + BIND( (?map1 <= ?map2 ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-20.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-20.rq new file mode 100644 index 00000000..d8fa4560 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-20.rq @@ -0,0 +1,10 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( "{1 : 41}"^^cdt:Map AS ?map1 ) + BIND( "{ : 41}"^^cdt:Map AS ?map2 ) + BIND( (?map1 <= ?map2 ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-21.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-21.rq new file mode 100644 index 00000000..7b3d87ec --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-21.rq @@ -0,0 +1,10 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( "{ : 41}"^^cdt:Map AS ?map1 ) + BIND( "{ : 41}"^^cdt:Map AS ?map2 ) + BIND( (?map1 <= ?map2 ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-error-01.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-error-01.rq new file mode 100644 index 00000000..cf5f3f34 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-error-01.rq @@ -0,0 +1,10 @@ +PREFIX cdt: +PREFIX xsd: + +# IRIs as map values cannot be compared based on < +ASK { + BIND( cdt:Map(1, ) AS ?map1 ) + BIND( "{1: }"^^cdt:Map AS ?map2 ) + BIND( (?map1 <= ?map2 ) AS ?result ) + FILTER( ! BOUND(?result) ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-error-02.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-error-02.rq new file mode 100644 index 00000000..3ddae2fe --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-error-02.rq @@ -0,0 +1,10 @@ +PREFIX cdt: +PREFIX xsd: + +# IRIs as map values cannot be compared to literals +ASK { + BIND( cdt:Map(1, ) AS ?map1 ) + BIND( "{1: 42}"^^cdt:Map AS ?map2 ) + BIND( (?map1 <= ?map2 ) AS ?result ) + FILTER( ! BOUND(?result) ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-null-01.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-null-01.rq new file mode 100644 index 00000000..eb1d1bdb --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-null-01.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( cdt:Map(1, ?undef) AS ?map1 ) + BIND( ( ?map1 <= "{1:42}"^^cdt:Map ) AS ?result ) + FILTER( ! BOUND(?result) ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-null-02.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-null-02.rq new file mode 100644 index 00000000..9733a4ee --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-null-02.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "{1:42, 2:null}"^^cdt:Map < "{1:43, 2:42}"^^cdt:Map ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-null-03.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-null-03.rq new file mode 100644 index 00000000..3f9e5dc8 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-null-03.rq @@ -0,0 +1,10 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( cdt:Map(1, ?undef) AS ?map1 ) + BIND( ( ?map1 < "{1:null}"^^cdt:Map ) AS ?result ) + + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-null-04.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-null-04.rq new file mode 100644 index 00000000..2a9553d4 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-less-equal-null-04.rq @@ -0,0 +1,9 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "{1:null}"^^cdt:Map < "{1:null, 2:42}"^^cdt:Map ) AS ?result ) + + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-01.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-01.rq new file mode 100644 index 00000000..301d4998 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-01.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "{}"^^cdt:Map < "{ }"^^cdt:Map ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-02.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-02.rq new file mode 100644 index 00000000..f05c1818 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-02.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "{}"^^cdt:Map < "{1:42}"^^cdt:Map ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-03.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-03.rq new file mode 100644 index 00000000..ae7eac4c --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-03.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "{1:42}"^^cdt:Map < "{}"^^cdt:Map ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-04.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-04.rq new file mode 100644 index 00000000..a458eb49 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-04.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "{1:42}"^^cdt:Map < "{ 1:42 }"^^cdt:Map ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-05.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-05.rq new file mode 100644 index 00000000..114b3fcb --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-05.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "{1:42}"^^cdt:Map < "{2:42}"^^cdt:Map ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-06.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-06.rq new file mode 100644 index 00000000..3b95e737 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-06.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "{2:42}"^^cdt:Map < "{1:42}"^^cdt:Map ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-07.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-07.rq new file mode 100644 index 00000000..962a21c7 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-07.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "{1:42}"^^cdt:Map < "{1:43}"^^cdt:Map ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-08.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-08.rq new file mode 100644 index 00000000..98ea6502 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-08.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "{1:43}"^^cdt:Map < "{1:42}"^^cdt:Map ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-09.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-09.rq new file mode 100644 index 00000000..537a727c --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-09.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "{1:42, 2:42}"^^cdt:Map < "{2:42, 1:43}"^^cdt:Map ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-10.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-10.rq new file mode 100644 index 00000000..67c0bfce --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-10.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "{1:42, 2:42}"^^cdt:Map < "{2:43, 1:42}"^^cdt:Map ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-11.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-11.rq new file mode 100644 index 00000000..b8474916 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-11.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "{1:42, 2:43}"^^cdt:Map < "{2:42, 1:42}"^^cdt:Map ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-12.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-12.rq new file mode 100644 index 00000000..c4bdfb35 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-12.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "{1:42}"^^cdt:Map < "{2:43, 1:42}"^^cdt:Map ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-13.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-13.rq new file mode 100644 index 00000000..bccc0b7f --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-13.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "{1:42, 2:43}"^^cdt:Map < "{1:42}"^^cdt:Map ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-14.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-14.rq new file mode 100644 index 00000000..ac0f834e --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-14.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "{1:41, 2:43}"^^cdt:Map < "{1:42}"^^cdt:Map ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-15.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-15.rq new file mode 100644 index 00000000..5fbda080 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-15.rq @@ -0,0 +1,10 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( "{'001'^^ : 41}"^^cdt:Map AS ?map1 ) + BIND( "{'01'^^ : 41}"^^cdt:Map AS ?map2 ) + BIND( (?map1 < ?map2 ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-16.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-16.rq new file mode 100644 index 00000000..631106d4 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-16.rq @@ -0,0 +1,10 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( "{1: '001'^^ }"^^cdt:Map AS ?map1 ) + BIND( "{1: '01'^^ }"^^cdt:Map AS ?map2 ) + BIND( (?map1 < ?map2 ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-17.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-17.rq new file mode 100644 index 00000000..24abc60d --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-17.rq @@ -0,0 +1,10 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( "{'2'^^ : 41}"^^cdt:Map AS ?map1 ) + BIND( "{'1'^^ : 41}"^^cdt:Map AS ?map2 ) + BIND( (?map1 < ?map2 ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-18.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-18.rq new file mode 100644 index 00000000..c52fbf82 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-18.rq @@ -0,0 +1,10 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( "{'1'@sv : 41}"^^cdt:Map AS ?map1 ) + BIND( "{'2'@en : 41}"^^cdt:Map AS ?map2 ) + BIND( (?map1 < ?map2 ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-19.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-19.rq new file mode 100644 index 00000000..b128fa94 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-19.rq @@ -0,0 +1,10 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( "{'1'@sv : 41}"^^cdt:Map AS ?map1 ) + BIND( "{'1'@en : 41}"^^cdt:Map AS ?map2 ) + BIND( (?map1 < ?map2 ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-20.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-20.rq new file mode 100644 index 00000000..99b50c6e --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-20.rq @@ -0,0 +1,10 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( "{1 : 41}"^^cdt:Map AS ?map1 ) + BIND( "{ : 41}"^^cdt:Map AS ?map2 ) + BIND( (?map1 < ?map2 ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-21.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-21.rq new file mode 100644 index 00000000..dd01d5ab --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-21.rq @@ -0,0 +1,10 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( "{ : 41}"^^cdt:Map AS ?map1 ) + BIND( "{ : 41}"^^cdt:Map AS ?map2 ) + BIND( (?map1 < ?map2 ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = false ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-error-01.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-error-01.rq new file mode 100644 index 00000000..5c71e34c --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-error-01.rq @@ -0,0 +1,10 @@ +PREFIX cdt: +PREFIX xsd: + +# IRIs as map values cannot be compared based on < +ASK { + BIND( cdt:Map(1, ) AS ?map1 ) + BIND( "{1: }"^^cdt:Map AS ?map2 ) + BIND( (?map1 < ?map2 ) AS ?result ) + FILTER( ! BOUND(?result) ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-error-02.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-error-02.rq new file mode 100644 index 00000000..6a408c8f --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-error-02.rq @@ -0,0 +1,10 @@ +PREFIX cdt: +PREFIX xsd: + +# IRIs as map values cannot be compared to literals +ASK { + BIND( cdt:Map(1, ) AS ?map1 ) + BIND( "{1: 42}"^^cdt:Map AS ?map2 ) + BIND( (?map1 < ?map2 ) AS ?result ) + FILTER( ! BOUND(?result) ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-null-01.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-null-01.rq new file mode 100644 index 00000000..dfa8fdfd --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-null-01.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( cdt:Map(1, ?undef) AS ?map1 ) + BIND( ( ?map1 < "{1:42}"^^cdt:Map ) AS ?result ) + FILTER( ! BOUND(?result) ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-null-02.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-null-02.rq new file mode 100644 index 00000000..9733a4ee --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-null-02.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "{1:42, 2:null}"^^cdt:Map < "{1:43, 2:42}"^^cdt:Map ) AS ?result ) + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-null-03.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-null-03.rq new file mode 100644 index 00000000..cfc6786a --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-null-03.rq @@ -0,0 +1,10 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( cdt:Map(1, ?undef) AS ?map1 ) + BIND( ( ?map1 <= "{1:null}"^^cdt:Map ) AS ?result ) + + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-null-04.rq b/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-null-04.rq new file mode 100644 index 00000000..d9a3a57b --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/map-less-than-null-04.rq @@ -0,0 +1,9 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( ( "{1:null}"^^cdt:Map <= "{1:null, 2:42}"^^cdt:Map ) AS ?result ) + + FILTER( BOUND(?result) ) + FILTER( ?result = true ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/merge-01.rq b/src/test/resources/sparql-cdts/tests/map-functions/merge-01.rq new file mode 100644 index 00000000..eed6a712 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/merge-01.rq @@ -0,0 +1,10 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( "{}"^^cdt:Map AS ?map1 ) + BIND( "{}"^^cdt:Map AS ?map2 ) + BIND( cdt:merge(?map1, ?map2) AS ?merged ) + + FILTER( ?merged = "{}"^^cdt:Map ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/merge-02.rq b/src/test/resources/sparql-cdts/tests/map-functions/merge-02.rq new file mode 100644 index 00000000..75057208 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/merge-02.rq @@ -0,0 +1,10 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( "{1: 'one'}"^^cdt:Map AS ?map1 ) + BIND( "{}"^^cdt:Map AS ?map2 ) + BIND( cdt:merge(?map1, ?map2) AS ?merged ) + + FILTER( ?merged = "{1: 'one'}"^^cdt:Map ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/merge-03.rq b/src/test/resources/sparql-cdts/tests/map-functions/merge-03.rq new file mode 100644 index 00000000..d91a4b51 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/merge-03.rq @@ -0,0 +1,10 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( "{}"^^cdt:Map AS ?map1 ) + BIND( "{1: 'one'}"^^cdt:Map AS ?map2 ) + BIND( cdt:merge(?map1, ?map2) AS ?merged ) + + FILTER( ?merged = "{1: 'one'}"^^cdt:Map ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/merge-04.rq b/src/test/resources/sparql-cdts/tests/map-functions/merge-04.rq new file mode 100644 index 00000000..f626e35e --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/merge-04.rq @@ -0,0 +1,10 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( "{1: 'one'}"^^cdt:Map AS ?map1 ) + BIND( "{2: 'two'}"^^cdt:Map AS ?map2 ) + BIND( cdt:merge(?map1, ?map2) AS ?merged ) + + FILTER( ?merged = "{1: 'one', 2: 'two'}"^^cdt:Map ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/merge-05.rq b/src/test/resources/sparql-cdts/tests/map-functions/merge-05.rq new file mode 100644 index 00000000..fa12ec8e --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/merge-05.rq @@ -0,0 +1,10 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( "{1: 'one', 2: 'two'}"^^cdt:Map AS ?map1 ) + BIND( "{1: 'another one', 3: 'three'}"^^cdt:Map AS ?map2 ) + BIND( cdt:merge(?map1, ?map2) AS ?merged ) + + FILTER( ?merged = "{1: 'one', 2: 'two', 3: 'three'}"^^cdt:Map ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/merge-06.rq b/src/test/resources/sparql-cdts/tests/map-functions/merge-06.rq new file mode 100644 index 00000000..82142c1b --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/merge-06.rq @@ -0,0 +1,10 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( "{1: 'one', 2: 'two'}"^^cdt:Map AS ?map1 ) + BIND( "{'01'^^: 'another one', 3: 'three'}"^^cdt:Map AS ?map2 ) + BIND( cdt:merge(?map1, ?map2) AS ?merged ) + + FILTER( ?merged = "{1: 'one', '01'^^: 'another one', 2: 'two', 3: 'three'}"^^cdt:Map ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/merge-07.rq b/src/test/resources/sparql-cdts/tests/map-functions/merge-07.rq new file mode 100644 index 00000000..2ee2f6ef --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/merge-07.rq @@ -0,0 +1,10 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( "{: 'one', 2: 'two'}"^^cdt:Map AS ?map1 ) + BIND( "{'hello'@en: }"^^cdt:Map AS ?map2 ) + BIND( cdt:merge(?map1, ?map2) AS ?merged ) + + FILTER( ?merged = "{: 'one', 2: 'two', 'hello'@en: }"^^cdt:Map ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/merge-08.rq b/src/test/resources/sparql-cdts/tests/map-functions/merge-08.rq new file mode 100644 index 00000000..72326fcc --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/merge-08.rq @@ -0,0 +1,10 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( "{: 'one', 'hello': 42}"^^cdt:Map AS ?map1 ) + BIND( "{: 'ONE', 'hello'@en: }"^^cdt:Map AS ?map2 ) + BIND( cdt:merge(?map1, ?map2) AS ?merged ) + + FILTER( ?merged = "{: 'one', 'hello': 42, 'hello'@en: }"^^cdt:Map ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/merge-null-01.rq b/src/test/resources/sparql-cdts/tests/map-functions/merge-null-01.rq new file mode 100644 index 00000000..7118071d --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/merge-null-01.rq @@ -0,0 +1,18 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( "{1: null, 2: 'two'}"^^cdt:Map AS ?map1 ) + BIND( "{3: 'three'}"^^cdt:Map AS ?map2 ) + BIND( cdt:merge(?map1, ?map2) AS ?merged ) + + FILTER( cdt:size(?merged) = 3 ) + + FILTER( cdt:containsKey(?merged,1) ) + BIND( cdt:get(?merged,1) AS ?x ) + FILTER( ! BOUND(?x) ) + + FILTER( cdt:get(?merged,2) = "two" ) + + FILTER( cdt:get(?merged,3) = "three" ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/merge-null-02.rq b/src/test/resources/sparql-cdts/tests/map-functions/merge-null-02.rq new file mode 100644 index 00000000..5f730a2c --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/merge-null-02.rq @@ -0,0 +1,18 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( "{1: 'one', 2: 'two'}"^^cdt:Map AS ?map1 ) + BIND( "{3: null}"^^cdt:Map AS ?map2 ) + BIND( cdt:merge(?map1, ?map2) AS ?merged ) + + FILTER( cdt:size(?merged) = 3 ) + + FILTER( cdt:containsKey(?merged,3) ) + BIND( cdt:get(?merged,3) AS ?x ) + FILTER( ! BOUND(?x) ) + + FILTER( cdt:get(?merged,1) = "one" ) + + FILTER( cdt:get(?merged,2) = "two" ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/merge-null-03.rq b/src/test/resources/sparql-cdts/tests/map-functions/merge-null-03.rq new file mode 100644 index 00000000..fbc08e9e --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/merge-null-03.rq @@ -0,0 +1,14 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( "{1: null}"^^cdt:Map AS ?map1 ) + BIND( "{1: 'one'}"^^cdt:Map AS ?map2 ) + BIND( cdt:merge(?map1, ?map2) AS ?merged ) + + FILTER( cdt:size(?merged) = 1 ) + + FILTER( cdt:containsKey(?merged,1) ) + BIND( cdt:get(?merged,1) AS ?x ) + FILTER( ! BOUND(?x) ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/merge-null-04.rq b/src/test/resources/sparql-cdts/tests/map-functions/merge-null-04.rq new file mode 100644 index 00000000..7f603d41 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/merge-null-04.rq @@ -0,0 +1,10 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( "{1: 'one'}"^^cdt:Map AS ?map1 ) + BIND( "{1: null}"^^cdt:Map AS ?map2 ) + BIND( cdt:merge(?map1, ?map2) AS ?merged ) + + FILTER( ?merged = "{1: 'one'}"^^cdt:Map ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/put-01.rq b/src/test/resources/sparql-cdts/tests/map-functions/put-01.rq new file mode 100644 index 00000000..ea78bc11 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/put-01.rq @@ -0,0 +1,9 @@ +PREFIX cdt: + +ASK { + BIND( "{}"^^cdt:Map AS ?mapIn ) + BIND( cdt:put(?mapIn, 1, "one") AS ?mapOut ) + + FILTER( BOUND(?mapOut) ) # check that there was no error + FILTER( ?mapOut = "{1:'one'}"^^cdt:Map ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/put-02.rq b/src/test/resources/sparql-cdts/tests/map-functions/put-02.rq new file mode 100644 index 00000000..4e5abd50 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/put-02.rq @@ -0,0 +1,12 @@ +PREFIX cdt: + +ASK { + BIND( "{}"^^cdt:Map AS ?mapIn ) + BIND( cdt:put(?mapIn, 1, ?unbound) AS ?mapOut ) + + FILTER( BOUND(?mapOut) ) # check that there was no error + FILTER( cdt:size(?mapOut) = 1 ) + FILTER( cdt:containsKey(?mapOut,1) ) + BIND( cdt:get(?mapOut,1) AS ?value ) + FILTER( ! BOUND(?value) ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/put-03.rq b/src/test/resources/sparql-cdts/tests/map-functions/put-03.rq new file mode 100644 index 00000000..f31aa232 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/put-03.rq @@ -0,0 +1,12 @@ +PREFIX cdt: + +ASK { + BIND( "{}"^^cdt:Map AS ?mapIn ) + BIND( cdt:put(?mapIn, 1) AS ?mapOut ) + + FILTER( BOUND(?mapOut) ) # check that there was no error + FILTER( cdt:size(?mapOut) = 1 ) + FILTER( cdt:containsKey(?mapOut,1) ) + BIND( cdt:get(?mapOut,1) AS ?value ) + FILTER( ! BOUND(?value) ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/put-04.rq b/src/test/resources/sparql-cdts/tests/map-functions/put-04.rq new file mode 100644 index 00000000..89e32f37 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/put-04.rq @@ -0,0 +1,9 @@ +PREFIX cdt: + +ASK { + BIND( "{1:'one', 2:'two'}"^^cdt:Map AS ?mapIn ) + BIND( cdt:put(?mapIn, 1, "one") AS ?mapOut ) + + FILTER( BOUND(?mapOut) ) # check that there was no error + FILTER( ?mapOut = ?mapIn ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/put-05.rq b/src/test/resources/sparql-cdts/tests/map-functions/put-05.rq new file mode 100644 index 00000000..49508c4b --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/put-05.rq @@ -0,0 +1,9 @@ +PREFIX cdt: + +ASK { + BIND( "{1:'one', 2:'two'}"^^cdt:Map AS ?mapIn ) + BIND( cdt:put(?mapIn, 1, "alsoOne") AS ?mapOut ) + + FILTER( BOUND(?mapOut) ) # check that there was no error + FILTER( ?mapOut = "{1:'alsoOne', 2:'two'}"^^cdt:Map ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/put-06.rq b/src/test/resources/sparql-cdts/tests/map-functions/put-06.rq new file mode 100644 index 00000000..7b719b1d --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/put-06.rq @@ -0,0 +1,9 @@ +PREFIX cdt: + +ASK { + BIND( "{1:null, 2:'two'}"^^cdt:Map AS ?mapIn ) + BIND( cdt:put(?mapIn, 1, "one") AS ?mapOut ) + + FILTER( BOUND(?mapOut) ) # check that there was no error + FILTER( ?mapOut = "{1:'one', 2:'two'}"^^cdt:Map ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/put-07.rq b/src/test/resources/sparql-cdts/tests/map-functions/put-07.rq new file mode 100644 index 00000000..30beb372 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/put-07.rq @@ -0,0 +1,15 @@ +PREFIX cdt: + +ASK { + BIND( "{1:'one', 2:'two'}"^^cdt:Map AS ?mapIn ) + BIND( cdt:put(?mapIn, 1, ?unbound) AS ?mapOut ) + + FILTER( BOUND(?mapOut) ) # check that there was no error + FILTER( cdt:size(?mapOut) = 2 ) + + FILTER( cdt:containsKey(?mapOut,1) ) + BIND( cdt:get(?mapOut,1) AS ?v1 ) + FILTER( ! BOUND(?v1) ) + + FILTER( cdt:get(?mapOut,2) = "two" ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/put-08.rq b/src/test/resources/sparql-cdts/tests/map-functions/put-08.rq new file mode 100644 index 00000000..47aa279e --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/put-08.rq @@ -0,0 +1,15 @@ +PREFIX cdt: + +ASK { + BIND( "{1:'one', 2:'two'}"^^cdt:Map AS ?mapIn ) + BIND( cdt:put(?mapIn, 1) AS ?mapOut ) + + FILTER( BOUND(?mapOut) ) # check that there was no error + FILTER( cdt:size(?mapOut) = 2 ) + + FILTER( cdt:containsKey(?mapOut,1) ) + BIND( cdt:get(?mapOut,1) AS ?v1 ) + FILTER( ! BOUND(?v1) ) + + FILTER( cdt:get(?mapOut,2) = "two" ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/put-09.rq b/src/test/resources/sparql-cdts/tests/map-functions/put-09.rq new file mode 100644 index 00000000..d4cff7a4 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/put-09.rq @@ -0,0 +1,9 @@ +PREFIX cdt: + +ASK { + BIND( "{1:'one'}"^^cdt:Map AS ?mapIn ) + BIND( cdt:put(?mapIn, 2, "two") AS ?mapOut ) + + FILTER( BOUND(?mapOut) ) # check that there was no error + FILTER( ?mapOut = "{1:'one', 2:'two'}"^^cdt:Map ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/put-10.rq b/src/test/resources/sparql-cdts/tests/map-functions/put-10.rq new file mode 100644 index 00000000..2db72225 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/put-10.rq @@ -0,0 +1,15 @@ +PREFIX cdt: + +ASK { + BIND( "{1:'one'}"^^cdt:Map AS ?mapIn ) + BIND( cdt:put(?mapIn, 2, ?unbound) AS ?mapOut ) + + FILTER( BOUND(?mapOut) ) # check that there was no error + FILTER( cdt:size(?mapOut) = 2 ) + + FILTER( cdt:get(?mapOut,1) = "one" ) + + FILTER( cdt:containsKey(?mapOut,2) ) + BIND( cdt:get(?mapOut,2) AS ?v2 ) + FILTER( ! BOUND(?v2) ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/put-11.rq b/src/test/resources/sparql-cdts/tests/map-functions/put-11.rq new file mode 100644 index 00000000..073fd9a1 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/put-11.rq @@ -0,0 +1,15 @@ +PREFIX cdt: + +ASK { + BIND( "{1:'one'}"^^cdt:Map AS ?mapIn ) + BIND( cdt:put(?mapIn, 2) AS ?mapOut ) + + FILTER( BOUND(?mapOut) ) # check that there was no error + FILTER( cdt:size(?mapOut) = 2 ) + + FILTER( cdt:get(?mapOut,1) = "one" ) + + FILTER( cdt:containsKey(?mapOut,2) ) + BIND( cdt:get(?mapOut,2) AS ?v2 ) + FILTER( ! BOUND(?v2) ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/put-12.rq b/src/test/resources/sparql-cdts/tests/map-functions/put-12.rq new file mode 100644 index 00000000..727c7464 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/put-12.rq @@ -0,0 +1,10 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( "{1:'one', 2:'two'}"^^cdt:Map AS ?mapIn ) + BIND( cdt:put(?mapIn, "01"^^xsd:integer, "alsoOne") AS ?mapOut ) + + FILTER( BOUND(?mapOut) ) # check that there was no error + FILTER( ?mapOut = "{1:'one', '01'^^:'alsoOne', 2:'two'}"^^cdt:Map ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/put-13.rq b/src/test/resources/sparql-cdts/tests/map-functions/put-13.rq new file mode 100644 index 00000000..d956701e --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/put-13.rq @@ -0,0 +1,9 @@ +PREFIX cdt: + +ASK { + BIND( "{'hello'@en:'one', 2:'two'}"^^cdt:Map AS ?mapIn ) + BIND( cdt:put(?mapIn, 'hello'@en, "alsoOne") AS ?mapOut ) + + FILTER( BOUND(?mapOut) ) # check that there was no error + FILTER( ?mapOut = "{'hello'@en:'alsoOne', 2:'two'}"^^cdt:Map ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/put-14.rq b/src/test/resources/sparql-cdts/tests/map-functions/put-14.rq new file mode 100644 index 00000000..fd61141b --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/put-14.rq @@ -0,0 +1,9 @@ +PREFIX cdt: + +ASK { + BIND( "{'hello'@en:'one', 2:'two'}"^^cdt:Map AS ?mapIn ) + BIND( cdt:put(?mapIn, 'hello', "alsoOne") AS ?mapOut ) + + FILTER( BOUND(?mapOut) ) # check that there was no error + FILTER( ?mapOut = "{'hello'@en:'one', 'hello':'alsoOne', 2:'two'}"^^cdt:Map ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/put-15.rq b/src/test/resources/sparql-cdts/tests/map-functions/put-15.rq new file mode 100644 index 00000000..1c2b041a --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/put-15.rq @@ -0,0 +1,9 @@ +PREFIX cdt: + +ASK { + BIND( "{:'one', 2:'two'}"^^cdt:Map AS ?mapIn ) + BIND( cdt:put(?mapIn, , "alsoOne") AS ?mapOut ) + + FILTER( BOUND(?mapOut) ) # check that there was no error + FILTER( ?mapOut = "{:'alsoOne', 2:'two'}"^^cdt:Map ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/put-error-01.rq b/src/test/resources/sparql-cdts/tests/map-functions/put-error-01.rq new file mode 100644 index 00000000..24ae878b --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/put-error-01.rq @@ -0,0 +1,8 @@ +PREFIX cdt: + +ASK { + BIND( "{}" AS ?mapIn ) # not a cdt:Map literal + BIND( cdt:put(?mapIn, 1, "one") AS ?mapOut ) + + FILTER( ! BOUND(?mapOut) ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/put-error-02.rq b/src/test/resources/sparql-cdts/tests/map-functions/put-error-02.rq new file mode 100644 index 00000000..109eb2c4 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/put-error-02.rq @@ -0,0 +1,8 @@ +PREFIX cdt: + +ASK { + BIND( "{ 1 }"^^cdt:Map AS ?mapIn ) # a cdt:Map literal that is not well-formed + BIND( cdt:put(?mapIn, 1, "one") AS ?mapOut ) + + FILTER( ! BOUND(?mapOut) ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/put-error-03.rq b/src/test/resources/sparql-cdts/tests/map-functions/put-error-03.rq new file mode 100644 index 00000000..2e96f878 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/put-error-03.rq @@ -0,0 +1,8 @@ +PREFIX cdt: + +ASK { + BIND( "{}"^^cdt:Map AS ?mapIn ) + BIND( cdt:put(?mapIn, BNODE(), "one") AS ?mapOut ) # blank nodes are not valid as map keys + + FILTER( ! BOUND(?mapOut) ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/put-error-04.rq b/src/test/resources/sparql-cdts/tests/map-functions/put-error-04.rq new file mode 100644 index 00000000..7aeba390 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/put-error-04.rq @@ -0,0 +1,8 @@ +PREFIX cdt: + +ASK { + BIND( "{}"^^cdt:Map AS ?mapIn ) + BIND( cdt:put(?mapIn, ?unbound, "one") AS ?mapOut ) # unbound map key + + FILTER( ! BOUND(?mapOut) ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/put-error-05.rq b/src/test/resources/sparql-cdts/tests/map-functions/put-error-05.rq new file mode 100644 index 00000000..b1df47e9 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/put-error-05.rq @@ -0,0 +1,7 @@ +PREFIX cdt: + +ASK { + BIND( cdt:put(?unbound, 1, "one") AS ?mapOut ) # unbound cdt:Map literal + + FILTER( ! BOUND(?mapOut) ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/remove-01.rq b/src/test/resources/sparql-cdts/tests/map-functions/remove-01.rq new file mode 100644 index 00000000..3dee66fb --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/remove-01.rq @@ -0,0 +1,11 @@ +PREFIX cdt: + +ASK { + BIND( "{1:'one',2:'two'}"^^cdt:Map AS ?mapIn ) + BIND( cdt:remove(?mapIn, BNODE()) AS ?mapOut ) # special case because a bnode is not a map key + + FILTER( BOUND(?mapOut) ) # check that there was no error + FILTER( SAMETERM(?mapIn,?mapOut) ) # by definition of this special case, + # the input term must be returned + # (input and output must be the same term) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/remove-02.rq b/src/test/resources/sparql-cdts/tests/map-functions/remove-02.rq new file mode 100644 index 00000000..463f9981 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/remove-02.rq @@ -0,0 +1,9 @@ +PREFIX cdt: + +ASK { + BIND( "{}"^^cdt:Map AS ?mapIn ) + BIND( cdt:remove(?mapIn, 1) AS ?mapOut ) + + FILTER( BOUND(?mapOut) ) # check that there was no error + FILTER( ?mapOut = "{}"^^cdt:Map ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/remove-03.rq b/src/test/resources/sparql-cdts/tests/map-functions/remove-03.rq new file mode 100644 index 00000000..3684db8f --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/remove-03.rq @@ -0,0 +1,9 @@ +PREFIX cdt: + +ASK { + BIND( "{1:'one'}"^^cdt:Map AS ?mapIn ) + BIND( cdt:remove(?mapIn, 1) AS ?mapOut ) + + FILTER( BOUND(?mapOut) ) # check that there was no error + FILTER( ?mapOut = "{}"^^cdt:Map ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/remove-04.rq b/src/test/resources/sparql-cdts/tests/map-functions/remove-04.rq new file mode 100644 index 00000000..f42963ea --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/remove-04.rq @@ -0,0 +1,9 @@ +PREFIX cdt: + +ASK { + BIND( "{1:'one',2:'two'}"^^cdt:Map AS ?mapIn ) + BIND( cdt:remove(?mapIn, 1) AS ?mapOut ) + + FILTER( BOUND(?mapOut) ) # check that there was no error + FILTER( ?mapOut = "{2:'two'}"^^cdt:Map ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/remove-05.rq b/src/test/resources/sparql-cdts/tests/map-functions/remove-05.rq new file mode 100644 index 00000000..74c653ce --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/remove-05.rq @@ -0,0 +1,10 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( "{1:'one', '02'^^:'two'}"^^cdt:Map AS ?mapIn ) + BIND( cdt:remove(?mapIn, '02'^^xsd:integer) AS ?mapOut ) + + FILTER( BOUND(?mapOut) ) # check that there was no error + FILTER( ?mapOut = "{1:'one'}"^^cdt:Map ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/remove-06.rq b/src/test/resources/sparql-cdts/tests/map-functions/remove-06.rq new file mode 100644 index 00000000..80547e21 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/remove-06.rq @@ -0,0 +1,10 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( "{1:'one', '02'^^:'two'}"^^cdt:Map AS ?mapIn ) + BIND( cdt:remove(?mapIn, '2'^^xsd:integer) AS ?mapOut ) + + FILTER( BOUND(?mapOut) ) # check that there was no error + FILTER( ?mapOut = ?mapIn ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/remove-07.rq b/src/test/resources/sparql-cdts/tests/map-functions/remove-07.rq new file mode 100644 index 00000000..2fded4f5 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/remove-07.rq @@ -0,0 +1,10 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( "{1:'one', 2:'two'}"^^cdt:Map AS ?mapIn ) + BIND( cdt:remove(?mapIn, '02'^^xsd:integer) AS ?mapOut ) + + FILTER( BOUND(?mapOut) ) # check that there was no error + FILTER( ?mapOut = ?mapIn ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/remove-08.rq b/src/test/resources/sparql-cdts/tests/map-functions/remove-08.rq new file mode 100644 index 00000000..43afdcf7 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/remove-08.rq @@ -0,0 +1,9 @@ +PREFIX cdt: + +ASK { + BIND("{'hello'@en:'there'@en, 1:'one', 2:'two'}"^^cdt:Map AS ?mapIn ) + BIND( cdt:remove(?mapIn, 'hello'@en) AS ?mapOut ) + + FILTER( BOUND(?mapOut) ) # check that there was no error + FILTER( ?mapOut = "{1:'one', 2:'two'}"^^cdt:Map ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/remove-09.rq b/src/test/resources/sparql-cdts/tests/map-functions/remove-09.rq new file mode 100644 index 00000000..b652047e --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/remove-09.rq @@ -0,0 +1,9 @@ +PREFIX cdt: + +ASK { + BIND("{'hello'@en:'there'@en, 1:'one', 2:'two'}"^^cdt:Map AS ?mapIn ) + BIND( cdt:remove(?mapIn, 'hello') AS ?mapOut ) + + FILTER( BOUND(?mapOut) ) # check that there was no error + FILTER( ?mapOut = ?mapIn ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/remove-10.rq b/src/test/resources/sparql-cdts/tests/map-functions/remove-10.rq new file mode 100644 index 00000000..c0047b98 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/remove-10.rq @@ -0,0 +1,9 @@ +PREFIX cdt: + +ASK { + BIND("{'hello':'there', 1:'one', 2:'two'}"^^cdt:Map AS ?mapIn ) + BIND( cdt:remove(?mapIn, 'hello'@en) AS ?mapOut ) + + FILTER( BOUND(?mapOut) ) # check that there was no error + FILTER( ?mapOut = ?mapIn ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/remove-11.rq b/src/test/resources/sparql-cdts/tests/map-functions/remove-11.rq new file mode 100644 index 00000000..677a8f2f --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/remove-11.rq @@ -0,0 +1,9 @@ +PREFIX cdt: + +ASK { + BIND("{:'there'@en, 1:'one', 2:'two'}"^^cdt:Map AS ?mapIn ) + BIND( cdt:remove(?mapIn, ) AS ?mapOut ) + + FILTER( BOUND(?mapOut) ) # check that there was no error + FILTER( ?mapOut = "{1:'one', 2:'two'}"^^cdt:Map ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/sameterm-01.rq b/src/test/resources/sparql-cdts/tests/map-functions/sameterm-01.rq new file mode 100644 index 00000000..5dedb601 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/sameterm-01.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( cdt:Map() AS ?map1 ) + BIND( cdt:Map() AS ?map2 ) + FILTER(SAMETERM( ?map1, ?map2)) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/sameterm-02.rq b/src/test/resources/sparql-cdts/tests/map-functions/sameterm-02.rq new file mode 100644 index 00000000..714e012b --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/sameterm-02.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( cdt:Map(1, 1) AS ?map1 ) + BIND( cdt:Map(1, 1) AS ?map2 ) + FILTER( SAMETERM(?map1, ?map2) ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/sameterm-03.rq b/src/test/resources/sparql-cdts/tests/map-functions/sameterm-03.rq new file mode 100644 index 00000000..223e1284 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/sameterm-03.rq @@ -0,0 +1,7 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( cdt:Map(1, 2) AS ?map1 ) + FILTER(! SAMETERM(?map1, "{1: '2'^^}"^^cdt:Map) ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/sameterm-04.rq b/src/test/resources/sparql-cdts/tests/map-functions/sameterm-04.rq new file mode 100644 index 00000000..9a1dffa7 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/sameterm-04.rq @@ -0,0 +1,7 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( cdt:Map(1, 1) AS ?map ) + FILTER(! SAMETERM("{ 1 : 1 }"^^cdt:Map, ?map) ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/sameterm-05.rq b/src/test/resources/sparql-cdts/tests/map-functions/sameterm-05.rq new file mode 100644 index 00000000..264d9166 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/sameterm-05.rq @@ -0,0 +1,9 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( BNODE() AS ?bnode ) + BIND( cdt:Map(1, ?bnode ) AS ?map1 ) + BIND( cdt:Map(1, ?bnode ) AS ?map2 ) + FILTER( SAMETERM( ?map1, ?map2) ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/sameterm-null-01.rq b/src/test/resources/sparql-cdts/tests/map-functions/sameterm-null-01.rq new file mode 100644 index 00000000..261b6120 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/sameterm-null-01.rq @@ -0,0 +1,8 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + BIND( cdt:Map(1, ?undef1) AS ?map1 ) + BIND( cdt:Map(1, ?undef2) AS ?map2 ) + FILTER( SAMETERM( ?map1, ?map2 ) ) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/size-01.rq b/src/test/resources/sparql-cdts/tests/map-functions/size-01.rq new file mode 100644 index 00000000..b71c7cba --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/size-01.rq @@ -0,0 +1,7 @@ +PREFIX cdt: + +# empty map +ASK { + BIND("{}"^^cdt:Map AS ?map) + FILTER(cdt:size(?map) = 0) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/size-02.rq b/src/test/resources/sparql-cdts/tests/map-functions/size-02.rq new file mode 100644 index 00000000..41818080 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/size-02.rq @@ -0,0 +1,7 @@ +PREFIX cdt: + +# 1-entry map +ASK { + BIND("{1: 'one'}"^^cdt:Map AS ?map) + FILTER(cdt:size(?map) = 1) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/size-03.rq b/src/test/resources/sparql-cdts/tests/map-functions/size-03.rq new file mode 100644 index 00000000..84f06e2b --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/size-03.rq @@ -0,0 +1,7 @@ +PREFIX cdt: + +# 2-entry map +ASK { + BIND("{1: 'one', 2: 'two'}"^^cdt:Map AS ?map) + FILTER(cdt:size(?map) = 2) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/size-04.rq b/src/test/resources/sparql-cdts/tests/map-functions/size-04.rq new file mode 100644 index 00000000..f78148e0 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/size-04.rq @@ -0,0 +1,7 @@ +PREFIX cdt: + +# 2-entry map, mixed types +ASK { + BIND("{1: 'one', 'hello'@en: 2.5}"^^cdt:Map AS ?map) + FILTER(cdt:size(?map) = 2) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/size-05.rq b/src/test/resources/sparql-cdts/tests/map-functions/size-05.rq new file mode 100644 index 00000000..d6a8faa0 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/size-05.rq @@ -0,0 +1,7 @@ +PREFIX cdt: + +# 2-entry map, including null value +ASK { + BIND("{1: 'one', 2: null}"^^cdt:Map AS ?map) + FILTER(cdt:size(?map) = 2) +} diff --git a/src/test/resources/sparql-cdts/tests/map-functions/true.srx b/src/test/resources/sparql-cdts/tests/map-functions/true.srx new file mode 100644 index 00000000..c187f066 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/map-functions/true.srx @@ -0,0 +1,5 @@ + + + + true + diff --git a/src/test/resources/sparql-cdts/tests/orderby/empty.ttl b/src/test/resources/sparql-cdts/tests/orderby/empty.ttl new file mode 100644 index 00000000..e69de29b diff --git a/src/test/resources/sparql-cdts/tests/orderby/manifest.ttl b/src/test/resources/sparql-cdts/tests/orderby/manifest.ttl new file mode 100644 index 00000000..8b2b9b3b --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/orderby/manifest.ttl @@ -0,0 +1,291 @@ +@prefix rdf: . +@prefix : . +@prefix rdfs: . +@prefix mf: . +@prefix qt: . +@prefix dawgt: . +@prefix sparql: . +@prefix cdt: . + +<> rdf:type mf:Manifest ; + rdfs:label "ORDER BY for cdt:List and cdt:Map literals" ; + mf:entries + ( + :order-list-03 + :order-list-04 + :order-list-05 + :order-list-06 + :order-list-07 + :order-list-08 + :order-list-09 + :order-list-10 + + :order-list-null-01 + :order-list-null-02 + + :order-map-03 + :order-map-03 + :order-map-04 + :order-map-05 + :order-map-06 + :order-map-07 + :order-map-08 + :order-map-09 + :order-map-10 + :order-map-11 + :order-map-12 + :order-map-13 + :order-map-14 + :order-map-15 + :order-map-16 + :order-map-17 + + :order-map-null-01 + :order-map-null-02 + ) . + +:order-list-03 rdf:type mf:QueryEvaluationTest ; + mf:name "order-list-03" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:order-list-04 rdf:type mf:QueryEvaluationTest ; + mf:name "order-list-04" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:order-list-05 rdf:type mf:QueryEvaluationTest ; + mf:name "order-list-05" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:order-list-06 rdf:type mf:QueryEvaluationTest ; + mf:name "order-list-06" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:order-list-07 rdf:type mf:QueryEvaluationTest ; + mf:name "order-list-07" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:order-list-08 rdf:type mf:QueryEvaluationTest ; + mf:name "order-list-08" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:order-list-09 rdf:type mf:QueryEvaluationTest ; + mf:name "order-list-09" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:order-list-10 rdf:type mf:QueryEvaluationTest ; + mf:name "order-list-10" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + + +:order-list-null-01 rdf:type mf:QueryEvaluationTest ; + mf:name "order-list-null-01" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:order-list-null-02 rdf:type mf:QueryEvaluationTest ; + mf:name "order-list-null-02" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + + +:order-map-03 rdf:type mf:QueryEvaluationTest ; + mf:name "order-map-03" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:order-map-04 rdf:type mf:QueryEvaluationTest ; + mf:name "order-map-04" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:order-map-05 rdf:type mf:QueryEvaluationTest ; + mf:name "order-map-05" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:order-map-06 rdf:type mf:QueryEvaluationTest ; + mf:name "order-map-06" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:order-map-07 rdf:type mf:QueryEvaluationTest ; + mf:name "order-map-07" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:order-map-08 rdf:type mf:QueryEvaluationTest ; + mf:name "order-map-08" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:order-map-09 rdf:type mf:QueryEvaluationTest ; + mf:name "order-map-09" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:order-map-10 rdf:type mf:QueryEvaluationTest ; + mf:name "order-map-10" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:order-map-11 rdf:type mf:QueryEvaluationTest ; + mf:name "order-map-11" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:order-map-12 rdf:type mf:QueryEvaluationTest ; + mf:name "order-map-12" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:order-map-13 rdf:type mf:QueryEvaluationTest ; + mf:name "order-map-13" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:order-map-14 rdf:type mf:QueryEvaluationTest ; + mf:name "order-map-14" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:order-map-15 rdf:type mf:QueryEvaluationTest ; + mf:name "order-map-15" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:order-map-16 rdf:type mf:QueryEvaluationTest ; + mf:name "order-map-16" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:order-map-17 rdf:type mf:QueryEvaluationTest ; + mf:name "order-map-17" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + + +:order-map-null-01 rdf:type mf:QueryEvaluationTest ; + mf:name "order-map-null-01" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . + +:order-map-null-02 rdf:type mf:QueryEvaluationTest ; + mf:name "order-map-null-02" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result ; + . diff --git a/src/test/resources/sparql-cdts/tests/orderby/order-list-03.rq b/src/test/resources/sparql-cdts/tests/orderby/order-list-03.rq new file mode 100644 index 00000000..689416cf --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/orderby/order-list-03.rq @@ -0,0 +1,15 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + { + SELECT * WHERE { + VALUES (?id ?list) { + (1 "[1]"^^cdt:List) + (2 "[ 2]"^^cdt:List) # the space is on purpose, to make sure the comparison is not done in terms of the lexical forms + } + } + ORDER BY ?list LIMIT 1 + } + FILTER (?id = 1) +} diff --git a/src/test/resources/sparql-cdts/tests/orderby/order-list-04.rq b/src/test/resources/sparql-cdts/tests/orderby/order-list-04.rq new file mode 100644 index 00000000..4e67eaf1 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/orderby/order-list-04.rq @@ -0,0 +1,15 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + { + SELECT * WHERE { + VALUES (?id ?list) { + (1 "['01'^^]"^^cdt:List) + (2 "['001'^^]"^^cdt:List) + } + } + ORDER BY ?list LIMIT 1 + } + FILTER ( (?id = 1) || (?id = 2) ) +} diff --git a/src/test/resources/sparql-cdts/tests/orderby/order-list-05.rq b/src/test/resources/sparql-cdts/tests/orderby/order-list-05.rq new file mode 100644 index 00000000..85918ac4 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/orderby/order-list-05.rq @@ -0,0 +1,18 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + { + SELECT * WHERE { + VALUES (?id ?list) { + (1 "[1]"^^cdt:List) + (2 "[ ]"^^cdt:List) + (3 "[ 2]"^^cdt:List) # the spaces are on purpose, to make sure the comparison is not done in terms of the lexical forms + (4 "[ ]"^^cdt:List) + (5 "[3]"^^cdt:List) + } + } + ORDER BY ?list LIMIT 1 + } + FILTER ( (?id = 2) || (?id = 4) ) +} diff --git a/src/test/resources/sparql-cdts/tests/orderby/order-list-06.rq b/src/test/resources/sparql-cdts/tests/orderby/order-list-06.rq new file mode 100644 index 00000000..5782ad84 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/orderby/order-list-06.rq @@ -0,0 +1,15 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + { + SELECT * WHERE { + VALUES (?id ?list) { + (1 "[ 1, 1]"^^cdt:List) # the leading space is on purpose, to make sure the comparison is not done in terms of the lexical forms + (2 "[1]"^^cdt:List) + } + } + ORDER BY ?list LIMIT 1 + } + FILTER (?id = 2) +} diff --git a/src/test/resources/sparql-cdts/tests/orderby/order-list-07.rq b/src/test/resources/sparql-cdts/tests/orderby/order-list-07.rq new file mode 100644 index 00000000..cbdf9e32 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/orderby/order-list-07.rq @@ -0,0 +1,15 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + { + SELECT * WHERE { + VALUES (?id ?list) { + (1 "[1, 1]"^^cdt:List) + (2 "[2]"^^cdt:List) + } + } + ORDER BY ?list LIMIT 1 + } + FILTER (?id = 1) +} diff --git a/src/test/resources/sparql-cdts/tests/orderby/order-list-08.rq b/src/test/resources/sparql-cdts/tests/orderby/order-list-08.rq new file mode 100644 index 00000000..129cf1c9 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/orderby/order-list-08.rq @@ -0,0 +1,15 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + { + SELECT * WHERE { + VALUES (?id ?list) { + (1 "[2, 1]"^^cdt:List) + (2 "[2, 2]"^^cdt:List) + } + } + ORDER BY ?list LIMIT 1 + } + FILTER (?id = 1) +} diff --git a/src/test/resources/sparql-cdts/tests/orderby/order-list-09.rq b/src/test/resources/sparql-cdts/tests/orderby/order-list-09.rq new file mode 100644 index 00000000..1754162f --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/orderby/order-list-09.rq @@ -0,0 +1,15 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + { + SELECT * WHERE { + VALUES (?id ?list) { + (1 "[, 1]"^^cdt:List) + (2 "[, 2]"^^cdt:List) + } + } + ORDER BY ?list LIMIT 1 + } + FILTER (?id = 1) +} diff --git a/src/test/resources/sparql-cdts/tests/orderby/order-list-10.rq b/src/test/resources/sparql-cdts/tests/orderby/order-list-10.rq new file mode 100644 index 00000000..755a43e6 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/orderby/order-list-10.rq @@ -0,0 +1,15 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + { + SELECT * WHERE { + VALUES (?id ?list) { + (1 "[, ]"^^cdt:List) + (2 "[, ]"^^cdt:List) + } + } + ORDER BY ?list LIMIT 1 + } + FILTER (?id = 1) +} diff --git a/src/test/resources/sparql-cdts/tests/orderby/order-list-null-01.rq b/src/test/resources/sparql-cdts/tests/orderby/order-list-null-01.rq new file mode 100644 index 00000000..d087a21f --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/orderby/order-list-null-01.rq @@ -0,0 +1,15 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + { + SELECT * WHERE { + VALUES (?id ?list) { + (1 "[null, 1]"^^cdt:List) + (2 "[null, 2]"^^cdt:List) # the added space is on purpose, to make sure the comparison is not done in terms of the lexical forms + } + } + ORDER BY ?list LIMIT 1 + } + FILTER (?id = 1) +} diff --git a/src/test/resources/sparql-cdts/tests/orderby/order-list-null-02.rq b/src/test/resources/sparql-cdts/tests/orderby/order-list-null-02.rq new file mode 100644 index 00000000..d3b601b0 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/orderby/order-list-null-02.rq @@ -0,0 +1,16 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + { + SELECT * WHERE { + VALUES (?id ?list) { + (1 "[ null , 1]"^^cdt:List) + (2 "[ 'hello', 2]"^^cdt:List) + (3 "[null , 3]"^^cdt:List) + } + } + ORDER BY DESC(?list) LIMIT 1 # attention, DESC here to check that the non-null element ordered highest + } + FILTER (?id = 2) +} diff --git a/src/test/resources/sparql-cdts/tests/orderby/order-map-03.rq b/src/test/resources/sparql-cdts/tests/orderby/order-map-03.rq new file mode 100644 index 00000000..985acd8c --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/orderby/order-map-03.rq @@ -0,0 +1,15 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + { + SELECT * WHERE { + VALUES (?id ?map) { + (1 "{1: 42}"^^cdt:Map) + (2 "{ 2: 42}"^^cdt:Map) # the space is on purpose, to make sure the comparison is not done in terms of the lexical forms + } + } + ORDER BY ?map LIMIT 1 + } + FILTER (?id = 1) +} diff --git a/src/test/resources/sparql-cdts/tests/orderby/order-map-04.rq b/src/test/resources/sparql-cdts/tests/orderby/order-map-04.rq new file mode 100644 index 00000000..17e8a5bd --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/orderby/order-map-04.rq @@ -0,0 +1,15 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + { + SELECT * WHERE { + VALUES (?id ?map) { + (1 "{ '01'^^: 42 }"^^cdt:Map) + (2 "{ '001'^^: 42 }"^^cdt:Map) + } + } + ORDER BY ?map LIMIT 1 + } + FILTER (?id = 2) +} diff --git a/src/test/resources/sparql-cdts/tests/orderby/order-map-05.rq b/src/test/resources/sparql-cdts/tests/orderby/order-map-05.rq new file mode 100644 index 00000000..43dcabcf --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/orderby/order-map-05.rq @@ -0,0 +1,15 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + { + SELECT * WHERE { + VALUES (?id ?map) { + (1 " { '1'^^: 42 }"^^cdt:Map) # note, different datatype + (2 "{ '2'^^: 42 }"^^cdt:Map) + } + } + ORDER BY ?map LIMIT 1 + } + FILTER (?id = 2) +} diff --git a/src/test/resources/sparql-cdts/tests/orderby/order-map-06.rq b/src/test/resources/sparql-cdts/tests/orderby/order-map-06.rq new file mode 100644 index 00000000..77b73acd --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/orderby/order-map-06.rq @@ -0,0 +1,15 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + { + SELECT * WHERE { + VALUES (?id ?map) { + (1 "{ : 42 }"^^cdt:Map) + (2 "{ '2'^^: 42}"^^cdt:Map) + } + } + ORDER BY ?map LIMIT 1 + } + FILTER (?id = 1) +} diff --git a/src/test/resources/sparql-cdts/tests/orderby/order-map-07.rq b/src/test/resources/sparql-cdts/tests/orderby/order-map-07.rq new file mode 100644 index 00000000..1b1f2bbb --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/orderby/order-map-07.rq @@ -0,0 +1,15 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + { + SELECT * WHERE { + VALUES (?id ?map) { + (1 " { : 42 }"^^cdt:Map) + (2 "{ : 42 }"^^cdt:Map) + } + } + ORDER BY ?map LIMIT 1 + } + FILTER (?id = 2) +} diff --git a/src/test/resources/sparql-cdts/tests/orderby/order-map-08.rq b/src/test/resources/sparql-cdts/tests/orderby/order-map-08.rq new file mode 100644 index 00000000..75d67c86 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/orderby/order-map-08.rq @@ -0,0 +1,15 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + { + SELECT * WHERE { + VALUES (?id ?map) { + (1 "{1: 42}"^^cdt:Map) + (2 "{ 1: 43}"^^cdt:Map) # the space is on purpose, to make sure the comparison is not done in terms of the lexical forms + } + } + ORDER BY ?map LIMIT 1 + } + FILTER (?id = 1) +} diff --git a/src/test/resources/sparql-cdts/tests/orderby/order-map-09.rq b/src/test/resources/sparql-cdts/tests/orderby/order-map-09.rq new file mode 100644 index 00000000..a5dd4b2a --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/orderby/order-map-09.rq @@ -0,0 +1,17 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + { + SELECT * WHERE { + VALUES (?id ?map) { + (1 "{ 99: 1 }"^^cdt:Map) + (2 " { 1: '01'^^ }"^^cdt:Map) + (3 " { 1: '001'^^ }"^^cdt:Map) + (4 " { 99: 99 }"^^cdt:Map) # a system that doesn't know about CDTs will return this. + } + } + ORDER BY ?map LIMIT 1 + } + FILTER ( (?id = 2) || (?id = 3) ) +} diff --git a/src/test/resources/sparql-cdts/tests/orderby/order-map-10.rq b/src/test/resources/sparql-cdts/tests/orderby/order-map-10.rq new file mode 100644 index 00000000..50c74129 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/orderby/order-map-10.rq @@ -0,0 +1,15 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + { + SELECT * WHERE { + VALUES (?id ?map) { + (1 "{ 1: 1 }"^^cdt:Map) + (2 "{ 1: }"^^cdt:Map) + } + } + ORDER BY ?map LIMIT 1 + } + FILTER (?id = 2) +} diff --git a/src/test/resources/sparql-cdts/tests/orderby/order-map-11.rq b/src/test/resources/sparql-cdts/tests/orderby/order-map-11.rq new file mode 100644 index 00000000..c88fe1b2 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/orderby/order-map-11.rq @@ -0,0 +1,15 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + { + SELECT * WHERE { + VALUES (?id ?map) { + (1 " { 1: }"^^cdt:Map) + (2 "{ 1: }"^^cdt:Map) + } + } + ORDER BY ?map LIMIT 1 + } + FILTER (?id = 2) +} diff --git a/src/test/resources/sparql-cdts/tests/orderby/order-map-12.rq b/src/test/resources/sparql-cdts/tests/orderby/order-map-12.rq new file mode 100644 index 00000000..4e6b3685 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/orderby/order-map-12.rq @@ -0,0 +1,18 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + { + SELECT * WHERE { + VALUES (?id ?map) { + (1 "{1:42}"^^cdt:Map) + (2 "{ }"^^cdt:Map) + (3 "{ 2:42}"^^cdt:Map) # the spaces are on purpose, to make sure the comparison is not done in terms of the lexical forms + (4 "{ }"^^cdt:Map) + (5 "{3:42}"^^cdt:Map) + } + } + ORDER BY ?map LIMIT 1 + } + FILTER ( (?id = 2) || (?id = 4) ) +} diff --git a/src/test/resources/sparql-cdts/tests/orderby/order-map-13.rq b/src/test/resources/sparql-cdts/tests/orderby/order-map-13.rq new file mode 100644 index 00000000..9386a467 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/orderby/order-map-13.rq @@ -0,0 +1,15 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + { + SELECT * WHERE { + VALUES (?id ?map) { + (1 "{ 1: 42, 3: 42}"^^cdt:Map) + (2 "{1: 42}"^^cdt:Map) # the space is on purpose, to make sure the comparison is not done in terms of the lexical forms + } + } + ORDER BY ?map LIMIT 1 + } + FILTER (?id = 2) +} diff --git a/src/test/resources/sparql-cdts/tests/orderby/order-map-14.rq b/src/test/resources/sparql-cdts/tests/orderby/order-map-14.rq new file mode 100644 index 00000000..f5715319 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/orderby/order-map-14.rq @@ -0,0 +1,15 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + { + SELECT * WHERE { + VALUES (?id ?map) { + (1 "{1: 42, 3: 42}"^^cdt:Map) + (2 " {2: 42}"^^cdt:Map) + } + } + ORDER BY ?map LIMIT 1 + } + FILTER (?id = 1) +} diff --git a/src/test/resources/sparql-cdts/tests/orderby/order-map-15.rq b/src/test/resources/sparql-cdts/tests/orderby/order-map-15.rq new file mode 100644 index 00000000..d0682ae9 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/orderby/order-map-15.rq @@ -0,0 +1,15 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + { + SELECT * WHERE { + VALUES (?id ?map) { + (1 "{1: 42, 3: 42}"^^cdt:Map) + (2 " {1: 43}"^^cdt:Map) + } + } + ORDER BY ?map LIMIT 1 + } + FILTER (?id = 1) +} diff --git a/src/test/resources/sparql-cdts/tests/orderby/order-map-16.rq b/src/test/resources/sparql-cdts/tests/orderby/order-map-16.rq new file mode 100644 index 00000000..3dab6475 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/orderby/order-map-16.rq @@ -0,0 +1,15 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + { + SELECT * WHERE { + VALUES (?id ?map) { + (1 " {1: 42, 3: 42}"^^cdt:Map) + (2 "{1: 42, 2: 42}"^^cdt:Map) + } + } + ORDER BY ?map LIMIT 1 + } + FILTER (?id = 2) +} diff --git a/src/test/resources/sparql-cdts/tests/orderby/order-map-17.rq b/src/test/resources/sparql-cdts/tests/orderby/order-map-17.rq new file mode 100644 index 00000000..18fa2bde --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/orderby/order-map-17.rq @@ -0,0 +1,15 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + { + SELECT * WHERE { + VALUES (?id ?map) { + (1 "{3: 41, 1: 42, 2: 43}"^^cdt:Map) + (2 "{3: 42, 1: 42, 2: 42}"^^cdt:Map) + } + } + ORDER BY ?map LIMIT 1 + } + FILTER (?id = 2) +} diff --git a/src/test/resources/sparql-cdts/tests/orderby/order-map-null-01.rq b/src/test/resources/sparql-cdts/tests/orderby/order-map-null-01.rq new file mode 100644 index 00000000..d1cadd64 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/orderby/order-map-null-01.rq @@ -0,0 +1,15 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + { + SELECT * WHERE { + VALUES (?id ?map) { + (1 "{ 1:null, 2:42}"^^cdt:Map) # the added space is on purpose, to make sure the comparison is not done in terms of the lexical forms + (2 "{1:null, 2:41}"^^cdt:Map) + } + } + ORDER BY ?map LIMIT 1 + } + FILTER (?id = 2) +} diff --git a/src/test/resources/sparql-cdts/tests/orderby/order-map-null-02.rq b/src/test/resources/sparql-cdts/tests/orderby/order-map-null-02.rq new file mode 100644 index 00000000..0d4d90db --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/orderby/order-map-null-02.rq @@ -0,0 +1,16 @@ +PREFIX cdt: +PREFIX xsd: + +ASK { + { + SELECT * WHERE { + VALUES (?id ?map) { + (1 "{ 1:null, 2:41}"^^cdt:Map) + (2 "{ 1:'hello', 2:42}"^^cdt:Map) + (3 "{ 1:null, 2:43}"^^cdt:Map) + } + } + ORDER BY DESC(?map) LIMIT 1 # attention, DESC here to check that the non-null element ordered highest + } + FILTER (?id = 2) +} diff --git a/src/test/resources/sparql-cdts/tests/orderby/true.srx b/src/test/resources/sparql-cdts/tests/orderby/true.srx new file mode 100644 index 00000000..c187f066 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/orderby/true.srx @@ -0,0 +1,5 @@ + + + + true + diff --git a/src/test/resources/sparql-cdts/tests/unfold/empty.ttl b/src/test/resources/sparql-cdts/tests/unfold/empty.ttl new file mode 100644 index 00000000..e69de29b diff --git a/src/test/resources/sparql-cdts/tests/unfold/manifest.ttl b/src/test/resources/sparql-cdts/tests/unfold/manifest.ttl new file mode 100644 index 00000000..a829a67e --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/unfold/manifest.ttl @@ -0,0 +1,483 @@ +@prefix rdf: . +@prefix : . +@prefix rdfs: . +@prefix mf: . +@prefix qt: . +@prefix dawgt: . +@prefix sparql: . +@prefix cdt: . + +<> rdf:type mf:Manifest ; + rdfs:label "SPARQL UNFOLD operator" ; + mf:entries + ( + :unfold-list-1var-01 + :unfold-list-1var-02 + :unfold-list-1var-03 + :unfold-list-1var-04 + :unfold-list-1var-05 + :unfold-list-1var-06 + :unfold-list-1var-07 + :unfold-list-1var-08 + :unfold-list-1var-09 + :unfold-list-1var-10 + + :unfold-get-list-1var-01 + :unfold-get-list-1var-02 + :unfold-get-list-1var-03 + :unfold-get-list-1var-04 + + :unfold-list-2vars-01 + :unfold-list-2vars-02 + :unfold-list-2vars-03 + :unfold-list-2vars-04 + :unfold-list-2vars-05 + :unfold-list-2vars-06 + :unfold-list-2vars-07 + :unfold-list-2vars-08 + :unfold-list-2vars-09 + :unfold-list-2vars-10 + + :unfold-get-list-2vars-01 + :unfold-get-list-2vars-02 + :unfold-get-list-2vars-03 + :unfold-get-list-2vars-04 + :unfold-get-list-2vars-05 + :unfold-get-list-2vars-06 + + :unfold-map-1var-01 + :unfold-map-1var-02 + :unfold-map-1var-03 + :unfold-map-1var-04 + + :unfold-map-2vars-01 + :unfold-map-2vars-02 + :unfold-map-2vars-03 + :unfold-map-2vars-04 + :unfold-map-2vars-05 + :unfold-map-2vars-06 + :unfold-map-2vars-07 + :unfold-map-2vars-08 + ) . + +:unfold-list-1var-01 rdf:type mf:QueryEvaluationTest ; + mf:name "unfold-list-1var-01" ; + rdfs:comment "two list elements" ; + mf:feature cdt:unfold ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result . + +:unfold-list-1var-02 rdf:type mf:QueryEvaluationTest ; + mf:name "unfold-list-1var-02" ; + rdfs:comment "three list elements, including a duplicate" ; + mf:feature cdt:unfold ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result . + +:unfold-list-1var-03 rdf:type mf:QueryEvaluationTest ; + mf:name "unfold-list-1var-03" ; + rdfs:comment "two list elements, mixed datatypes" ; + mf:feature cdt:unfold ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result . + +:unfold-list-1var-04 rdf:type mf:QueryEvaluationTest ; + mf:name "unfold-list-1var-04" ; + rdfs:comment "two list elements, IRIs" ; + mf:feature cdt:unfold ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result . + +:unfold-list-1var-05 rdf:type mf:QueryEvaluationTest ; + mf:name "unfold-list-1var-05" ; + rdfs:comment "two list elements, IRI and literal" ; + mf:feature cdt:unfold ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result . + +:unfold-list-1var-06 rdf:type mf:QueryEvaluationTest ; + mf:name "unfold-list-1var-06" ; + rdfs:comment "two list elements, IRI and blank node" ; + mf:feature cdt:unfold ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result . + +:unfold-list-1var-07 rdf:type mf:QueryEvaluationTest ; + mf:name "unfold-list-1var-07" ; + rdfs:comment "three list elements, IRI and two distinct blank nodes" ; + mf:feature cdt:unfold ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result . + +:unfold-list-1var-08 rdf:type mf:QueryEvaluationTest ; + mf:name "unfold-list-1var-08" ; + rdfs:comment "three list elements, IRI and the same blank node twice" ; + mf:feature cdt:unfold ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result . + +:unfold-list-1var-09 rdf:type mf:QueryEvaluationTest ; + mf:name "unfold-list-1var-09" ; + rdfs:comment "two list elements, IRI and null value" ; + mf:feature cdt:unfold ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result . + +:unfold-list-1var-10 rdf:type mf:QueryEvaluationTest ; + mf:name "unfold-list-1var-10" ; + rdfs:comment "three list elements, IRI and two null values" ; + mf:feature cdt:unfold ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result . + + + +:unfold-get-list-1var-01 rdf:type mf:QueryEvaluationTest ; + mf:name "unfold-get-list-1var-01" ; + rdfs:comment "list literal with one blank node" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result . + +:unfold-get-list-1var-02 rdf:type mf:QueryEvaluationTest ; + mf:name "unfold-get-list-1var-02" ; + rdfs:comment "list literal with the same blank node twice" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result . + +:unfold-get-list-1var-03 rdf:type mf:QueryEvaluationTest ; + mf:name "unfold-get-list-1var-03" ; + rdfs:comment "construct list with one blank node" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result . + +:unfold-get-list-1var-04 rdf:type mf:QueryEvaluationTest ; + mf:name "unfold-get-list-1var-04" ; + rdfs:comment "construct list with the same blank node twice" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result . + + + +:unfold-list-2vars-01 rdf:type mf:QueryEvaluationTest ; + mf:name "unfold-list-2vars-01" ; + rdfs:comment "two list elements" ; + mf:feature cdt:unfold ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result . + +:unfold-list-2vars-02 rdf:type mf:QueryEvaluationTest ; + mf:name "unfold-list-2vars-02" ; + rdfs:comment "three list elements, including a duplicate" ; + mf:feature cdt:unfold ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result . + +:unfold-list-2vars-03 rdf:type mf:QueryEvaluationTest ; + mf:name "unfold-list-2vars-03" ; + rdfs:comment "two list elements, mixed datatypes" ; + mf:feature cdt:unfold ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result . + +:unfold-list-2vars-04 rdf:type mf:QueryEvaluationTest ; + mf:name "unfold-list-2vars-04" ; + rdfs:comment "two list elements, IRIs" ; + mf:feature cdt:unfold ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result . + +:unfold-list-2vars-05 rdf:type mf:QueryEvaluationTest ; + mf:name "unfold-list-2vars-05" ; + rdfs:comment "two list elements, IRI and literal" ; + mf:feature cdt:unfold ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result . + +:unfold-list-2vars-06 rdf:type mf:QueryEvaluationTest ; + mf:name "unfold-list-2vars-06" ; + rdfs:comment "two list elements, IRI and blank node" ; + mf:feature cdt:unfold ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result . + +:unfold-list-2vars-07 rdf:type mf:QueryEvaluationTest ; + mf:name "unfold-list-2vars-07" ; + rdfs:comment "three list elements, IRI and two distinct blank nodes" ; + mf:feature cdt:unfold ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result . + +:unfold-list-2vars-08 rdf:type mf:QueryEvaluationTest ; + mf:name "unfold-list-2vars-08" ; + rdfs:comment "three list elements, IRI and the same blank node twice" ; + mf:feature cdt:unfold ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result . + +:unfold-list-2vars-09 rdf:type mf:QueryEvaluationTest ; + mf:name "unfold-list-2vars-09" ; + rdfs:comment "two list elements, IRI and null value" ; + mf:feature cdt:unfold ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result . + +:unfold-list-2vars-10 rdf:type mf:QueryEvaluationTest ; + mf:name "unfold-list-2vars-10" ; + rdfs:comment "three list elements, IRI and two null values" ; + mf:feature cdt:unfold ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result . + + + +:unfold-get-list-2vars-01 rdf:type mf:QueryEvaluationTest ; + mf:name "unfold-get-list-2vars-01" ; + rdfs:comment "list literal with one blank node" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result . + +:unfold-get-list-2vars-02 rdf:type mf:QueryEvaluationTest ; + mf:name "unfold-get-list-2vars-02" ; + rdfs:comment "list literal with the same blank node twice" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result . + +:unfold-get-list-2vars-03 rdf:type mf:QueryEvaluationTest ; + mf:name "unfold-get-list-2vars-03" ; + rdfs:comment "construct list with one blank node" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result . + +:unfold-get-list-2vars-04 rdf:type mf:QueryEvaluationTest ; + mf:name "unfold-get-list-2vars-04" ; + rdfs:comment "construct list with the same blank node twice" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result . + +:unfold-get-list-2vars-05 rdf:type mf:QueryEvaluationTest ; + mf:name "unfold-get-list-2vars-05" ; + rdfs:comment "list literal with the two blank nodes" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result . + +:unfold-get-list-2vars-06 rdf:type mf:QueryEvaluationTest ; + mf:name "unfold-get-list-2vars-06" ; + rdfs:comment "construct list with the two blank nodes" ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result . + + + +:unfold-map-1var-01 rdf:type mf:QueryEvaluationTest ; + mf:name "unfold-map-1var-01" ; + rdfs:comment "two entries, integer keys" ; + mf:feature cdt:unfold ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result . + +:unfold-map-1var-02 rdf:type mf:QueryEvaluationTest ; + mf:name "unfold-map-1var-02" ; + rdfs:comment "two entries, mixed literal keys" ; + mf:feature cdt:unfold ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result . + +:unfold-map-1var-03 rdf:type mf:QueryEvaluationTest ; + mf:name "unfold-map-1var-03" ; + rdfs:comment "two entries, IRI keys" ; + mf:feature cdt:unfold ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result . + +:unfold-map-1var-04 rdf:type mf:QueryEvaluationTest ; + mf:name "unfold-map-1var-04" ; + rdfs:comment "two entries, IRI and literal key" ; + mf:feature cdt:unfold ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result . + + + +:unfold-map-2vars-01 rdf:type mf:QueryEvaluationTest ; + mf:name "unfold-map-2vars-01" ; + rdfs:comment "two entries, different values" ; + mf:feature cdt:unfold ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result . + +:unfold-map-2vars-02 rdf:type mf:QueryEvaluationTest ; + mf:name "unfold-map-2vars-02" ; + rdfs:comment "two entries, same values" ; + mf:feature cdt:unfold ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result . + +:unfold-map-2vars-03 rdf:type mf:QueryEvaluationTest ; + mf:name "unfold-map-2vars-03" ; + rdfs:comment "two entries, mixed types" ; + mf:feature cdt:unfold ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result . + +:unfold-map-2vars-04 rdf:type mf:QueryEvaluationTest ; + mf:name "unfold-map-2vars-04" ; + rdfs:comment "two entries, IRI keys" ; + mf:feature cdt:unfold ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result . + +:unfold-map-2vars-05 rdf:type mf:QueryEvaluationTest ; + mf:name "unfold-map-2vars-05" ; + rdfs:comment "two entries, IRI values" ; + mf:feature cdt:unfold ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result . + +:unfold-map-2vars-06 rdf:type mf:QueryEvaluationTest ; + mf:name "unfold-map-2vars-06" ; + rdfs:comment "two entries, distinct blank nodes as values" ; + mf:feature cdt:unfold ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result . + +:unfold-map-2vars-07 rdf:type mf:QueryEvaluationTest ; + mf:name "unfold-map-2vars-07" ; + rdfs:comment "two entries, same blank node as values" ; + mf:feature cdt:unfold ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result . + +:unfold-map-2vars-08 rdf:type mf:QueryEvaluationTest ; + mf:name "unfold-map-2vars-08" ; + rdfs:comment "two entries, one with a null value as value" ; + mf:feature cdt:unfold ; + dawgt:approval dawgt:Proposed ; + mf:action + [ qt:query ; + qt:data ] ; + mf:result . + + diff --git a/src/test/resources/sparql-cdts/tests/unfold/true.srx b/src/test/resources/sparql-cdts/tests/unfold/true.srx new file mode 100644 index 00000000..c187f066 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/unfold/true.srx @@ -0,0 +1,5 @@ + + + + true + diff --git a/src/test/resources/sparql-cdts/tests/unfold/unfold-get-list-1var-01.rq b/src/test/resources/sparql-cdts/tests/unfold/unfold-get-list-1var-01.rq new file mode 100644 index 00000000..e344e558 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/unfold/unfold-get-list-1var-01.rq @@ -0,0 +1,7 @@ +PREFIX cdt: + +ASK { + BIND( "[_:b]"^^cdt:List AS ?list ) + UNFOLD( ?list AS ?elmt ) + FILTER( SAMETERM(?elmt, cdt:get(?list,1)) ) +} diff --git a/src/test/resources/sparql-cdts/tests/unfold/unfold-get-list-1var-02.rq b/src/test/resources/sparql-cdts/tests/unfold/unfold-get-list-1var-02.rq new file mode 100644 index 00000000..2f13d682 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/unfold/unfold-get-list-1var-02.rq @@ -0,0 +1,7 @@ +PREFIX cdt: + +ASK { + BIND( "[_:b, _:b]"^^cdt:List AS ?list ) + UNFOLD( ?list AS ?elmt ) + FILTER( SAMETERM(?elmt, cdt:get(?list,1)) ) +} diff --git a/src/test/resources/sparql-cdts/tests/unfold/unfold-get-list-1var-03.rq b/src/test/resources/sparql-cdts/tests/unfold/unfold-get-list-1var-03.rq new file mode 100644 index 00000000..214fb1b5 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/unfold/unfold-get-list-1var-03.rq @@ -0,0 +1,9 @@ +PREFIX cdt: + +ASK { + BIND ( BNODE() AS ?b ) + BIND( cdt:List(?b) AS ?list ) + + UNFOLD( ?list AS ?elmt ) + FILTER( SAMETERM(?elmt, cdt:get(?list,1)) ) +} diff --git a/src/test/resources/sparql-cdts/tests/unfold/unfold-get-list-1var-04.rq b/src/test/resources/sparql-cdts/tests/unfold/unfold-get-list-1var-04.rq new file mode 100644 index 00000000..5dfa74d7 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/unfold/unfold-get-list-1var-04.rq @@ -0,0 +1,9 @@ +PREFIX cdt: + +ASK { + BIND ( BNODE() AS ?b ) + BIND( cdt:List(?b, ?b) AS ?list ) + + UNFOLD( ?list AS ?elmt ) + FILTER( SAMETERM(?elmt, cdt:get(?list,1)) ) +} diff --git a/src/test/resources/sparql-cdts/tests/unfold/unfold-get-list-2vars-01.rq b/src/test/resources/sparql-cdts/tests/unfold/unfold-get-list-2vars-01.rq new file mode 100644 index 00000000..691b0720 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/unfold/unfold-get-list-2vars-01.rq @@ -0,0 +1,7 @@ +PREFIX cdt: + +ASK { + BIND( "[_:b]"^^cdt:List AS ?list ) + UNFOLD( ?list AS ?elmt, ?idx ) + FILTER( SAMETERM(?elmt, cdt:get(?list,1)) ) +} diff --git a/src/test/resources/sparql-cdts/tests/unfold/unfold-get-list-2vars-02.rq b/src/test/resources/sparql-cdts/tests/unfold/unfold-get-list-2vars-02.rq new file mode 100644 index 00000000..69b8cd3d --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/unfold/unfold-get-list-2vars-02.rq @@ -0,0 +1,7 @@ +PREFIX cdt: + +ASK { + BIND( "[_:b, _:b]"^^cdt:List AS ?list ) + UNFOLD( ?list AS ?elmt, ?idx ) + FILTER( SAMETERM(?elmt, cdt:get(?list,1)) ) +} diff --git a/src/test/resources/sparql-cdts/tests/unfold/unfold-get-list-2vars-03.rq b/src/test/resources/sparql-cdts/tests/unfold/unfold-get-list-2vars-03.rq new file mode 100644 index 00000000..19cb28e8 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/unfold/unfold-get-list-2vars-03.rq @@ -0,0 +1,9 @@ +PREFIX cdt: + +ASK { + BIND ( BNODE() AS ?b ) + BIND( cdt:List(?b) AS ?list ) + + UNFOLD( ?list AS ?elmt, ?idx ) + FILTER( SAMETERM(?elmt, cdt:get(?list,1)) ) +} diff --git a/src/test/resources/sparql-cdts/tests/unfold/unfold-get-list-2vars-04.rq b/src/test/resources/sparql-cdts/tests/unfold/unfold-get-list-2vars-04.rq new file mode 100644 index 00000000..7aa08d91 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/unfold/unfold-get-list-2vars-04.rq @@ -0,0 +1,9 @@ +PREFIX cdt: + +ASK { + BIND ( BNODE() AS ?b ) + BIND( cdt:List(?b, ?b) AS ?list ) + + UNFOLD( ?list AS ?elmt, ?idx ) + FILTER( SAMETERM(?elmt, cdt:get(?list,1)) ) +} diff --git a/src/test/resources/sparql-cdts/tests/unfold/unfold-get-list-2vars-05.rq b/src/test/resources/sparql-cdts/tests/unfold/unfold-get-list-2vars-05.rq new file mode 100644 index 00000000..90dc68d5 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/unfold/unfold-get-list-2vars-05.rq @@ -0,0 +1,7 @@ +PREFIX cdt: + +ASK { + BIND( "[_:b1, _:b2]"^^cdt:List AS ?list ) + UNFOLD( ?list AS ?elmt, ?idx ) + FILTER( SAMETERM(?elmt, cdt:get(?list,?idx)) ) +} diff --git a/src/test/resources/sparql-cdts/tests/unfold/unfold-get-list-2vars-06.rq b/src/test/resources/sparql-cdts/tests/unfold/unfold-get-list-2vars-06.rq new file mode 100644 index 00000000..8da24a45 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/unfold/unfold-get-list-2vars-06.rq @@ -0,0 +1,10 @@ +PREFIX cdt: + +ASK { + BIND ( BNODE() AS ?b1 ) + BIND ( BNODE() AS ?b2 ) + BIND( cdt:List(?b1, ?b2) AS ?list ) + + UNFOLD( ?list AS ?elmt, ?idx ) + FILTER( SAMETERM(?elmt, cdt:get(?list,?idx)) ) +} diff --git a/src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-01.rq b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-01.rq new file mode 100644 index 00000000..ecb6d874 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-01.rq @@ -0,0 +1,6 @@ +PREFIX cdt: + +SELECT ?elmt WHERE { + BIND( "[1,2]"^^cdt:List AS ?list ) + UNFOLD( ?list AS ?elmt ) +} diff --git a/src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-01.srj b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-01.srj new file mode 100644 index 00000000..3f575cee --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-01.srj @@ -0,0 +1,14 @@ +{ "head": { + "vars": [ "elmt" ] + } , + "results": { + "bindings": [ + { + "elmt": { "type": "literal" , "datatype": "http://www.w3.org/2001/XMLSchema#integer" , "value": "1" } + }, + { + "elmt": { "type": "literal" , "datatype": "http://www.w3.org/2001/XMLSchema#integer" , "value": "2" } + } + ] + } +} diff --git a/src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-02.rq b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-02.rq new file mode 100644 index 00000000..71186ea1 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-02.rq @@ -0,0 +1,6 @@ +PREFIX cdt: + +SELECT ?elmt WHERE { + BIND( "[1,1,2]"^^cdt:List AS ?list ) + UNFOLD( ?list AS ?elmt ) +} diff --git a/src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-02.srj b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-02.srj new file mode 100644 index 00000000..68ae874d --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-02.srj @@ -0,0 +1,17 @@ +{ "head": { + "vars": [ "elmt" ] + } , + "results": { + "bindings": [ + { + "elmt": { "type": "literal" , "datatype": "http://www.w3.org/2001/XMLSchema#integer" , "value": "1" } + }, + { + "elmt": { "type": "literal" , "datatype": "http://www.w3.org/2001/XMLSchema#integer" , "value": "1" } + }, + { + "elmt": { "type": "literal" , "datatype": "http://www.w3.org/2001/XMLSchema#integer" , "value": "2" } + } + ] + } +} diff --git a/src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-03.rq b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-03.rq new file mode 100644 index 00000000..1c0dbfae --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-03.rq @@ -0,0 +1,6 @@ +PREFIX cdt: + +SELECT ?elmt WHERE { + BIND( "[true,1]"^^cdt:List AS ?list ) + UNFOLD( ?list AS ?elmt ) +} diff --git a/src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-03.srj b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-03.srj new file mode 100644 index 00000000..ab85d1f1 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-03.srj @@ -0,0 +1,14 @@ +{ "head": { + "vars": [ "elmt" ] + } , + "results": { + "bindings": [ + { + "elmt": { "type": "literal" , "datatype": "http://www.w3.org/2001/XMLSchema#integer" , "value": "1" } + }, + { + "elmt": { "type": "literal" , "datatype": "http://www.w3.org/2001/XMLSchema#boolean" , "value": "true" } + } + ] + } +} diff --git a/src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-04.rq b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-04.rq new file mode 100644 index 00000000..b3316a4f --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-04.rq @@ -0,0 +1,6 @@ +PREFIX cdt: + +SELECT ?elmt WHERE { + BIND( "[, ]"^^cdt:List AS ?list ) + UNFOLD( ?list AS ?elmt ) +} diff --git a/src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-04.srj b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-04.srj new file mode 100644 index 00000000..2c8585a9 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-04.srj @@ -0,0 +1,14 @@ +{ "head": { + "vars": [ "elmt" ] + } , + "results": { + "bindings": [ + { + "elmt": { "type": "uri" , "value": "http://example/1" } + }, + { + "elmt": { "type": "uri" , "value": "http://example/2" } + } + ] + } +} diff --git a/src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-05.rq b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-05.rq new file mode 100644 index 00000000..7e9df68d --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-05.rq @@ -0,0 +1,6 @@ +PREFIX cdt: + +SELECT ?elmt WHERE { + BIND( "[, 1]"^^cdt:List AS ?list ) + UNFOLD( ?list AS ?elmt ) +} diff --git a/src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-05.srj b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-05.srj new file mode 100644 index 00000000..e5acb974 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-05.srj @@ -0,0 +1,14 @@ +{ "head": { + "vars": [ "elmt" ] + } , + "results": { + "bindings": [ + { + "elmt": { "type": "uri" , "value": "http://example/1" } + }, + { + "elmt": { "type": "literal" , "datatype": "http://www.w3.org/2001/XMLSchema#integer" , "value": "1" } + } + ] + } +} diff --git a/src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-06.rq b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-06.rq new file mode 100644 index 00000000..7135d89f --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-06.rq @@ -0,0 +1,6 @@ +PREFIX cdt: + +SELECT ?elmt WHERE { + BIND( "[, _:x]"^^cdt:List AS ?list ) + UNFOLD( ?list AS ?elmt ) +} diff --git a/src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-06.srj b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-06.srj new file mode 100644 index 00000000..9c313fe0 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-06.srj @@ -0,0 +1,14 @@ +{ "head": { + "vars": [ "elmt" ] + } , + "results": { + "bindings": [ + { + "elmt": { "type": "uri" , "value": "http://example/1" } + }, + { + "elmt": { "type": "bnode" , "value": "b0" } + } + ] + } +} diff --git a/src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-07.rq b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-07.rq new file mode 100644 index 00000000..e13150d1 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-07.rq @@ -0,0 +1,6 @@ +PREFIX cdt: + +SELECT ?elmt WHERE { + BIND( "[, _:x, _:y]"^^cdt:List AS ?list ) + UNFOLD( ?list AS ?elmt ) +} diff --git a/src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-07.srj b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-07.srj new file mode 100644 index 00000000..f9a5b2ce --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-07.srj @@ -0,0 +1,17 @@ +{ "head": { + "vars": [ "elmt" ] + } , + "results": { + "bindings": [ + { + "elmt": { "type": "uri" , "value": "http://example/1" } + }, + { + "elmt": { "type": "bnode" , "value": "b0" } + }, + { + "elmt": { "type": "bnode" , "value": "b1" } + } + ] + } +} diff --git a/src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-08.rq b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-08.rq new file mode 100644 index 00000000..ebf055b9 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-08.rq @@ -0,0 +1,6 @@ +PREFIX cdt: + +SELECT ?elmt WHERE { + BIND( "[, _:x, _:x]"^^cdt:List AS ?list ) + UNFOLD( ?list AS ?elmt ) +} diff --git a/src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-08.srj b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-08.srj new file mode 100644 index 00000000..83fd0daf --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-08.srj @@ -0,0 +1,17 @@ +{ "head": { + "vars": [ "elmt" ] + } , + "results": { + "bindings": [ + { + "elmt": { "type": "uri" , "value": "http://example/1" } + }, + { + "elmt": { "type": "bnode" , "value": "b0" } + }, + { + "elmt": { "type": "bnode" , "value": "b0" } + } + ] + } +} diff --git a/src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-09.rq b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-09.rq new file mode 100644 index 00000000..7fef59f6 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-09.rq @@ -0,0 +1,6 @@ +PREFIX cdt: + +SELECT ?elmt WHERE { + BIND( "[, null]"^^cdt:List AS ?list ) + UNFOLD( ?list AS ?elmt ) +} diff --git a/src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-09.srj b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-09.srj new file mode 100644 index 00000000..19199bc0 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-09.srj @@ -0,0 +1,13 @@ +{ "head": { + "vars": [ "elmt" ] + } , + "results": { + "bindings": [ + { + "elmt": { "type": "uri" , "value": "http://example/1" } + }, + { + } + ] + } +} diff --git a/src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-10.rq b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-10.rq new file mode 100644 index 00000000..692f520c --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-10.rq @@ -0,0 +1,6 @@ +PREFIX cdt: + +SELECT ?elmt WHERE { + BIND( "[, null, null]"^^cdt:List AS ?list ) + UNFOLD( ?list AS ?elmt ) +} diff --git a/src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-10.srj b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-10.srj new file mode 100644 index 00000000..2cd1d2cb --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-1var-10.srj @@ -0,0 +1,15 @@ +{ "head": { + "vars": [ "elmt" ] + } , + "results": { + "bindings": [ + { + "elmt": { "type": "uri" , "value": "http://example/1" } + }, + { + }, + { + } + ] + } +} diff --git a/src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-01.rq b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-01.rq new file mode 100644 index 00000000..65854604 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-01.rq @@ -0,0 +1,6 @@ +PREFIX cdt: + +SELECT ?elmt ?idx WHERE { + BIND( "[1,2]"^^cdt:List AS ?list ) + UNFOLD( ?list AS ?elmt, ?idx ) +} diff --git a/src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-01.srj b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-01.srj new file mode 100644 index 00000000..d72c9080 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-01.srj @@ -0,0 +1,16 @@ +{ "head": { + "vars": [ "elmt", "idx" ] + } , + "results": { + "bindings": [ + { + "elmt": { "type": "literal" , "datatype": "http://www.w3.org/2001/XMLSchema#integer" , "value": "1" }, + "idx": { "type": "literal" , "datatype": "http://www.w3.org/2001/XMLSchema#integer" , "value": "1" } + }, + { + "elmt": { "type": "literal" , "datatype": "http://www.w3.org/2001/XMLSchema#integer" , "value": "2" }, + "idx": { "type": "literal" , "datatype": "http://www.w3.org/2001/XMLSchema#integer" , "value": "2" } + } + ] + } +} diff --git a/src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-02.rq b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-02.rq new file mode 100644 index 00000000..0c332c48 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-02.rq @@ -0,0 +1,6 @@ +PREFIX cdt: + +SELECT ?elmt ?idx WHERE { + BIND( "[1,1,2]"^^cdt:List AS ?list ) + UNFOLD( ?list AS ?elmt, ?idx ) +} diff --git a/src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-02.srj b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-02.srj new file mode 100644 index 00000000..9c161ea7 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-02.srj @@ -0,0 +1,20 @@ +{ "head": { + "vars": [ "elmt", "idx" ] + } , + "results": { + "bindings": [ + { + "elmt": { "type": "literal" , "datatype": "http://www.w3.org/2001/XMLSchema#integer" , "value": "1" }, + "idx": { "type": "literal" , "datatype": "http://www.w3.org/2001/XMLSchema#integer" , "value": "1" } + }, + { + "elmt": { "type": "literal" , "datatype": "http://www.w3.org/2001/XMLSchema#integer" , "value": "1" }, + "idx": { "type": "literal" , "datatype": "http://www.w3.org/2001/XMLSchema#integer" , "value": "2" } + }, + { + "elmt": { "type": "literal" , "datatype": "http://www.w3.org/2001/XMLSchema#integer" , "value": "2" }, + "idx": { "type": "literal" , "datatype": "http://www.w3.org/2001/XMLSchema#integer" , "value": "3" } + } + ] + } +} diff --git a/src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-03.rq b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-03.rq new file mode 100644 index 00000000..5c0a76f1 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-03.rq @@ -0,0 +1,6 @@ +PREFIX cdt: + +SELECT ?elmt ?idx WHERE { + BIND( "[true,1]"^^cdt:List AS ?list ) + UNFOLD( ?list AS ?elmt, ?idx ) +} diff --git a/src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-03.srj b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-03.srj new file mode 100644 index 00000000..7e3b9f7a --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-03.srj @@ -0,0 +1,16 @@ +{ "head": { + "vars": [ "elmt", "idx" ] + } , + "results": { + "bindings": [ + { + "elmt": { "type": "literal" , "datatype": "http://www.w3.org/2001/XMLSchema#integer" , "value": "1" }, + "idx": { "type": "literal" , "datatype": "http://www.w3.org/2001/XMLSchema#integer" , "value": "2" } + }, + { + "elmt": { "type": "literal" , "datatype": "http://www.w3.org/2001/XMLSchema#boolean" , "value": "true" }, + "idx": { "type": "literal" , "datatype": "http://www.w3.org/2001/XMLSchema#integer" , "value": "1" } + } + ] + } +} diff --git a/src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-04.rq b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-04.rq new file mode 100644 index 00000000..2538eb46 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-04.rq @@ -0,0 +1,6 @@ +PREFIX cdt: + +SELECT ?elmt ?idx WHERE { + BIND( "[, ]"^^cdt:List AS ?list ) + UNFOLD( ?list AS ?elmt, ?idx ) +} diff --git a/src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-04.srj b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-04.srj new file mode 100644 index 00000000..426591f5 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-04.srj @@ -0,0 +1,16 @@ +{ "head": { + "vars": [ "elmt", "idx" ] + } , + "results": { + "bindings": [ + { + "elmt": { "type": "uri" , "value": "http://example/1" }, + "idx": { "type": "literal" , "datatype": "http://www.w3.org/2001/XMLSchema#integer" , "value": "1" } + }, + { + "elmt": { "type": "uri" , "value": "http://example/2" }, + "idx": { "type": "literal" , "datatype": "http://www.w3.org/2001/XMLSchema#integer" , "value": "2" } + } + ] + } +} diff --git a/src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-05.rq b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-05.rq new file mode 100644 index 00000000..c9fe7cf1 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-05.rq @@ -0,0 +1,6 @@ +PREFIX cdt: + +SELECT ?elmt ?idx WHERE { + BIND( "[, 1]"^^cdt:List AS ?list ) + UNFOLD( ?list AS ?elmt, ?idx ) +} diff --git a/src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-05.srj b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-05.srj new file mode 100644 index 00000000..0b3ff6f7 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-05.srj @@ -0,0 +1,16 @@ +{ "head": { + "vars": [ "elmt", "idx" ] + } , + "results": { + "bindings": [ + { + "elmt": { "type": "uri" , "value": "http://example/1" }, + "idx": { "type": "literal" , "datatype": "http://www.w3.org/2001/XMLSchema#integer" , "value": "1" } + }, + { + "elmt": { "type": "literal" , "datatype": "http://www.w3.org/2001/XMLSchema#integer" , "value": "1" }, + "idx": { "type": "literal" , "datatype": "http://www.w3.org/2001/XMLSchema#integer" , "value": "2" } + } + ] + } +} diff --git a/src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-06.rq b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-06.rq new file mode 100644 index 00000000..69596252 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-06.rq @@ -0,0 +1,6 @@ +PREFIX cdt: + +SELECT ?elmt ?idx WHERE { + BIND( "[, _:x]"^^cdt:List AS ?list ) + UNFOLD( ?list AS ?elmt, ?idx ) +} diff --git a/src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-06.srj b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-06.srj new file mode 100644 index 00000000..45f10b33 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-06.srj @@ -0,0 +1,16 @@ +{ "head": { + "vars": [ "elmt", "idx" ] + } , + "results": { + "bindings": [ + { + "elmt": { "type": "uri" , "value": "http://example/1" }, + "idx": { "type": "literal" , "datatype": "http://www.w3.org/2001/XMLSchema#integer" , "value": "1" } + }, + { + "elmt": { "type": "bnode" , "value": "b0" }, + "idx": { "type": "literal" , "datatype": "http://www.w3.org/2001/XMLSchema#integer" , "value": "2" } + } + ] + } +} diff --git a/src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-07.rq b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-07.rq new file mode 100644 index 00000000..ccb4c466 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-07.rq @@ -0,0 +1,6 @@ +PREFIX cdt: + +SELECT ?elmt ?idx WHERE { + BIND( "[, _:x, _:y]"^^cdt:List AS ?list ) + UNFOLD( ?list AS ?elmt, ?idx ) +} diff --git a/src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-07.srj b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-07.srj new file mode 100644 index 00000000..db239ce3 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-07.srj @@ -0,0 +1,20 @@ +{ "head": { + "vars": [ "elmt", "idx" ] + } , + "results": { + "bindings": [ + { + "elmt": { "type": "uri" , "value": "http://example/1" }, + "idx": { "type": "literal" , "datatype": "http://www.w3.org/2001/XMLSchema#integer" , "value": "1" } + }, + { + "elmt": { "type": "bnode" , "value": "b0" }, + "idx": { "type": "literal" , "datatype": "http://www.w3.org/2001/XMLSchema#integer" , "value": "2" } + }, + { + "elmt": { "type": "bnode" , "value": "b1" }, + "idx": { "type": "literal" , "datatype": "http://www.w3.org/2001/XMLSchema#integer" , "value": "3" } + } + ] + } +} diff --git a/src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-08.rq b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-08.rq new file mode 100644 index 00000000..5a1848d8 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-08.rq @@ -0,0 +1,6 @@ +PREFIX cdt: + +SELECT ?elmt ?idx WHERE { + BIND( "[, _:x, _:x]"^^cdt:List AS ?list ) + UNFOLD( ?list AS ?elmt, ?idx ) +} diff --git a/src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-08.srj b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-08.srj new file mode 100644 index 00000000..62969f04 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-08.srj @@ -0,0 +1,20 @@ +{ "head": { + "vars": [ "elmt", "idx" ] + } , + "results": { + "bindings": [ + { + "elmt": { "type": "uri" , "value": "http://example/1" }, + "idx": { "type": "literal" , "datatype": "http://www.w3.org/2001/XMLSchema#integer" , "value": "1" } + }, + { + "elmt": { "type": "bnode" , "value": "b0" }, + "idx": { "type": "literal" , "datatype": "http://www.w3.org/2001/XMLSchema#integer" , "value": "2" } + }, + { + "elmt": { "type": "bnode" , "value": "b0" }, + "idx": { "type": "literal" , "datatype": "http://www.w3.org/2001/XMLSchema#integer" , "value": "3" } + } + ] + } +} diff --git a/src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-09.rq b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-09.rq new file mode 100644 index 00000000..689a8009 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-09.rq @@ -0,0 +1,6 @@ +PREFIX cdt: + +SELECT ?elmt ?idx WHERE { + BIND( "[, null]"^^cdt:List AS ?list ) + UNFOLD( ?list AS ?elmt, ?idx ) +} diff --git a/src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-09.srj b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-09.srj new file mode 100644 index 00000000..d843e62a --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-09.srj @@ -0,0 +1,15 @@ +{ "head": { + "vars": [ "elmt", "idx" ] + } , + "results": { + "bindings": [ + { + "elmt": { "type": "uri" , "value": "http://example/1" }, + "idx": { "type": "literal" , "datatype": "http://www.w3.org/2001/XMLSchema#integer" , "value": "1" } + }, + { + "idx": { "type": "literal" , "datatype": "http://www.w3.org/2001/XMLSchema#integer" , "value": "2" } + } + ] + } +} diff --git a/src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-10.rq b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-10.rq new file mode 100644 index 00000000..006e8a8d --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-10.rq @@ -0,0 +1,6 @@ +PREFIX cdt: + +SELECT ?elmt ?idx WHERE { + BIND( "[, null, null]"^^cdt:List AS ?list ) + UNFOLD( ?list AS ?elmt, ?idx ) +} diff --git a/src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-10.srj b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-10.srj new file mode 100644 index 00000000..7d7941e1 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/unfold/unfold-list-2vars-10.srj @@ -0,0 +1,18 @@ +{ "head": { + "vars": [ "elmt", "idx" ] + } , + "results": { + "bindings": [ + { + "elmt": { "type": "uri" , "value": "http://example/1" }, + "idx": { "type": "literal" , "datatype": "http://www.w3.org/2001/XMLSchema#integer" , "value": "1" } + }, + { + "idx": { "type": "literal" , "datatype": "http://www.w3.org/2001/XMLSchema#integer" , "value": "2" } + }, + { + "idx": { "type": "literal" , "datatype": "http://www.w3.org/2001/XMLSchema#integer" , "value": "3" } + } + ] + } +} diff --git a/src/test/resources/sparql-cdts/tests/unfold/unfold-map-1var-01.rq b/src/test/resources/sparql-cdts/tests/unfold/unfold-map-1var-01.rq new file mode 100644 index 00000000..62435a71 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/unfold/unfold-map-1var-01.rq @@ -0,0 +1,6 @@ +PREFIX cdt: + +SELECT ?k WHERE { + BIND( "{1:3, 2:4}"^^cdt:Map AS ?map ) + UNFOLD( ?map AS ?k ) +} diff --git a/src/test/resources/sparql-cdts/tests/unfold/unfold-map-1var-01.srj b/src/test/resources/sparql-cdts/tests/unfold/unfold-map-1var-01.srj new file mode 100644 index 00000000..ca6992e1 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/unfold/unfold-map-1var-01.srj @@ -0,0 +1,14 @@ +{ "head": { + "vars": [ "k" ] + } , + "results": { + "bindings": [ + { + "k": { "type": "literal" , "datatype": "http://www.w3.org/2001/XMLSchema#integer" , "value": "1" } + }, + { + "k": { "type": "literal" , "datatype": "http://www.w3.org/2001/XMLSchema#integer" , "value": "2" } + } + ] + } +} diff --git a/src/test/resources/sparql-cdts/tests/unfold/unfold-map-1var-02.rq b/src/test/resources/sparql-cdts/tests/unfold/unfold-map-1var-02.rq new file mode 100644 index 00000000..0a05a795 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/unfold/unfold-map-1var-02.rq @@ -0,0 +1,6 @@ +PREFIX cdt: + +SELECT ?k WHERE { + BIND( "{1:3, true:4}"^^cdt:Map AS ?map ) + UNFOLD( ?map AS ?k ) +} diff --git a/src/test/resources/sparql-cdts/tests/unfold/unfold-map-1var-02.srj b/src/test/resources/sparql-cdts/tests/unfold/unfold-map-1var-02.srj new file mode 100644 index 00000000..30993975 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/unfold/unfold-map-1var-02.srj @@ -0,0 +1,14 @@ +{ "head": { + "vars": [ "k" ] + } , + "results": { + "bindings": [ + { + "k": { "type": "literal" , "datatype": "http://www.w3.org/2001/XMLSchema#integer" , "value": "1" } + }, + { + "k": { "type": "literal" , "datatype": "http://www.w3.org/2001/XMLSchema#boolean" , "value": "true" } + } + ] + } +} diff --git a/src/test/resources/sparql-cdts/tests/unfold/unfold-map-1var-03.rq b/src/test/resources/sparql-cdts/tests/unfold/unfold-map-1var-03.rq new file mode 100644 index 00000000..316dacb8 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/unfold/unfold-map-1var-03.rq @@ -0,0 +1,6 @@ +PREFIX cdt: + +SELECT ?k WHERE { + BIND( "{:3, :4}"^^cdt:Map AS ?map ) + UNFOLD( ?map AS ?k ) +} diff --git a/src/test/resources/sparql-cdts/tests/unfold/unfold-map-1var-03.srj b/src/test/resources/sparql-cdts/tests/unfold/unfold-map-1var-03.srj new file mode 100644 index 00000000..d0f057a7 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/unfold/unfold-map-1var-03.srj @@ -0,0 +1,14 @@ +{ "head": { + "vars": [ "k" ] + } , + "results": { + "bindings": [ + { + "k": { "type": "uri" , "value": "http://example/1" } + }, + { + "k": { "type": "uri" , "value": "http://example/2" } + } + ] + } +} diff --git a/src/test/resources/sparql-cdts/tests/unfold/unfold-map-1var-04.rq b/src/test/resources/sparql-cdts/tests/unfold/unfold-map-1var-04.rq new file mode 100644 index 00000000..0fa9e06e --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/unfold/unfold-map-1var-04.rq @@ -0,0 +1,6 @@ +PREFIX cdt: + +SELECT ?k WHERE { + BIND( "{:3, 1:4}"^^cdt:Map AS ?map ) + UNFOLD( ?map AS ?k ) +} diff --git a/src/test/resources/sparql-cdts/tests/unfold/unfold-map-1var-04.srj b/src/test/resources/sparql-cdts/tests/unfold/unfold-map-1var-04.srj new file mode 100644 index 00000000..c1e21488 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/unfold/unfold-map-1var-04.srj @@ -0,0 +1,14 @@ +{ "head": { + "vars": [ "k" ] + } , + "results": { + "bindings": [ + { + "k": { "type": "uri" , "value": "http://example/1" } + }, + { + "k": { "type": "literal" , "datatype": "http://www.w3.org/2001/XMLSchema#integer" , "value": "1" } + } + ] + } +} diff --git a/src/test/resources/sparql-cdts/tests/unfold/unfold-map-2vars-01.rq b/src/test/resources/sparql-cdts/tests/unfold/unfold-map-2vars-01.rq new file mode 100644 index 00000000..52238c08 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/unfold/unfold-map-2vars-01.rq @@ -0,0 +1,6 @@ +PREFIX cdt: + +SELECT ?k ?v WHERE { + BIND( "{1:3, 2:4}"^^cdt:Map AS ?map ) + UNFOLD( ?map AS ?k, ?v ) +} diff --git a/src/test/resources/sparql-cdts/tests/unfold/unfold-map-2vars-01.srj b/src/test/resources/sparql-cdts/tests/unfold/unfold-map-2vars-01.srj new file mode 100644 index 00000000..5e621c74 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/unfold/unfold-map-2vars-01.srj @@ -0,0 +1,16 @@ +{ "head": { + "vars": [ "k", "v" ] + } , + "results": { + "bindings": [ + { + "k": { "type": "literal" , "datatype": "http://www.w3.org/2001/XMLSchema#integer" , "value": "1" }, + "v": { "type": "literal" , "datatype": "http://www.w3.org/2001/XMLSchema#integer" , "value": "3" } + }, + { + "k": { "type": "literal" , "datatype": "http://www.w3.org/2001/XMLSchema#integer" , "value": "2" }, + "v": { "type": "literal" , "datatype": "http://www.w3.org/2001/XMLSchema#integer" , "value": "4" } + } + ] + } +} diff --git a/src/test/resources/sparql-cdts/tests/unfold/unfold-map-2vars-02.rq b/src/test/resources/sparql-cdts/tests/unfold/unfold-map-2vars-02.rq new file mode 100644 index 00000000..dde67501 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/unfold/unfold-map-2vars-02.rq @@ -0,0 +1,6 @@ +PREFIX cdt: + +SELECT ?k ?v WHERE { + BIND( "{1:3, 2:3}"^^cdt:Map AS ?map ) + UNFOLD( ?map AS ?k, ?v ) +} diff --git a/src/test/resources/sparql-cdts/tests/unfold/unfold-map-2vars-02.srj b/src/test/resources/sparql-cdts/tests/unfold/unfold-map-2vars-02.srj new file mode 100644 index 00000000..31971149 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/unfold/unfold-map-2vars-02.srj @@ -0,0 +1,16 @@ +{ "head": { + "vars": [ "k", "v" ] + } , + "results": { + "bindings": [ + { + "k": { "type": "literal" , "datatype": "http://www.w3.org/2001/XMLSchema#integer" , "value": "1" }, + "v": { "type": "literal" , "datatype": "http://www.w3.org/2001/XMLSchema#integer" , "value": "3" } + }, + { + "k": { "type": "literal" , "datatype": "http://www.w3.org/2001/XMLSchema#integer" , "value": "2" }, + "v": { "type": "literal" , "datatype": "http://www.w3.org/2001/XMLSchema#integer" , "value": "3" } + } + ] + } +} diff --git a/src/test/resources/sparql-cdts/tests/unfold/unfold-map-2vars-03.rq b/src/test/resources/sparql-cdts/tests/unfold/unfold-map-2vars-03.rq new file mode 100644 index 00000000..b110c129 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/unfold/unfold-map-2vars-03.rq @@ -0,0 +1,6 @@ +PREFIX cdt: + +SELECT ?k ?v WHERE { + BIND( "{1:false, true:3}"^^cdt:Map AS ?map ) + UNFOLD( ?map AS ?k, ?v ) +} diff --git a/src/test/resources/sparql-cdts/tests/unfold/unfold-map-2vars-03.srj b/src/test/resources/sparql-cdts/tests/unfold/unfold-map-2vars-03.srj new file mode 100644 index 00000000..4e3d16ee --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/unfold/unfold-map-2vars-03.srj @@ -0,0 +1,16 @@ +{ "head": { + "vars": [ "k", "v" ] + } , + "results": { + "bindings": [ + { + "k": { "type": "literal" , "datatype": "http://www.w3.org/2001/XMLSchema#integer" , "value": "1" }, + "v": { "type": "literal" , "datatype": "http://www.w3.org/2001/XMLSchema#boolean" , "value": "false" } + }, + { + "k": { "type": "literal" , "datatype": "http://www.w3.org/2001/XMLSchema#boolean" , "value": "true" }, + "v": { "type": "literal" , "datatype": "http://www.w3.org/2001/XMLSchema#integer" , "value": "3" } + } + ] + } +} diff --git a/src/test/resources/sparql-cdts/tests/unfold/unfold-map-2vars-04.rq b/src/test/resources/sparql-cdts/tests/unfold/unfold-map-2vars-04.rq new file mode 100644 index 00000000..8758a55f --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/unfold/unfold-map-2vars-04.rq @@ -0,0 +1,6 @@ +PREFIX cdt: + +SELECT ?k ?v WHERE { + BIND( "{:3, :4}"^^cdt:Map AS ?map ) + UNFOLD( ?map AS ?k, ?v ) +} diff --git a/src/test/resources/sparql-cdts/tests/unfold/unfold-map-2vars-04.srj b/src/test/resources/sparql-cdts/tests/unfold/unfold-map-2vars-04.srj new file mode 100644 index 00000000..6c160ec8 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/unfold/unfold-map-2vars-04.srj @@ -0,0 +1,16 @@ +{ "head": { + "vars": [ "k", "v" ] + } , + "results": { + "bindings": [ + { + "k": { "type": "uri" , "value": "http://example/1" }, + "v": { "type": "literal" , "datatype": "http://www.w3.org/2001/XMLSchema#integer" , "value": "3" } + }, + { + "k": { "type": "uri" , "value": "http://example/2" }, + "v": { "type": "literal" , "datatype": "http://www.w3.org/2001/XMLSchema#integer" , "value": "4" } + } + ] + } +} diff --git a/src/test/resources/sparql-cdts/tests/unfold/unfold-map-2vars-05.rq b/src/test/resources/sparql-cdts/tests/unfold/unfold-map-2vars-05.rq new file mode 100644 index 00000000..76eccfbf --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/unfold/unfold-map-2vars-05.rq @@ -0,0 +1,6 @@ +PREFIX cdt: + +SELECT ?k ?v WHERE { + BIND( "{1:, 2:}"^^cdt:Map AS ?map ) + UNFOLD( ?map AS ?k, ?v ) +} diff --git a/src/test/resources/sparql-cdts/tests/unfold/unfold-map-2vars-05.srj b/src/test/resources/sparql-cdts/tests/unfold/unfold-map-2vars-05.srj new file mode 100644 index 00000000..5ae65bb3 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/unfold/unfold-map-2vars-05.srj @@ -0,0 +1,16 @@ +{ "head": { + "vars": [ "k", "v" ] + } , + "results": { + "bindings": [ + { + "k": { "type": "literal" , "datatype": "http://www.w3.org/2001/XMLSchema#integer" , "value": "1" }, + "v": { "type": "uri" , "value": "http://example/1" } + }, + { + "k": { "type": "literal" , "datatype": "http://www.w3.org/2001/XMLSchema#integer" , "value": "2" }, + "v": { "type": "uri" , "value": "http://example/2" } + } + ] + } +} diff --git a/src/test/resources/sparql-cdts/tests/unfold/unfold-map-2vars-06.rq b/src/test/resources/sparql-cdts/tests/unfold/unfold-map-2vars-06.rq new file mode 100644 index 00000000..dcf0c864 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/unfold/unfold-map-2vars-06.rq @@ -0,0 +1,6 @@ +PREFIX cdt: + +SELECT ?k ?v WHERE { + BIND( "{1: _:x, 2: _:y}"^^cdt:Map AS ?map ) + UNFOLD( ?map AS ?k, ?v ) +} diff --git a/src/test/resources/sparql-cdts/tests/unfold/unfold-map-2vars-06.srj b/src/test/resources/sparql-cdts/tests/unfold/unfold-map-2vars-06.srj new file mode 100644 index 00000000..7adf07e3 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/unfold/unfold-map-2vars-06.srj @@ -0,0 +1,16 @@ +{ "head": { + "vars": [ "k", "v" ] + } , + "results": { + "bindings": [ + { + "k": { "type": "literal" , "datatype": "http://www.w3.org/2001/XMLSchema#integer" , "value": "1" }, + "v": { "type": "bnode" , "value": "b0" } + }, + { + "k": { "type": "literal" , "datatype": "http://www.w3.org/2001/XMLSchema#integer" , "value": "2" }, + "v": { "type": "bnode" , "value": "b1" } + } + ] + } +} diff --git a/src/test/resources/sparql-cdts/tests/unfold/unfold-map-2vars-07.rq b/src/test/resources/sparql-cdts/tests/unfold/unfold-map-2vars-07.rq new file mode 100644 index 00000000..42c4c0d6 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/unfold/unfold-map-2vars-07.rq @@ -0,0 +1,6 @@ +PREFIX cdt: + +SELECT ?k ?v WHERE { + BIND( "{1: _:x, 2: _:x}"^^cdt:Map AS ?map ) + UNFOLD( ?map AS ?k, ?v ) +} diff --git a/src/test/resources/sparql-cdts/tests/unfold/unfold-map-2vars-07.srj b/src/test/resources/sparql-cdts/tests/unfold/unfold-map-2vars-07.srj new file mode 100644 index 00000000..74c4b0e3 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/unfold/unfold-map-2vars-07.srj @@ -0,0 +1,16 @@ +{ "head": { + "vars": [ "k", "v" ] + } , + "results": { + "bindings": [ + { + "k": { "type": "literal" , "datatype": "http://www.w3.org/2001/XMLSchema#integer" , "value": "1" }, + "v": { "type": "bnode" , "value": "b0" } + }, + { + "k": { "type": "literal" , "datatype": "http://www.w3.org/2001/XMLSchema#integer" , "value": "2" }, + "v": { "type": "bnode" , "value": "b0" } + } + ] + } +} diff --git a/src/test/resources/sparql-cdts/tests/unfold/unfold-map-2vars-08.rq b/src/test/resources/sparql-cdts/tests/unfold/unfold-map-2vars-08.rq new file mode 100644 index 00000000..c1a3172d --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/unfold/unfold-map-2vars-08.rq @@ -0,0 +1,6 @@ +PREFIX cdt: + +SELECT ?k ?v WHERE { + BIND( "{1:null, 2:4}"^^cdt:Map AS ?map ) + UNFOLD( ?map AS ?k, ?v ) +} diff --git a/src/test/resources/sparql-cdts/tests/unfold/unfold-map-2vars-08.srj b/src/test/resources/sparql-cdts/tests/unfold/unfold-map-2vars-08.srj new file mode 100644 index 00000000..e27adcb8 --- /dev/null +++ b/src/test/resources/sparql-cdts/tests/unfold/unfold-map-2vars-08.srj @@ -0,0 +1,15 @@ +{ "head": { + "vars": [ "k", "v" ] + } , + "results": { + "bindings": [ + { + "k": { "type": "literal" , "datatype": "http://www.w3.org/2001/XMLSchema#integer" , "value": "1" } + }, + { + "k": { "type": "literal" , "datatype": "http://www.w3.org/2001/XMLSchema#integer" , "value": "2" }, + "v": { "type": "literal" , "datatype": "http://www.w3.org/2001/XMLSchema#integer" , "value": "4" } + } + ] + } +} From 0b6ee9619f341dd7c0bbe853d44e9e238b86228d Mon Sep 17 00:00:00 2001 From: Erich Bremer Date: Thu, 16 Jul 2026 20:52:39 -0400 Subject: [PATCH 5/5] RDF 1.2-basic conformant (format v4) --- RDF_1.1-compliance.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/RDF_1.1-compliance.md b/RDF_1.1-compliance.md index 3c91f807..778459e3 100644 --- a/RDF_1.1-compliance.md +++ b/RDF_1.1-compliance.md @@ -58,7 +58,8 @@ regardless. Policy: anything the format cannot represent fails the build loudly. > defines basic conformance as supporting graphs/datasets whose triples contain only basic RDF > terms — i.e. everything except triple terms. BeakGraph stores base-direction literals > term-exactly, inherits RDF 1.2's case-insensitive language-tag identity from Jena, and rejects -> triple terms loudly (full conformance is planned; PLAN.md Phase 3). +> triple terms loudly. Full conformance is a designed-but-deferred future phase (PLAN.md Phase 3, +> decided 2026-07-16: stand on basic). > > **Evidence:** the vendored W3C RDF 1.2 test suites (rdf-turtle, rdf-n-triples, rdf-n-quads, > rdf-trig; `W3CRdf12SuiteTest`, suites at commit `d3e844a`): **301 tests — 213 executed, 0