Open yashkhatri opened 7 years ago
@labra @darkLabra
I have tested it and it works. It signals the error on ex:InvalidInstance.
If you remove the ex:InvalidInstance, it says that ex:ValidInstance conforms.
One problem, though, is that it stops as soon as there is an error and that's why it just says that there is an error in ex:InvalidInstance.
This behaviour of stopping at the first error is wrong and is something we will try to repair.
Here is a minimal breaking example in Java: https://github.com/berezovskyi/Validator-Demo/tree/b1-unit-tests
Failing test: https://github.com/berezovskyi/Validator-Demo/blob/b1-unit-tests/validator-demo/src/test/java/ValidatorTest.java#L24
Wrapper class to for library calls: https://github.com/berezovskyi/Validator-Demo/blob/b1-unit-tests/validator-demo/src/main/java/Validator.java
I tried the example and it works. With the invalid shape, it signals an error, while If you uncomment the invalid shape, you can se that it is validated.
The problem, I think, is the behaviour of the whole validator which is different from SHACL in that it doesn't generate a validation report and it just stops as soon as it detects an error.
I am planning to work on this issue in the next weeks.
I reopen the issue until I solve issue #38
The following Shapes graph and Data graph exemplifies SHACL AND. It should work but, it does not.
Example Shapes Graph
Example Data Graph
Example taken from source: https://www.w3.org/TR/shacl/#AndConstraintComponent