Skip to content

Commit

Permalink
switch to xone where appropriate (#162)
Browse files Browse the repository at this point in the history
* switch to `xone` where appropriate

* build(deps): bump express from 4.18.2 to 4.19.2

Bumps [express](https://github.com/expressjs/express) from 4.18.2 to 4.19.2.
- [Release notes](https://github.com/expressjs/express/releases)
- [Changelog](https://github.com/expressjs/express/blob/master/History.md)
- [Commits](expressjs/express@4.18.2...4.19.2)

---
updated-dependencies:
- dependency-name: express
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <[email protected]>

* build(deps-dev): bump undici from 5.28.3 to 5.28.4

Bumps [undici](https://github.com/nodejs/undici) from 5.28.3 to 5.28.4.
- [Release notes](https://github.com/nodejs/undici/releases)
- [Commits](nodejs/undici@v5.28.3...v5.28.4)

---
updated-dependencies:
- dependency-name: undici
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <[email protected]>

* build(deps): bump tar from 6.2.0 to 6.2.1

Bumps [tar](https://github.com/isaacs/node-tar) from 6.2.0 to 6.2.1.
- [Release notes](https://github.com/isaacs/node-tar/releases)
- [Changelog](https://github.com/isaacs/node-tar/blob/main/CHANGELOG.md)
- [Commits](isaacs/node-tar@v6.2.0...v6.2.1)

---
updated-dependencies:
- dependency-name: tar
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <[email protected]>

* Create sour-cooks-cheer.md

* test: update approved results

* perf: alternative shape for lists (#158)

* perf: alternative shape for lists

* Create friendly-pumas-melt.md

* test malformed lists

* list validation: use xone

* refactor: remove warning about valid `qudt:hasUnit`

* adjust approval tests

* fix typo

---------

Co-authored-by: Tomasz Pluskiewicz <[email protected]>

---------

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Tomasz Pluskiewicz <[email protected]>
Co-authored-by: Giacomo Citi <[email protected]>
  • Loading branch information
4 people authored Apr 12, 2024
1 parent 3f40fd5 commit 9faf4fb
Show file tree
Hide file tree
Showing 7 changed files with 27 additions and 22 deletions.
5 changes: 5 additions & 0 deletions .changeset/sour-cooks-cheer.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"cube-link": patch
---

Validation profiles: switch to `sh:xone` where appropriate
28 changes: 14 additions & 14 deletions test/profile-visualize/invalid-temporal.ttl.approved.txt
Original file line number Diff line number Diff line change
Expand Up @@ -25,35 +25,35 @@ _:report a sh:ValidationReport ;
sh:resultMessage "Predicate is not allowed (closed shape)" ;
], [
rdf:type sh:ValidationResult ;
sh:resultSeverity sh:Violation ;
sh:sourceConstraintComponent sh:OrConstraintComponent ;
sh:sourceShape <https://cube.link/shape/profile-opendataswiss-lindas#TemporalDimensionConstraint> ;
sh:resultSeverity sh:Warning ;
sh:sourceConstraintComponent sh:XoneConstraintComponent ;
sh:sourceShape <https://cube.link/shape/shared/data-kind#DataKind> ;
sh:focusNode _:b3 ;
sh:value _:b3 ;
sh:resultMessage "Temporal dimension must be one of XSD datatypes: gYear, gYearMonth, date, dateTime, or have time:unitType" ;
sh:resultMessage "Data kind should be one of the following: GeneralDateTimeDescription, GeoShape, GeoCoordinates" ;
], [
rdf:type sh:ValidationResult ;
sh:resultSeverity sh:Violation ;
sh:sourceConstraintComponent sh:OrConstraintComponent ;
sh:sourceShape <https://cube.link/shape/profile-opendataswiss-lindas#TemporalDimensionConstraint> ;
sh:resultSeverity sh:Warning ;
sh:sourceConstraintComponent sh:XoneConstraintComponent ;
sh:sourceShape <https://cube.link/shape/shared/data-kind#DataKind> ;
sh:focusNode _:b5 ;
sh:value _:b5 ;
sh:resultMessage "Temporal dimension must be one of XSD datatypes: gYear, gYearMonth, date, dateTime, or have time:unitType" ;
sh:resultMessage "Data kind should be one of the following: GeneralDateTimeDescription, GeoShape, GeoCoordinates" ;
], [
rdf:type sh:ValidationResult ;
sh:resultSeverity sh:Warning ;
sh:resultSeverity sh:Violation ;
sh:sourceConstraintComponent sh:XoneConstraintComponent ;
sh:sourceShape <https://cube.link/shape/shared/data-kind#DataKind> ;
sh:sourceShape <https://cube.link/shape/profile-opendataswiss-lindas#TemporalDimensionConstraint> ;
sh:focusNode _:b3 ;
sh:value _:b3 ;
sh:resultMessage "Data kind should be one of the following: GeneralDateTimeDescription, GeoShape, GeoCoordinates" ;
sh:resultMessage "Temporal dimension must be one of XSD datatypes: gYear, gYearMonth, date, dateTime, or have time:unitType" ;
], [
rdf:type sh:ValidationResult ;
sh:resultSeverity sh:Warning ;
sh:resultSeverity sh:Violation ;
sh:sourceConstraintComponent sh:XoneConstraintComponent ;
sh:sourceShape <https://cube.link/shape/shared/data-kind#DataKind> ;
sh:sourceShape <https://cube.link/shape/profile-opendataswiss-lindas#TemporalDimensionConstraint> ;
sh:focusNode _:b5 ;
sh:value _:b5 ;
sh:resultMessage "Data kind should be one of the following: GeneralDateTimeDescription, GeoShape, GeoCoordinates" ;
sh:resultMessage "Temporal dimension must be one of XSD datatypes: gYear, gYearMonth, date, dateTime, or have time:unitType" ;
] ;
sh:conforms false .
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,11 @@ _:report a sh:ValidationReport ;
sh:result [
rdf:type sh:ValidationResult ;
sh:resultSeverity sh:Violation ;
sh:sourceConstraintComponent sh:OrConstraintComponent ;
sh:sourceConstraintComponent sh:XoneConstraintComponent ;
sh:sourceShape [
sh:path schema:contactPoint ;
sh:minCount 1 ;
sh:or (
sh:xone (
[
sh:nodeKind sh:IRI ;
]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,11 @@ _:report a sh:ValidationReport ;
sh:result [
rdf:type sh:ValidationResult ;
sh:resultSeverity sh:Violation ;
sh:sourceConstraintComponent sh:OrConstraintComponent ;
sh:sourceConstraintComponent sh:XoneConstraintComponent ;
sh:sourceShape [
sh:path schema:contactPoint ;
sh:minCount 1 ;
sh:or (
sh:xone (
[
sh:nodeKind sh:IRI ;
]
Expand Down
2 changes: 1 addition & 1 deletion validation/profile-visualize.ttl
Original file line number Diff line number Diff line change
Expand Up @@ -182,7 +182,7 @@ prefix : <https://cube.link/shape/profile-opendataswiss-lindas#>
sh:targetClass time:GeneralDateTimeDescription ;
sh:message
"Temporal dimension must be one of XSD datatypes: gYear, gYearMonth, date, dateTime, or have time:unitType" ;
sh:or
sh:xone
(
[
sh:property
Expand Down
4 changes: 2 additions & 2 deletions validation/standalone-constraint-constraint.ttl
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@
:PropertyNameType a sh:NodeShape ;
sh:property [
sh:path schema:name;
sh:or ( [ sh:datatype xsd:string ] [ sh:datatype rdf:langString ] ) ;
sh:xone ( [ sh:datatype xsd:string ] [ sh:datatype rdf:langString ] ) ;
];
.

Expand Down Expand Up @@ -241,7 +241,7 @@
sh:severity sh:Info;
sh:message "nextInHierarchy can have nested nodes"
] ;
sh:or (
sh:xone (
[
sh:path sh:path;
sh:nodeKind sh:IRI;
Expand Down
2 changes: 1 addition & 1 deletion validation/standalone-cube-constraint.ttl
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@
[
sh:path schema:contactPoint ;
sh:minCount 1 ;
sh:or
sh:xone
(
[ sh:nodeKind sh:IRI ]
[
Expand Down

0 comments on commit 9faf4fb

Please sign in to comment.