Skip to content

Commit d741814

Browse files
committed
Revert to old IRIs
This revents to the IRIs from master branch as the tests only pass when using them. Also assert that there is more than 1 test found to prevent silent failures.
1 parent e6a1bbb commit d741814

File tree

1 file changed

+6
-4
lines changed

1 file changed

+6
-4
lines changed

test/test_parsers/test_rdfxml_w3c.py

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ def add(self, spo):
4545
super(TestStore, self).add((s, p, o))
4646

4747

48-
TEST = Namespace("http://www.w3.org/2013/RDFXMLTests/testSchema#")
48+
TEST = Namespace("http://www.w3.org/2000/10/rdf-tests/rdfcore/testSchema#")
4949

5050
CACHE_DIR = os.path.join(TEST_DATA_DIR, "suites", "w3c", "rdfxml")
5151

@@ -77,7 +77,7 @@ def cached_file(url):
7777
return fpath
7878

7979

80-
RDFCOREBASE = "http://www.w3.org/2013/RDFXMLTests/"
80+
RDFCOREBASE = "http://www.w3.org/2000/10/rdf-tests/rdfcore/"
8181

8282

8383
def relative(url):
@@ -178,7 +178,7 @@ def setUp(self):
178178
self.manifest = manifest = Graph(store=self.store)
179179
manifest.open(self.path)
180180
manifest.parse(
181-
cached_file("http://www.w3.org/2013/RDFXMLTests/Manifest.rdf"),
181+
cached_file("http://www.w3.org/2000/10/rdf-tests/rdfcore/Manifest.rdf"),
182182
format="xml",
183183
)
184184

@@ -189,6 +189,7 @@ def testNegative(self):
189189
manifest = self.manifest
190190
num_failed = total = 0
191191
negs = list(manifest.subjects(RDF.type, TEST["NegativeParserTest"]))
192+
self.assertGreater(len(negs), 1)
192193
negs.sort()
193194
for neg in negs:
194195
status = first(manifest.objects(neg, TEST["status"]))
@@ -201,6 +202,7 @@ def testNegative(self):
201202
def testPositive(self):
202203
manifest = self.manifest
203204
uris = list(manifest.subjects(RDF.type, TEST["PositiveParserTest"]))
205+
self.assertGreater(len(uris), 1)
204206
uris.sort()
205207
num_failed = total = 0
206208
for uri in uris:
@@ -238,7 +240,7 @@ def testPositive(self):
238240
if __name__ == "__main__":
239241
manifest = Graph()
240242
manifest.parse(
241-
cached_file("http://www.w3.org/2013/RDFXMLTests//Manifest.rdf"),
243+
cached_file("http://www.w3.org/2000/10/rdf-tests/rdfcore/Manifest.rdf"),
242244
format="xml",
243245
)
244246
import getopt

0 commit comments

Comments
 (0)