- Skip failing test on 32bit arch (gh#pydata/sparse#490).

OBS-URL: https://build.opensuse.org/package/show/devel:languages:python:numeric/python-sparse?expand=0&rev=13
This commit is contained in:
2022-10-21 09:10:06 +00:00
committed by Git OBS Bridge
parent 7600afcb8a
commit e6f2374bfb
3 changed files with 31 additions and 0 deletions

View File

@@ -1,3 +1,8 @@
-------------------------------------------------------------------
Fri Oct 21 08:39:20 UTC 2022 - Matej Cepl <mcepl@suse.com>
- Skip failing test on 32bit arch (gh#pydata/sparse#490).
-------------------------------------------------------------------
Thu Jul 14 17:53:01 UTC 2022 - Ben Greiner <code@bnavigator.de>

View File

@@ -26,6 +26,9 @@ License: BSD-3-Clause
Group: Development/Languages/Python
URL: https://github.com/pydata/sparse
Source: https://files.pythonhosted.org/packages/source/s/sparse/sparse-%{version}.tar.gz
# PATCH-FIX-UPSTREAM skip-32bit-archs.patch gh#pydata/sparse#490 mcepl@suse.com
# Skip some tests on 32bit architecture
Patch0: skip-32bit-archs.patch
BuildRequires: %{python_module setuptools}
# SECTION test requirements
BuildRequires: %{python_module dask-array}

23
skip-32bit-archs.patch Normal file
View File

@@ -0,0 +1,23 @@
---
sparse/tests/test_coo.py | 3 +++
1 file changed, 3 insertions(+)
--- a/sparse/tests/test_coo.py
+++ b/sparse/tests/test_coo.py
@@ -1,6 +1,7 @@
import contextlib
import operator
import pickle
+import platform
import sys
from functools import reduce
@@ -14,6 +15,8 @@ from sparse import COO
from sparse._settings import NEP18_ENABLED
from sparse._utils import assert_eq, random_value_array, html_table
+pytestmark = pytest.mark.skipif(platform.architecture()[0] == '32bit',
+ reason='Fails on 32bit arch (gh#pydata/sparse#490)')
@pytest.fixture(scope="module", params=["f8", "f4", "i8", "i4"])
def random_sparse(request):