summaryrefslogtreecommitdiff
path: root/tests/test_error.py
Commit message (Collapse)AuthorAgeFilesLines
* Remove all Python 2 Python codeChristoph Reiter2020-04-151-2/+0
|
* Make GLib.Error picklable. Fixes #145Christoph Reiter2018-04-051-0/+17
| | | | | Make __module__ match the module where it gets exposed so Python can find the right class.
* tests: Make it possible to use pytest directlywip/creiter/pytest-directChristoph Reiter2018-02-121-4/+2
| | | | | | | | | | | pytest will just import the files passed to it and try to run tests. Since we need to run some setup code convert the tests directory to a Python package and do the initialization in __init__.py. This makes the init code (env vars, typelib search path, dbus) always run when something from the package gets imported. python3 setup.py build_tests # build pygobject and tests py.test-3 tests/test_gi.py # run tests in test_gi.py only
* tests: check passing Boxed type in GValue as function parametersThibault Saunier2016-03-011-0/+6
| | | | https://bugzilla.gnome.org/show_bug.cgi?id=761592
* Support throwing exceptions in closuresGarrett Regier2015-09-221-0/+22
| | | | | | | | | | This allows exceptions raised in vfunc implemntations and callbacks to be turned into GErrors. NOTE: this requires matchs in https://bugzilla.gnome.org/show_bug.cgi?id=729543 thus we must bump the GI req once they are commited. https://bugzilla.gnome.org/show_bug.cgi?id=710671
* tests: Use assertRaises as a context manager for GError testSimon Feltman2014-05-111-8/+6
| | | | | Simplify tests/test_error.py:TestMarshalling.test_exception so that it no longer needs to pull exception information out of sys.exc_info.
* Clobber GLib.Error with custom implementationSimon Feltman2014-05-051-12/+12
| | | | | | | | Clobber the introspection GLib.Error class with the custom Python implementation found in gi._error.GError. Update references to GLib.GError to use GLib.Error. https://bugzilla.gnome.org/show_bug.cgi?id=712519
* Add Python implementation of GErrorSimon Feltman2014-05-041-0/+37
| | | | | | | | | Add internally used gi/_error.py module as a basis for implementing a unified GError between introspection and static bindings. Patch Python implementations of GError.matches and GError.new_literal in the GLib overrides https://bugzilla.gnome.org/show_bug.cgi?id=712519
* tests: Move GError tests into test_error.pySimon Feltman2014-05-041-0/+81
https://bugzilla.gnome.org/show_bug.cgi?id=712519