aboutsummaryrefslogtreecommitdiffstats
path: root/test/pretty/graph-abbreviation.trig
diff options
context:
space:
mode:
authorDavid Robillard <d@drobilla.net>2023-03-27 15:42:27 -0400
committerDavid Robillard <d@drobilla.net>2023-04-05 09:41:43 -0400
commite970e63146fb5d8de511104eba7aef5319e8653b (patch)
tree9f8e24335b84012ec0473e62301f37491c31cdb9 /test/pretty/graph-abbreviation.trig
parent68c1a2e677775e489cff4beb38ef17c1efeae4e3 (diff)
downloadserd-e970e63146fb5d8de511104eba7aef5319e8653b.tar.gz
serd-e970e63146fb5d8de511104eba7aef5319e8653b.tar.bz2
serd-e970e63146fb5d8de511104eba7aef5319e8653b.zip
Add pretty-printing test suite
The earlier "test" was just hitting the code without actually checking the output. This new suite is a set of pretty-printed documents which serd must reproduce exactly to pass. This should make it easy to add cases in the future, since each case is just a document, as it should look.
Diffstat (limited to 'test/pretty/graph-abbreviation.trig')
-rw-r--r--test/pretty/graph-abbreviation.trig65
1 files changed, 65 insertions, 0 deletions
diff --git a/test/pretty/graph-abbreviation.trig b/test/pretty/graph-abbreviation.trig
new file mode 100644
index 00000000..8ec75f6e
--- /dev/null
+++ b/test/pretty/graph-abbreviation.trig
@@ -0,0 +1,65 @@
+@prefix : <http://example.org/> .
+@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .
+
+:graph {
+ :a
+ :b :c ,
+ :d ,
+ :e ;
+ :f :g ,
+ :h ;
+ :i :j ;
+ :k :l .
+
+ :s
+ a :Thing ;
+ :p1 :o1 ,
+ [
+ a :SubThing ;
+ :p2 :o2
+ ] , [
+ a :OtherSubThing ;
+ :p3 :o3
+ ] ;
+ :p4 :o4 .
+
+ []
+ :isA :Blank .
+
+ []
+ :sameAs [] .
+
+ []
+ :blank [
+ :nestedEmptyBlank [] ;
+ :nestedNonEmptyBlanks [
+ rdf:value 1
+ ] , [
+ rdf:value 2
+ ]
+ ] ;
+ :lists (
+ 3
+ 4
+ ) .
+
+ []
+ :lists (
+ 5
+ 6
+ ) .
+
+ []
+ :lists (
+ [
+ rdf:value 7
+ ] [
+ rdf:value 8
+ ]
+ ) .
+}
+
+:separateGraph {
+ :m
+ a :OtherThing .
+}