Skip to content
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

Rework turtle-like test suites #1986

Merged

Conversation

aucampia
Copy link
Member

@aucampia aucampia commented Jun 5, 2022

This patch reworks the turtle-like test suites (N-Quads, N-Triples,
Turtle, TriG). The changes includes:

  • A new DAWG Manifest processor:
    • Incorporates pytest expected failure support in test parameter generation.
    • Supports URI mapping so that local filesystem URIs can be mapped to the
      correct remote base URIs and still work correctly with local files.
    • Supports custom entry types so that suite specific handling can be
      implemented separately from the core manifest processor. This will
      be used for SPARQL test suite and JSON test suite processing.
  • Updated EARL reporter:
    • Support for the new DAWG Manifest processor.
    • Writing of EARL reports by default if a report prefix is
      specified in the DAWG Manifest processor.
    • Reports output is sorted so that it can be compared with text based
      diff tools.
    • Fixed reporting of xfail tests. These were reported as skipped before,
      now they are reported as failed.

The testing is also more accurate, and now tests which were reported as
passing before are now correctly reported as failing. With one exception
all these failures are related to leniency in the parser, as our parser
accepts input that should raise an error when parsing.

Other changes:

  • Moved IRI related test utilities to a separate module.
  • Added generated reports for turtle-like formats to git with -HEAD
    suffix.

Subsequent changes will use this new processor for SPARQL and RDF/XML,
the draft for these can be seen in #1969.

Summary of changes

Checklist

  • Checked that there aren't other open pull requests for
    the same change.
  • Checked that all tests and type checking passes.
  • Considered granting push permissions to the PR branch,
    so maintainers can fix minor issues and keep your PR up to date.

@aucampia aucampia force-pushed the iwana-20220605T1432-rework_turtle_like branch from 60bd54e to 6217830 Compare June 5, 2022 12:55
@coveralls
Copy link

coveralls commented Jun 5, 2022

Coverage Status

Coverage increased (+0.01%) to 88.525% when pulling 8daae37 on aucampia:iwana-20220605T1432-rework_turtle_like into 7d8cab6 on RDFLib:master.

This patch reworks the turtle-like test suites (N-Quads, N-Triples,
Turtle, TriG). The changes includes:

- A new DAWG Manifest processor:
  - Incorporates pytest expected failure support in test paramater generation.
  - Supports URI mapping so that local filesystem URIs can be mapped to the
    correct remote base URIs and still work correctly with local files.
  - Supports custom entry types so that suite specific handling can be
    implemented separately from the core manifest processor. This will
    be used for SPARQL test suite and JSON test suite processing.
- Updated EARL reporter:
  - Support for the new DAWG Manifest processor.
  - Writing of EARL reports by detault if a report prefix is
    specified in the DAWG Manifest processor.
  - Reports output is sorted so that it can be compared with text based
    diff tools.

The testing is also more accurate, and now tests which were reported as
passing before are now correctly reported as failing. With one exception
all these failures are related to leniancy in the parser, as our parser
accepts input that should raise an error when parsing.

Other changes:
- Moved IRI related test utilities to a separate module.
- Added generated reports for turtle-like formats to git with `-HEAD`
  suffix.

Subsequent changes will use this new processor for SPARQL and RDF/XML.
@aucampia aucampia force-pushed the iwana-20220605T1432-rework_turtle_like branch from 6217830 to 8daae37 Compare June 5, 2022 13:02
@aucampia aucampia marked this pull request as ready for review June 5, 2022 13:04
@aucampia aucampia requested a review from a team June 5, 2022 13:08
@aucampia aucampia added the review wanted This indicates that the PR is ready for review label Jun 5, 2022
Copy link

@ghost ghost left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

impressive, much-needed improvement to the coherence of the RDFLib test suite

@aucampia aucampia merged commit 60ff2fd into RDFLib:master Jun 5, 2022
@ghost ghost removed the review wanted This indicates that the PR is ready for review label Jun 8, 2022
@aucampia aucampia deleted the iwana-20220605T1432-rework_turtle_like branch June 23, 2022 19:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants