-
Notifications
You must be signed in to change notification settings - Fork 89
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Added SPARQL 1.1 compliance tests (incomplete) #102
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
its just for completeness, because we not really testing anything. reason is, that based on ARC2 wiki, MOVE queries are not supported.
type hint problem (5.6 with symfony YAML) and count requires something which implements Countable (php nightly)
reason: doctrine/instantiator#30 fix: lowering doctrine/instantiator version below 1.1
applied makeQueryA1Liner in tests to have a clean way to output a query string.
there is bascially nothing to test, because ARC2 doesnt support such queries at all.
…-connections-error
a query is from now formated as given, expect spaces
…SyntaxUpdate1 DropTest, SyntaxUpdate1Test: changed meaning of many tests. instead of asserting their result to 0, which means the given query failed, the test is marked as skipped. that way its explicit and visible, that something is not as it is supposed to be. GroupingTest: provide more information for skipped tests.
Ping @semsol :) |
Cheers :-) |
Closed
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
What do you do, if you have a cold and must stay at home? You write tests for ARC2!
W3C test suite
There is a test suite for SPARQL 1.1 compliance provided by the W3C here: https://www.w3.org/2009/sparql/docs/tests/. It contains many tests for different types of queries. They range from simple SELECT queries over function-usage to graph management.
Goal and motivation
I want to know the current state of SPARQL 1.0/1.1 support of ARC2. Instead of using custom queries, i decided to use the official test suite. Their tests showed that ARC2 lacks major parts of SPARQL 1.0/1.1. Please do not understand that as blaming, but as a first step to define a basement for further development. With these tests, further changes on the query engine can be made without worrying about adding bugs or change expected behavior.
Tested ARC2 component
These new tests check the result from
ARC2_Store::query
for a given query.Coverage
I picked mostly cases, which cover major functionality. In the following related folders from the test suite:
Additionally, there a some cases which have exotic kinds of configuration (
manifest.ttl
). A few of those are also part of the list.7 folders are covered, 22 folders are not covered yet.
Important: How to interpret the new tests
Don't get fooled, there are 2 different kinds of the tests:
manifest.ttl
, load data etc. and run a W3C-provided query. A test is approved, if the expected result (given by the W3C) matches the actual result (returned from ARC2).Every skipped test provides meaningful information. For instance
Tests\sparql11\AggregatesTest::test_agg_avg_01
outputs:This way one can see the limitations of ARC2, sometimes also the reason. If one decides to extend/fix ARC2 SPARQL support, they can take the related test and change it.
Current output in PHPUnit
New PHPUnit output below. To see a full overview, you can look here.
Further changes
Besides these new files in
tests/sparql11
, i changed the following files:Related issues
During this process, i opened the following issues: