summaryrefslogtreecommitdiff
path: root/test/test_n3.py
Commit message (Collapse)AuthorAgeFilesLines
* Migrate from nosetest to pytestIwan Aucamp2021-10-241-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 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.
* blacked everything6.0.0Nicholas Car2021-07-201-1/+1
|
* Merge branch 'master' into hsolbrig/masterEdmond Chuc2021-07-081-4/+4
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | # Conflicts: # rdflib/__init__.py # rdflib/compat.py # rdflib/namespace/__init__.py # rdflib/plugins/parsers/rdfxml.py # rdflib/plugins/serializers/rdfxml.py # rdflib/tools/csv2rdf.py # test/test_dawg.py # test/test_namespace.py # test/test_nt_misc.py # test/test_rdfxml.py # test/test_seq.py # test/test_trig.py # test/testutils.py
| * Serialize Changes:Ashley Sommer2020-10-081-2/+2
| | | | | | | | | | | | | | | | 1) Change default format from 'xml' to 'turtle' 2) If destination is None and encoding is None, output a str, not bytes 3) Add a new convenience method to print the Graph contents (turtle by default) Lots of fixes in tests to adapt to these changes (serialize is used a lot to check graph state in tests). Blacked files which were involved in this change.
| * 2to3 whole sourcebaset0b32020-06-221-2/+2
| | | | | | | | Signed-off-by: t0b3 <thomas.bettler@gmail.com>
* | Migration from ClosedNamespace to DeclaredNamespacehsolbrig2020-05-261-1/+6
|/ | | | Passes all unit tests, but did have to remove '.' from manifest and earl imports. May have to restore...
* blacked all python filesNicholas Car2020-05-161-34/+50
|
* removal of all uses of package sixNicholas Car2020-05-161-4/+2
|
* Fix for python 2.7Natanael Arndt2020-04-171-2/+2
|
* TEST: Stress test exponent regexChris Markiewicz2020-04-171-1/+21
|
* Add test for exponent floats with leading dotNatanael Arndt2020-04-171-0/+25
|
* a slightly opinionated autopep8 runGunnar Aastrand Grimnes2018-10-301-9/+7
| | | | | | | | opinions is mainly: no to long lines, but not at any cost. notation3.py crashses autopep :D Also rdflib/__init__.py gets completely broken
* removed most of the six import from py3compatGunnar Aastrand Grimnes2017-01-301-1/+2
| | | | now six is used throughout.
* converted all testsGunnar Aastrand Grimnes2017-01-301-5/+3
|
* updating deprecated testing syntax (#697)Nate Prewitt2017-01-241-2/+2
|
* added test and fixed #312Gunnar Aastrand Grimnes2013-12-301-0/+11
|
* removed incorrect testGunnar Aastrand Grimnes2013-11-201-19/+0
|
* Added test for #326 (accept single quotes around Turtle strings)Alexander Dutton2013-10-141-0/+16
|
* Test N3 formula serialization.Eric Peden2013-05-231-0/+5
|
* test fix for py3gromgull2013-03-111-1/+2
|
* better tests for base support in n3/turtle. Fixes #248.gromgull2013-03-111-29/+70
|
* added parser/serializer roundtrip testgromgull2012-07-201-8/+0
|
* cleaned up tests, removed duplicates, more sensible namesgromgull2012-07-181-28/+8
|
* fixed n3 parser to allow .s in prefixesgromgull2012-02-141-0/+5
|
* Fix to error condition reported in issue206Graham Higgins2012-01-251-1/+6
|
* fix from Rob Sanderson so that n3/turtle parser does not choke on UTF-8 BOM ↵ed.summers2011-01-051-0/+7
| | | | (Fixes issue 156)
* added test for issue68gromgull2010-02-021-2/+7
|
* made test_n3 be included in testsgromgull2010-02-021-3/+3
|
* changed n3 test-names so nose picks them upgromgull2010-02-021-2/+2
|
* added some n3 tests for known issues;gromgull2010-02-011-0/+40
|
* Fairly big revision of the Turtle and N3 serializers, including:lindstream2009-09-091-6/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | - only generate prefixes for predicates (thus much less gratuitous); - use prefix if bound uri is used as subject or object (common in ontologies); - prefixes are used for datatypes (if bound in the graph); - integer and float literals are outputted as is (as supported by turtle and n3); - prepared to use plain boolean literals in place (not active since the n3 parser doesn't yet support those..); - for "rdf:nil" (the empty list), "()" is used; - for n3 only, "=" is used for "owl:sameAs", and "=>" for log:implies; - 4 space indents (not 5) and no spurious trailing spaces; - space before periods; - no newline before @prefix declarations, one after; - added serializer flag "spacious" (defaults to False); if True: - use two newlines after prefix declarations - one extra newline at end of document - top-level bnodes as "[]" instead of surrounding statements; - nested bnodes start with "[ ", ends with " ]"; - some space/indent tweaks for n3 graph literals . Changes to other parts: - Added some more n3 test files and altered some n3 test code. - The "n3()" method of "term.Literal" now uses the new "_literal_n3" method, which takes some optional parameters and is used directly by the turtle+n3 serializers. - Added a bunch of doctests in Literal's "n3" and "_literal_n3". - Registered "turtle" as a serialization format (due to the tokens ("=", "=>") supported by N3 but not by Turtle).
* moved namespace bits from term into a namespace moduleeikeon2009-04-021-1/+1
|
* renaming so that nose picks it up as a test moduleeikeon2009-03-101-1/+1
|
* renaming test modules so they get picked up by noseeikeon2009-03-081-0/+141