diff --git a/fix-test-failure-of-test_atoms-and-test_overrides_gtk.patch b/fix-test-failure-of-test_atoms-and-test_overrides_gtk.patch new file mode 100644 index 0000000000000000000000000000000000000000..ed3ca39e161c6859771b109b9956ae3123097762 --- /dev/null +++ b/fix-test-failure-of-test_atoms-and-test_overrides_gtk.patch @@ -0,0 +1,39 @@ +From 925182370146907c51712d77bc026177f0644425 Mon Sep 17 00:00:00 2001 +From: panxiaohe +Date: Sat, 22 May 2021 15:21:50 +0800 +Subject: [PATCH] fix test failure of test_atoms and test_overrides_gtk + +--- + tests/test_atoms.py | 2 +- + tests/test_overrides_gtk.py | 2 +- + 2 files changed, 2 insertions(+), 2 deletions(-) + +diff --git a/tests/test_atoms.py b/tests/test_atoms.py +index 26d5c43..c2d41cb 100644 +--- a/tests/test_atoms.py ++++ b/tests/test_atoms.py +@@ -24,7 +24,7 @@ def is_X11(): + + + @unittest.skipUnless(Gdk, 'Gdk not available') +-@unittest.skipIf(Gdk._version == "4.0", 'Gdk4 doesn\'t have GdkAtom') ++#@unittest.skipIf(Gdk._version == "4.0", 'Gdk4 doesn\'t have GdkAtom') + class TestGdkAtom(unittest.TestCase): + def test_create(self): + atom = Gdk.Atom.intern('my_string', False) +diff --git a/tests/test_overrides_gtk.py b/tests/test_overrides_gtk.py +index 88b3f88..9bbf35b 100644 +--- a/tests/test_overrides_gtk.py ++++ b/tests/test_overrides_gtk.py +@@ -40,7 +40,7 @@ def gtkver(): + Gtk.get_micro_version()) + + +-GTK4 = (Gtk._version == "4.0") ++GTK4 = (Gtk_version == "4.0") + + + @contextlib.contextmanager +-- +1.8.3.1 + diff --git a/pygobject3.spec b/pygobject3.spec index ca9bf9a1966836212ad358f966747bf3388f128e..8d5f965bc41e01072805c1d91d9665600c057f90 100644 --- a/pygobject3.spec +++ b/pygobject3.spec @@ -2,14 +2,17 @@ Name: pygobject3 Version: 3.36.1 -Release: 1 +Release: 2 Summary: Provides bindings for GObject based libraries License: LGPLv2+ and MIT URL: https://wiki.gnome.org/Projects/PyGObject Source0: https://download.gnome.org/sources/pygobject/3.36/pygobject-%{version}.tar.xz +Patch9000: fix-test-failure-of-test_atoms-and-test_overrides_gtk.patch + BuildRequires: glib2-devel >= 2.48.0 gobject-introspection-devel >= 1.46.0 BuildRequires: meson cairo-gobject-devel python2-devel >= 2.7 python2-cairo-devel >= 1.11.1 +BuildRequires: python2-pytest python3-pytest %if 0%{?with_python3} BuildRequires: python3-devel >= 3.4 python3-cairo-devel >= 1.11.1 %endif @@ -99,6 +102,10 @@ pushd %{py3dir} %meson_install popd +%check +%{__python2} setup.py test +%{__python3} setup.py test + %pre %preun @@ -138,6 +145,9 @@ popd %{_libdir}/pkgconfig/pygobject-3.0.pc %changelog +* Sat May 22 2021 wangchen - 3.36.1-2 +- enable check test suite + * Wed Aug 26 2020 wangchen - 3.36.1-1 - update to 3.36.1