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

Test reorg (continued) #1788

Merged
merged 3 commits into from Apr 4, 2022
Merged

Test reorg (continued) #1788

merged 3 commits into from Apr 4, 2022

Conversation

ghost
Copy link

@ghost ghost commented Apr 2, 2022

Further test re-org, all but a couple of changes (noted below) restricted to moving tests into sub-folders and relocating w.r.t import of test.testutils / test.helpers and test fixture data.

Of note:

  • Removed unused store_performance_test.py
  • Removed unused test_rules.py and a.n3 (test imports pychinko, unavailable for a decade or more!)

Migration of some more tests to pytest to follow.

@@ -1,77 +0,0 @@
import unittest
Copy link
Member

Choose a reason for hiding this comment

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

where was this file moved to?

Copy link
Author

Choose a reason for hiding this comment

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

Of note:

Removed unused test_rules.py and a.n3 (test imports pychinko, unavailable for a decade or more!)

Copy link
Member

Choose a reason for hiding this comment

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

Would it not be better to just fix it so it becomes a test instead?

Copy link
Author

Choose a reason for hiding this comment

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

A swift foray into RDFLib's dev history reveals that test/rules.py was introduced somewhere between 2.2.3 (2005) and 2.4.0 (2007). I'll hazard a guess that it's never been executed because it imports pychinko

try:
    from pychinko import terms
    from pychinko.interpreter import Interpreter
    ...
except ImportError as e:
    print("Could not test Pychinko: %s" % e)

Although pychinko was integrated into swap back in 2007 or so, I see two issues acting to prevent a refurb: i) I doubt we'd want to introduce a dependency on the 15-year-old swap package and ii) in order to function, pychinko relies on a local installation of the Java-implemented Pellet reasoner.

(If we want to test RDF rule-processing, refurbishing FuXi is possibly the more feasible option - as noted on the Pychinko web page, at one time FuXi used Pychinko but Chimezie subsequently factored out that dependency.)

@@ -1,103 +0,0 @@
import unittest
Copy link
Member

Choose a reason for hiding this comment

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

Don't see where this moved to.

Copy link
Author

Choose a reason for hiding this comment

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

Of note:

Removed unused store_performance_test.py

Oh, I mistyped the test file name, sry

Copy link
Member

@aucampia aucampia left a comment

Choose a reason for hiding this comment

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

Thanks @gjhiggins - looks good to me - should have taken a closer look at removed files, they look fine now that I took a closer look.

@nicholascar nicholascar merged commit d496748 into RDFLib:master Apr 4, 2022
@ghost ghost deleted the more-test-reorg branch April 5, 2022 03:50
@ghost ghost mentioned this pull request Apr 5, 2022
3 tasks
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