diff options
author | Christoph Reiter <creiter@src.gnome.org> | 2017-04-01 18:06:47 +0200 |
---|---|---|
committer | Christoph Reiter <creiter@src.gnome.org> | 2017-04-01 18:17:17 +0200 |
commit | a2b3d846fab3a4b660eefbe3555933afe6d9c90a (patch) | |
tree | 4cc3c2910e2b2aa27475178cb912673348263726 /tests/test_atoms.py | |
parent | ed488be1f0bcd2d2ec1acf98f27585d8577ddc5f (diff) | |
download | pygobject-a2b3d846fab3a4b660eefbe3555933afe6d9c90a.tar.gz |
tests: silence some glib deprecation warnings
These functions were deprecated in the last few cycles.
This hides the warnings when running the test suite.
https://bugzilla.gnome.org/show_bug.cgi?id=780812
Diffstat (limited to 'tests/test_atoms.py')
-rw-r--r-- | tests/test_atoms.py | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/tests/test_atoms.py b/tests/test_atoms.py index 762f41e3..e6c8aba1 100644 --- a/tests/test_atoms.py +++ b/tests/test_atoms.py @@ -10,6 +10,8 @@ try: except (ValueError, ImportError): Gdk = None +from helper import capture_glib_deprecation_warnings + @unittest.skipUnless(Gdk, 'Gdk not available') class TestGdkAtom(unittest.TestCase): @@ -79,8 +81,9 @@ class TestGdkAtom(unittest.TestCase): "fails on OSX/Windows") def test_out_glist(self): display = Gdk.Display.get_default() - dm = display.get_device_manager() - device = dm.get_client_pointer() + with capture_glib_deprecation_warnings(): + dm = display.get_device_manager() + device = dm.get_client_pointer() axes = device.list_axes() axes_names = [atom.name() for atom in axes] self.assertNotEqual(axes_names, []) |