[pygobject/benzea/gio-asyncio] test
- From: Benjamin Berg <bberg src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [pygobject/benzea/gio-asyncio] test
- Date: Wed, 17 Nov 2021 20:34:58 +0000 (UTC)
commit 86dc84c33232fc8a76b52980371ee53e6fb79ace
Author: Benjamin Berg <bberg redhat com>
Date: Wed Nov 17 21:05:28 2021 +0100
test
.gitlab-ci.yml | 104 +++++++++++++++++++++++++--------------------------
tests/meson.build | 1 +
tests/runtests.py | 6 +++
tests/test_events.py | 6 +++
4 files changed, 65 insertions(+), 52 deletions(-)
---
diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index de9d9b0b..ba852c19 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -52,35 +52,35 @@ pages:
only:
- master
-mingw32:
- variables:
- MSYSTEM: "MINGW32"
- <<: *mingw-defaults
-
-mingw64:
- variables:
- MSYSTEM: "MINGW64"
- <<: *mingw-defaults
+#mingw32:
+# variables:
+# MSYSTEM: "MINGW32"
+# <<: *mingw-defaults
+#
+#mingw64:
+# variables:
+# MSYSTEM: "MINGW64"
+# <<: *mingw-defaults
python3.6:
variables:
PYENV_VERSION: "3.6.12"
<<: *defaults
-python3.7:
- variables:
- PYENV_VERSION: "3.7.9-debug"
- <<: *defaults
-
-python3.8:
- variables:
- PYENV_VERSION: "3.8.5-debug"
- <<: *defaults
-
-python3.9:
- variables:
- PYENV_VERSION: "3.9.0-debug"
- <<: *defaults
+#python3.7:
+# variables:
+# PYENV_VERSION: "3.7.9-debug"
+# <<: *defaults
+#
+#python3.8:
+# variables:
+# PYENV_VERSION: "3.8.5-debug"
+# <<: *defaults
+#
+#python3.9:
+# variables:
+# PYENV_VERSION: "3.9.0-debug"
+# <<: *defaults
pypy3.6:
allow_failure: true
@@ -88,32 +88,32 @@ pypy3.6:
PYENV_VERSION: "pypy3.6-7.3.1"
<<: *defaults
-old-i386-py3:
- stage: build_and_test
- image: registry.gitlab.gnome.org/gnome/pygobject/old:v4
- artifacts:
- paths:
- - coverage/
- script:
- - bash -x ./.gitlab-ci/test-docker-old.sh
-
-gnome-master:
- allow_failure: true
- stage: build_and_test
- image: registry.gitlab.gnome.org/gnome/gnome-runtime-images/gnome:master
- tags:
- - flatpak
- script:
- - xvfb-run -a flatpak run --filesystem=host --share=network --socket=x11 --command=bash
org.gnome.Sdk//master -x .gitlab-ci/test-flatpak.sh
-
-gnome-master-gtk4:
- allow_failure: true
- stage: build_and_test
- image: registry.gitlab.gnome.org/gnome/gnome-runtime-images/gnome:master
- tags:
- - flatpak
- script:
- - xvfb-run -a flatpak run --filesystem=host --share=network --socket=x11 --command=bash
org.gnome.Sdk//master -x .gitlab-ci/test-flatpak-gtk4.sh
- artifacts:
- paths:
- - coverage/
\ No newline at end of file
+#old-i386-py3:
+# stage: build_and_test
+# image: registry.gitlab.gnome.org/gnome/pygobject/old:v4
+# artifacts:
+# paths:
+# - coverage/
+# script:
+# - bash -x ./.gitlab-ci/test-docker-old.sh
+#
+#gnome-master:
+# allow_failure: true
+# stage: build_and_test
+# image: registry.gitlab.gnome.org/gnome/gnome-runtime-images/gnome:master
+# tags:
+# - flatpak
+# script:
+# - xvfb-run -a flatpak run --filesystem=host --share=network --socket=x11 --command=bash
org.gnome.Sdk//master -x .gitlab-ci/test-flatpak.sh
+#
+#gnome-master-gtk4:
+# allow_failure: true
+# stage: build_and_test
+# image: registry.gitlab.gnome.org/gnome/gnome-runtime-images/gnome:master
+# tags:
+# - flatpak
+# script:
+# - xvfb-run -a flatpak run --filesystem=host --share=network --socket=x11 --command=bash
org.gnome.Sdk//master -x .gitlab-ci/test-flatpak-gtk4.sh
+# artifacts:
+# paths:
+# - coverage/
\ No newline at end of file
diff --git a/tests/meson.build b/tests/meson.build
index 6a25688e..0ca46fd4 100644
--- a/tests/meson.build
+++ b/tests/meson.build
@@ -126,6 +126,7 @@ if pycairo_dep.found() and pycairo_dep.type_name() == 'internal'
endif
envdata.append('PYTHONPATH', python_paths)
envdata.append('TESTS_BUILDDIR', meson.current_build_dir())
+envdata.append('PYGI_TEST_VERBOSE', '1')
test('pygobject-test-suite', python,
args : [join_paths(meson.current_source_dir(), 'runtests.py')],
diff --git a/tests/runtests.py b/tests/runtests.py
index 721b5d80..932b8cb4 100755
--- a/tests/runtests.py
+++ b/tests/runtests.py
@@ -6,6 +6,12 @@ import sys
import pytest
+# Try to generate backtrace if meson kills as with SIGTERM:
+# will not work if the mainloop is overriding SIGTERM
+import signal
+def r(*args):
+ raise KeyboardInterrupt()
+signal.signal(signal.SIGTERM, r)
def main(argv):
if '--help' in argv:
diff --git a/tests/test_events.py b/tests/test_events.py
index 6b4cca5f..56340db4 100644
--- a/tests/test_events.py
+++ b/tests/test_events.py
@@ -26,6 +26,7 @@ except ImportError:
warnings.warn('Upstream test_asyncio module has missing files!')
raise unittest.SkipTest('Upstream test_asyncio module has missing files!')
+import os
import sys
import gi
import gi.events
@@ -39,12 +40,17 @@ if sys.platform != 'win32':
class GLibEventLoopTests(UnixEventLoopTestsMixin, test_utils.TestCase):
+ def setUp(self):
+ print("running", os.environ['PYTEST_CURRENT_TEST'])
+ super().setUp()
+
def create_event_loop(self):
return gi.events.GLibEventLoop(main_context=GLib.MainContext.default())
class SubprocessWatcherTests(SubprocessMixin, test_utils.TestCase):
def setUp(self):
+ print("running", os.environ['PYTEST_CURRENT_TEST'])
super().setUp()
policy = gi.events.GLibEventLoopPolicy()
asyncio.set_event_loop_policy(policy)
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]