summaryrefslogtreecommitdiff
path: root/test/test_graph.py
Commit message (Collapse)AuthorAgeFilesLines
* Migrate from nosetest to pytestIwan Aucamp2021-10-241-4/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch replace all uses of nose with pytest. It also includes a pytest plugin for creating EARL reports for tests with a `rdf_test_uri` parameter. Some caveats: - HTML report directory is now htmlcov instead of coverage - There is some warning related to the EARL reporting plugin which I can't quite figure out: ``` .venv/lib64/python3.7/site-packages/_pytest/config/__init__.py:676 /home/iwana/sw/d/github.com/iafork/rdflib/.venv/lib64/python3.7/site-packages/_pytest/config/__init__.py:676: PytestAssertRewriteWarning: Module already imported so cannot be rewritten: test.earl self.import_plugin(import_spec) ``` This is not causing any problems as far as I can tell, but still annoying. - python setup.py test won't work anymore, I can make it work but this is not advised by pytest: https://github.com/pytest-dev/pytest-runner/#deprecation-notice - run_test.py is still there but it's not really referenced anymore from anywhere and the options it accepts are completely different as it's options were based on nose. I would say it should be removed entirely but for now it is basically just a wrapper around pytest that basically does nothing. - Removed references to test attributes as currently they are not being used anywhere anyway, I guess we can add them back if there is some use for them later. - A lot of tests are still marked to skip when really they should be marked with xfail. This is also affecting the RDFT test manifests and result in reports saying tests are skipped when really we know they will fail and they are only skipped for this reason. But there is no change here from before, and pytest makes it easier to dynamically do expected failures. Special thanks to Wes Turner for his advice and inputs on this process.
* Fix Graph.parse URL handling on windowsIwan Aucamp2021-10-121-0/+19
| | | | | | | | | | Using `pathlib.Path("http://example.com/").exists()` on windows causes an exception as a URL is not a valid path, while `os.path.exists("http://example.com/")` just returns false. This patch reverts _create_input_source_from_location to using `os.path.exists()` instead of pathlib.Path to make it possible to parse graphs from http URLs on windows.
* blacked everything6.0.0Nicholas Car2021-07-201-4/+11
|
* Add tests for Graph.transitive_{subjects,objects}Iwan Aucamp2021-05-121-0/+41
| | | | This is based on examples/transitive.py
* Fix graphFormatGuess test for when one of the expected endpoints are downAshley Sommer2020-09-181-4/+14
|
* Merge remote-tracking branch 'origin/master' into t0b3_masterAshley Sommer2020-08-271-2/+67
|\ | | | | | | | | | | | | | | | | # Conflicts: # rdflib/namespace.py # rdflib/parser.py # rdflib/plugins/memory.py # rdflib/plugins/parsers/ntriples.py # test/test_iomemory.py
| * Merge pull request #1140 from RDFLib/improve_graph_parseAshley Sommer2020-08-271-1/+62
| |\ | | | | | | improved Graph().parse()
| | * improved Graph().parse()Nicholas Car2020-08-141-1/+62
| | |
| * | Removed IOMemory storeAshley Sommer2020-08-191-1/+5
| |/ | | | | | | | | | | | | | | Renamed Memory2 to Memory Renamed Memory1 to SimpleMemory Set default store to new Memory Fixed tests Fixed docs
* | 2to3 whole sourcebaset0b32020-06-221-7/+7
|/ | | | Signed-off-by: t0b3 <thomas.bettler@gmail.com>
* blacked all python filesNicholas Car2020-05-161-19/+23
|
* updating deprecated testing syntax (#697)Nate Prewitt2017-01-241-29/+29
|
* "Fix" for issue #296, GraphValue has no articulated role and no apparent use.Graham Higgins2013-11-091-30/+0
|
* Dataset and graph_aware store fixesGunnar Aastrand Grimnes2013-07-291-1/+1
| | | | Add graphs when parsing, so also empty graphs are added.
* whitespace gardeningGunnar Aastrand Grimnes2013-07-291-1/+1
|
* Cleaning up Dataset class, adding graph tracking to store API, asGunnar Aastrand Grimnes2013-07-291-7/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | discussed in #307 Summary of changes: * added methods ```add_graph``` and ```remove_graph``` to the Store API, implemented these for Sleepycat and IOMemory. A flag, ```graph_awareness``` is set on the store if they methods are supported, default implementations will raise an exception. * made the dataset require a store with the ```graph_awareness``` flag set. * removed the graph-state kept in the ```Dataset``` class directly. * removed ```dataset.add_quads```, ```remove_quads``` methods. The ```add/remove``` methods of ```ConjunctiveGraph``` are smart enough to work with triples or quads. * removed the ```dataset.graphs``` method - it now does exactly the same as ```contexts``` * cleaned up a bit more confusion of whether Graph instance or the Graph identifiers are passed to store methods. (#225)
* Add some storage conveniencesGraham Higgins2013-03-211-57/+54
|
* Skip test of now-deprecated Statement class.Graham Higgins2012-11-061-1/+1
|
* made unittests skip tests where dependencies for stores are not available, ↵Gunnar Aastrand Grimnes2012-09-231-1/+7
| | | | triggered by store raising ImportError
* more test cleanups - test all storesGunnar Aastrand Grimnes2012-07-221-103/+24
|
* fixes #214. Made turtle parser that does not require context-aware store. ↵Gunnar Aastrand Grimnes2012-07-221-1/+1
| | | | Test fixes.
* Amend tests to skip known pypy/jython issuesGraham Higgins2012-01-061-0/+8
|
* Integrate Gerhard Weiss' cleanup of tempfile handling.Graham Higgins2012-01-061-4/+5
|
* Various more fixes for Python 3.Thomas Kluyver2011-11-121-2/+3
|
* More fixes for Python 3 compatibility.Thomas Kluyver2011-11-121-1/+1
|
* NQuads serializer requires context-aware store so exclude the plugin from thisGraham Higgins2011-10-261-5/+6
| | | | test.
* Fixed 103gromgull2010-02-031-6/+75
| | | | ALTHOUGH, there is a more subtle issue here. Now we send the right accept header, but we might still get something else back, in which case we also get the mime-type of whatever it is. Whether we want to be tolerant and try to parse it as what it is, not what we asked for is another question. (Another ticket?)
* resurrected final newline test from svn-branch, and fixed issue 5gromgull2010-02-021-0/+18
|
* added tests for sub/add/mulgromgull2010-02-021-0/+104
|
* moved RDF and RDFS into rdflib.namespace; lower cased the rest of the ↵eikeon2009-04-021-1/+1
| | | | top-level module names
* annotated tests with attributes known_issue, slow, non_core and sparql to ↵eikeon2009-04-021-4/+0
| | | | make it easier to run the various groups of tests; and make the default be tests that match the following: \!known_issue,\!slow,\!non_core,\!sparql
* cleaned upeikeon2009-03-241-20/+0
|
* renaming test modules so they get picked up by noseeikeon2009-03-081-0/+202