[pygobject/coverage-gobject-overrides: 1/4] tests: gdk overrides: silence a deprecation warning



commit bc689cbc0a7fedb01209ffa08ac69f00f8eedc4f
Author: Christoph Reiter <reiter christoph gmail com>
Date:   Fri Nov 23 15:37:15 2018 +0100

    tests: gdk overrides: silence a deprecation warning

 tests/test_overrides_gdk.py | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
---
diff --git a/tests/test_overrides_gdk.py b/tests/test_overrides_gdk.py
index e327abe9..e497cf97 100644
--- a/tests/test_overrides_gdk.py
+++ b/tests/test_overrides_gdk.py
@@ -106,7 +106,8 @@ class TestGdk(unittest.TestCase):
         w = Gtk.Window()
         w.realize()
         window = w.get_window()
-        assert window.cairo_create() is not None
+        with capture_glib_deprecation_warnings():
+            assert window.cairo_create() is not None
 
     @unittest.skipIf(GDK4, "not in gdk4")
     def test_drag_context(self):


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]