diff --git a/tests/expand-manifest.jsonld b/tests/expand-manifest.jsonld index c18f12bb..f09a7147 100644 --- a/tests/expand-manifest.jsonld +++ b/tests/expand-manifest.jsonld @@ -1819,6 +1819,13 @@ "purpose": "The value of @type in an expanded term definition object MUST be a string or null.", "input": "expand/er55-in.jsonld", "expectErrorCode": "invalid type mapping" + }, { + "@id": "#ter56", + "@type": [ "jld:NegativeEvaluationTest", "jld:ExpandTest" ], + "name": "Invalid redefinition of @context keyword.", + "purpose": "Verifies that an exception is raised when attempting to redefine @context.", + "input": "expand/er56-in.jsonld", + "expectErrorCode": "keyword redefinition" }, { "@id": "#tes01", "@type": ["jld:NegativeEvaluationTest", "jld:ExpandTest"], diff --git a/tests/expand/er56-in.jsonld b/tests/expand/er56-in.jsonld new file mode 100644 index 00000000..157ec456 --- /dev/null +++ b/tests/expand/er56-in.jsonld @@ -0,0 +1,10 @@ +{ + "@context": { + "@context": { + "p": "ex:p" + } + }, + "@id": "ex:1", + "p": "value" +} + diff --git a/tests/toRdf-manifest.jsonld b/tests/toRdf-manifest.jsonld index b5448d5f..0fcc3354 100644 --- a/tests/toRdf-manifest.jsonld +++ b/tests/toRdf-manifest.jsonld @@ -2231,19 +2231,26 @@ "expectErrorCode": "invalid @prefix value", "option": {"specVersion": "json-ld-1.1"} }, { - "@id": "#ter54", - "@type": [ "jld:NegativeEvaluationTest", "jld:ToRDFTest" ], - "name": "Invalid value object, multiple values for @type.", - "purpose": "The value of @type in a value object MUST be a string or null.", - "input": "toRdf/er54-in.jsonld", - "expectErrorCode": "invalid typed value" - }, { - "@id": "#ter55", - "@type": [ "jld:NegativeEvaluationTest", "jld:ToRDFTest" ], - "name": "Invalid term definition, multiple values for @type.", - "purpose": "The value of @type in an expanded term definition object MUST be a string or null.", - "input": "toRdf/er55-in.jsonld", - "expectErrorCode": "invalid type mapping" + "@id": "#ter54", + "@type": [ "jld:NegativeEvaluationTest", "jld:ToRDFTest" ], + "name": "Invalid value object, multiple values for @type.", + "purpose": "The value of @type in a value object MUST be a string or null.", + "input": "toRdf/er54-in.jsonld", + "expectErrorCode": "invalid typed value" + }, { + "@id": "#ter55", + "@type": [ "jld:NegativeEvaluationTest", "jld:ToRDFTest" ], + "name": "Invalid term definition, multiple values for @type.", + "purpose": "The value of @type in an expanded term definition object MUST be a string or null.", + "input": "toRdf/er55-in.jsonld", + "expectErrorCode": "invalid type mapping" + }, { + "@id": "#ter56", + "@type": [ "jld:NegativeEvaluationTest", "jld:ToRDFTest" ], + "name": "Invalid redefinition of @context keyword.", + "purpose": "Verifies that an exception is raised when attempting to redefine @context.", + "input": "expand/er56-in.jsonld", + "expectErrorCode": "keyword redefinition" }, { "@id": "#tin01", "@type": ["jld:PositiveEvaluationTest", "jld:ToRDFTest"], diff --git a/tests/toRdf/er56-in.jsonld b/tests/toRdf/er56-in.jsonld new file mode 100644 index 00000000..157ec456 --- /dev/null +++ b/tests/toRdf/er56-in.jsonld @@ -0,0 +1,10 @@ +{ + "@context": { + "@context": { + "p": "ex:p" + } + }, + "@id": "ex:1", + "p": "value" +} +