diff options
author | Christoph Reiter <reiter.christoph@gmail.com> | 2021-09-19 16:26:14 +0200 |
---|---|---|
committer | Christoph Reiter <reiter.christoph@gmail.com> | 2021-09-19 22:16:12 +0200 |
commit | ca83316884a2e3ebe3549ec80d11de79895cd00a (patch) | |
tree | f2f5e2adabf7728dbf0e5ec84f850cead4de1ec4 | |
parent | 822a04859f22e272f97b7e9a20b1a78fca86143f (diff) | |
download | pygobject-ca83316884a2e3ebe3549ec80d11de79895cd00a.tar.gz |
tests: silence a deprecation warning with newer glib
-rw-r--r-- | tests/test_glib.py | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/tests/test_glib.py b/tests/test_glib.py index 0a5cb3d6..19eff7f9 100644 --- a/tests/test_glib.py +++ b/tests/test_glib.py @@ -282,8 +282,10 @@ https://my.org/q?x=1&y=2 self.assertGreaterEqual(micro, 0) def test_timezone_constructor(self): - timezone = GLib.TimeZone("+05:21") - self.assertEqual(timezone.get_offset(0), ((5 * 60) + 21) * 60) + with warnings.catch_warnings(): + warnings.simplefilter('ignore', DeprecationWarning) + timezone = GLib.TimeZone("+05:21") + self.assertEqual(timezone.get_offset(0), ((5 * 60) + 21) * 60) def test_source_attach_implicit_context(self): context = GLib.MainContext.default() |