Skip to content

Commit 1c454ac

Browse files
committed
Tests for VERSION/@Version in Turtle
1 parent 22ba727 commit 1c454ac

15 files changed

+150
-0
lines changed

rdf/rdf12/rdf-turtle/syntax/manifest.ttl

Lines changed: 91 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -87,6 +87,24 @@ trs:manifest rdf:type mf:Manifest ;
8787

8888
trs:nt-ttl-base-bad-1
8989
trs:nt-ttl-base-bad-2
90+
91+
## Version
92+
93+
trs:turtle-version-01
94+
trs:turtle-version-02
95+
trs:turtle-version-03
96+
trs:turtle-version-04
97+
trs:turtle-version-05
98+
trs:turtle-version-06
99+
trs:turtle-version-07
100+
trs:turtle-version-08
101+
102+
trs:turtle-version-bad-01
103+
trs:turtle-version-bad-02
104+
trs:turtle-version-bad-03
105+
trs:turtle-version-bad-04
106+
trs:turtle-version-bad-05
107+
trs:turtle-version-bad-06
90108
) .
91109

92110
## Good Syntax
@@ -351,3 +369,76 @@ trs:nt-ttl-base-bad-2 rdf:type rdft:TestTurtleNegativeSyntax ;
351369
mf:name "N-Triples-star as Turtle-star - upper case LTR" ;
352370
mf:action <nt-ttl-base-bad-2.ttl> ;
353371
.
372+
373+
## Version
374+
375+
trs:turtle-version-01 rdf:type rdft:TestTurtlePositiveSyntax ;
376+
mf:name "Turtle 1.2 - VERSION" ;
377+
mf:action <turtle-version-01.ttl> ;
378+
.
379+
380+
trs:turtle-version-02 rdf:type rdft:TestTurtlePositiveSyntax ;
381+
mf:name "Turtle 1.2 - @version" ;
382+
mf:action <turtle-version-02.ttl> ;
383+
.
384+
385+
trs:turtle-version-03 rdf:type rdft:TestTurtlePositiveSyntax ;
386+
mf:name "Turtle 1.2 - VERSION in data " ;
387+
mf:action <turtle-version-03.ttl> ;
388+
.
389+
390+
trs:turtle-version-04 rdf:type rdft:TestTurtlePositiveSyntax ;
391+
mf:name "Turtle 1.2 - @version in data" ;
392+
mf:action <turtle-version-04.ttl> ;
393+
.
394+
395+
trs:turtle-version-05 rdf:type rdft:TestTurtlePositiveSyntax ;
396+
mf:name "Turtle 1.2 - VERSION other version string" ;
397+
mf:action <turtle-version-05.ttl> ;
398+
.
399+
400+
trs:turtle-version-06 rdf:type rdft:TestTurtlePositiveSyntax ;
401+
mf:name "Turtle 1.2 - @version other version string" ;
402+
mf:action <turtle-version-06.ttl> ;
403+
.
404+
405+
trs:turtle-version-07 rdf:type rdft:TestTurtlePositiveSyntax ;
406+
mf:name "Turtle 1.2 - mixed versions" ;
407+
mf:action <turtle-version-07.ttl> ;
408+
.
409+
410+
trs:turtle-version-08 rdf:type rdft:TestTurtlePositiveSyntax ;
411+
mf:name "Turtle 1.2 - many versions" ;
412+
mf:action <turtle-version-08.ttl> ;
413+
.
414+
415+
trs:turtle-version-bad-01 rdf:type rdft:TestTurtleNegativeSyntax ;
416+
mf:name "Turtle 1.2 - VERSION - not string" ;
417+
mf:action <turtle-version-bad-01.ttl> ;
418+
.
419+
420+
trs:turtle-version-bad-02 rdf:type rdft:TestTurtleNegativeSyntax ;
421+
mf:name "Turtle 1.2 - VERSION - triple-'-quoted string" ;
422+
mf:action <turtle-version-bad-02.ttl> ;
423+
.
424+
425+
trs:turtle-version-bad-03 rdf:type rdft:TestTurtleNegativeSyntax ;
426+
mf:name "Turtle 1.2 - VERSION - triple-\"-quoted string" ;
427+
mf:action <turtle-version-bad-03.ttl> ;
428+
.
429+
430+
trs:turtle-version-bad-04 rdf:type rdft:TestTurtleNegativeSyntax ;
431+
mf:name "Turtle 1.2 - @version - not string" ;
432+
mf:action <turtle-version-bad-04.ttl> ;
433+
.
434+
435+
trs:turtle-version-bad-05 rdf:type rdft:TestTurtleNegativeSyntax ;
436+
mf:name "Turtle 1.2 - @version - triple-'-quoted string" ;
437+
mf:action <turtle-version-bad-05.ttl> ;
438+
.
439+
440+
trs:turtle-version-bad-06 rdf:type rdft:TestTurtleNegativeSyntax ;
441+
mf:name "Turtle 1.2 - @version - triple-\"-quoted string" ;
442+
mf:action <turtle-version-bad-06.ttl> ;
443+
.
444+
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
VERSION "1.2"
2+
PREFIX : <http://example/>
3+
4+
:s :p :o .
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
@version "1.2" .
2+
@prefix : <http://example/> .
3+
4+
:s :p :o .
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
PREFIX : <http://example/>
2+
:s :p :o .
3+
4+
VERSION "1.2"
5+
6+
:a :b :c .
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
PREFIX : <http://example/>
2+
3+
:s :p :o .
4+
5+
@version "1.2" .
6+
7+
:a :b :c .
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
PREFIX : <http://example/>
2+
VERSION "1.2-basic"
3+
4+
:s :p :o .
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
PREFIX : <http://example/>
2+
@version '1.2-basic' .
3+
4+
:s :p :o .
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
@version '1.2-basic' .
2+
PREFIX : <http://example/>
3+
VERSION "1.2"
4+
5+
:s :p :o .
Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
PREFIX : <http://example/>
2+
3+
VERSION "1.2"
4+
version "1.2"
5+
@version "1.2" .
6+
7+
:s :p 1 .
8+
9+
VERSION '1.2'
10+
version '1.2'
11+
@version '1.2' .
12+
13+
:s :p 2 .
14+
15+
VERSION "abc"
16+
version "abc"
17+
@version "abc" .
18+
19+
:s :p 3 .
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
VERSION 1.2

0 commit comments

Comments
 (0)