aboutsummaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authorDavid Robillard <d@drobilla.net>2019-10-27 19:48:02 +0100
committerDavid Robillard <d@drobilla.net>2019-10-27 22:41:27 +0100
commitf7ffff1e75634909da60ea63a7c52f1a001220b8 (patch)
treed14587114d96a0be8408709c1f315412440d078d /tests
parentcd6d4569c1c8819cc8e54eefdc0ac389d8efb4ea (diff)
downloadserd-f7ffff1e75634909da60ea63a7c52f1a001220b8.tar.gz
serd-f7ffff1e75634909da60ea63a7c52f1a001220b8.tar.bz2
serd-f7ffff1e75634909da60ea63a7c52f1a001220b8.zip
Fix EOF handling while reading in bulk or from strings
Diffstat (limited to 'tests')
-rw-r--r--tests/bad/bad-eof-after-quotes.ttl3
-rw-r--r--tests/bad/bad-eof-at-string-start.ttl3
-rw-r--r--tests/bad/bad-eof-in-long-string.ttl3
-rw-r--r--tests/bad/bad-eof-in-uri-scheme.nt1
-rw-r--r--tests/bad/manifest.ttl24
5 files changed, 34 insertions, 0 deletions
diff --git a/tests/bad/bad-eof-after-quotes.ttl b/tests/bad/bad-eof-after-quotes.ttl
new file mode 100644
index 00000000..40e429cb
--- /dev/null
+++ b/tests/bad/bad-eof-after-quotes.ttl
@@ -0,0 +1,3 @@
+@prefix eg: <http://example.org/> .
+
+<> eg:comment "" \ No newline at end of file
diff --git a/tests/bad/bad-eof-at-string-start.ttl b/tests/bad/bad-eof-at-string-start.ttl
new file mode 100644
index 00000000..93d20bcc
--- /dev/null
+++ b/tests/bad/bad-eof-at-string-start.ttl
@@ -0,0 +1,3 @@
+@prefix eg: <http://example.org/> .
+
+<> eg:comment " \ No newline at end of file
diff --git a/tests/bad/bad-eof-in-long-string.ttl b/tests/bad/bad-eof-in-long-string.ttl
new file mode 100644
index 00000000..2ef179a8
--- /dev/null
+++ b/tests/bad/bad-eof-in-long-string.ttl
@@ -0,0 +1,3 @@
+@prefix eg: <http://example.org/> .
+
+<> eg:comment """This is the string that never ends \ No newline at end of file
diff --git a/tests/bad/bad-eof-in-uri-scheme.nt b/tests/bad/bad-eof-in-uri-scheme.nt
new file mode 100644
index 00000000..de892dcf
--- /dev/null
+++ b/tests/bad/bad-eof-in-uri-scheme.nt
@@ -0,0 +1 @@
+<http://example.org/s> <http://example.org/p> <ht \ No newline at end of file
diff --git a/tests/bad/manifest.ttl b/tests/bad/manifest.ttl
index bd51ba48..4d543dd4 100644
--- a/tests/bad/manifest.ttl
+++ b/tests/bad/manifest.ttl
@@ -30,6 +30,8 @@
<#bad-char-in-uri>
<#bad-datatype>
<#bad-dot-after-subject>
+ <#bad-eof-after-quotes>
+ <#bad-eof-at-string-start>
<#bad-eof-in-blank>
<#bad-eof-in-escape>
<#bad-eof-in-lang-suffix>
@@ -38,9 +40,11 @@
<#bad-eof-in-object-list2>
<#bad-eof-in-object-list>
<#bad-eof-in-predicate-list>
+ <#bad-eof-in-long-string>
<#bad-eof-in-string>
<#bad-eof-in-triple-quote>
<#bad-eof-in-uri>
+ <#bad-eof-in-uri-scheme>
<#bad-escape>
<#bad-ext-namedblank-op>
<#bad-hex-digit>
@@ -186,6 +190,16 @@
mf:name "bad-dot-after-subject" ;
mf:action <bad-dot-after-subject.ttl> .
+<#bad-eof-after-quotes>
+ rdf:type rdft:TestTurtleNegativeSyntax ;
+ mf:name "bad-eof-after-quotes" ;
+ mf:action <bad-eof-after-quotes.ttl> .
+
+<#bad-eof-at-string-start>
+ rdf:type rdft:TestTurtleNegativeSyntax ;
+ mf:name "bad-eof-at-string-start" ;
+ mf:action <bad-eof-at-string-start.ttl> .
+
<#bad-eof-in-blank>
rdf:type rdft:TestTurtleNegativeSyntax ;
mf:name "bad-eof-in-blank" ;
@@ -226,6 +240,11 @@
mf:name "bad-eof-in-predicate-list" ;
mf:action <bad-eof-in-predicate-list.ttl> .
+<#bad-eof-in-long-string>
+ rdf:type rdft:TestTurtleNegativeSyntax ;
+ mf:name "bad-eof-in-long-string" ;
+ mf:action <bad-eof-in-long-string.ttl> .
+
<#bad-eof-in-string>
rdf:type rdft:TestTurtleNegativeSyntax ;
mf:name "bad-eof-in-string" ;
@@ -241,6 +260,11 @@
mf:name "bad-eof-in-uri" ;
mf:action <bad-eof-in-uri.ttl> .
+<#bad-eof-in-uri-scheme>
+ rdf:type rdft:TestNTriplesNegativeSyntax ;
+ mf:name "bad-eof-in-uri-scheme" ;
+ mf:action <bad-eof-in-uri-scheme.nt> .
+
<#bad-escape>
rdf:type rdft:TestTurtleNegativeSyntax ;
mf:name "bad-escape" ;