forked from pool/python-python-gvm
Accepting request 1226247 from devel:languages:python
- Add opensuse-fix-tests-1-core.patch custom patch to fix tests running in OBS with limited resources, running on 1-core-VM. bsc#1233398 OBS-URL: https://build.opensuse.org/request/show/1226247 OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/python-python-gvm?expand=0&rev=8
This commit is contained in:
18
opensuse-fix-tests-1-core.patch
Normal file
18
opensuse-fix-tests-1-core.patch
Normal file
@@ -0,0 +1,18 @@
|
|||||||
|
Index: python_gvm-24.8.0/tests/connections/test_unix_socket_connection.py
|
||||||
|
===================================================================
|
||||||
|
--- python_gvm-24.8.0.orig/tests/connections/test_unix_socket_connection.py
|
||||||
|
+++ python_gvm-24.8.0/tests/connections/test_unix_socket_connection.py
|
||||||
|
@@ -62,6 +62,13 @@ class UnixSocketConnectionTestCase(unitt
|
||||||
|
connection.disconnect()
|
||||||
|
|
||||||
|
def test_unix_socket_connection_connect_send_bytes_read(self):
|
||||||
|
+ # Add sleep to make sure setup theading server is up and
|
||||||
|
+ # running even with limited resources, bsc#1233398
|
||||||
|
+ import time
|
||||||
|
+ import multiprocessing
|
||||||
|
+ if multiprocessing.cpu_count() == 1:
|
||||||
|
+ time.sleep(2)
|
||||||
|
+
|
||||||
|
connection = UnixSocketConnection(
|
||||||
|
path=self.socket_name, timeout=DEFAULT_TIMEOUT
|
||||||
|
)
|
@@ -1,3 +1,10 @@
|
|||||||
|
-------------------------------------------------------------------
|
||||||
|
Mon Nov 25 10:29:53 UTC 2024 - Daniel Garcia <daniel.garcia@suse.com>
|
||||||
|
|
||||||
|
- Add opensuse-fix-tests-1-core.patch custom patch to fix tests
|
||||||
|
running in OBS with limited resources, running on 1-core-VM.
|
||||||
|
bsc#1233398
|
||||||
|
|
||||||
-------------------------------------------------------------------
|
-------------------------------------------------------------------
|
||||||
Wed Nov 13 12:28:07 UTC 2024 - Markéta Machová <mmachova@suse.com>
|
Wed Nov 13 12:28:07 UTC 2024 - Markéta Machová <mmachova@suse.com>
|
||||||
|
|
||||||
|
@@ -25,6 +25,9 @@ License: GPL-3.0-only
|
|||||||
Group: Development/Languages/Python
|
Group: Development/Languages/Python
|
||||||
URL: https://github.com/greenbone/python-gvm
|
URL: https://github.com/greenbone/python-gvm
|
||||||
Source: https://files.pythonhosted.org/packages/source/p/python_gvm/python_gvm-%{version}.tar.gz
|
Source: https://files.pythonhosted.org/packages/source/p/python_gvm/python_gvm-%{version}.tar.gz
|
||||||
|
# PATCH-FIX-OPENSUSE opensuse-fix-tests-1-core.patch -- bsc#1233398
|
||||||
|
# Fix tests running with 1 core in VM
|
||||||
|
Patch: opensuse-fix-tests-1-core.patch
|
||||||
BuildRequires: %{python_module pip}
|
BuildRequires: %{python_module pip}
|
||||||
BuildRequires: %{python_module poetry-core}
|
BuildRequires: %{python_module poetry-core}
|
||||||
BuildRequires: %{python_module setuptools}
|
BuildRequires: %{python_module setuptools}
|
||||||
@@ -49,7 +52,7 @@ Manager (GSM) appliance and its underlying Greenbone Vulnerability Manager
|
|||||||
Greenbone Management Protocol (GMP) and Open Scanner Protocol (OSP).
|
Greenbone Management Protocol (GMP) and Open Scanner Protocol (OSP).
|
||||||
|
|
||||||
%prep
|
%prep
|
||||||
%setup -q -n python_gvm-%{version}
|
%autosetup -p1 -n python_gvm-%{version}
|
||||||
|
|
||||||
%build
|
%build
|
||||||
%pyproject_wheel
|
%pyproject_wheel
|
||||||
|
Reference in New Issue
Block a user