Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,6 @@ doc = [
"sphinx_rtd_theme",
]
test = [
"packaging",
"numpy<2 ; python_version == '3.9'",
"blosc2>=2.5.1",
"blosc2-grok>=0.2.2",
Expand Down
13 changes: 8 additions & 5 deletions src/hdf5plugin/test.py
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,6 @@
from typing import Any, cast

import numpy
from packaging.version import parse as parse_version

import h5py
import hdf5plugin
Expand Down Expand Up @@ -435,8 +434,8 @@ def setUp(self):
numpy.array(["test", "strings", "ascii"] * N, dtype="S"),
numpy.array([b"test", b"strings", b"binary"] * N, dtype="O"),
]
has_h5py_314 = parse_version(h5py.__version__) >= parse_version("3.14")
has_numpy_2 = parse_version(numpy.__version__) >= parse_version("2.0")
has_h5py_314 = h5py.version.version_tuple >= (3, 14)
has_numpy_2 = numpy.__version__.startswith("2.")
if has_h5py_314 and has_numpy_2:
self.string_arrays.append(
numpy.array(["test", "strings", "Crème brûlée"] * N, dtype="T")
Expand Down Expand Up @@ -494,13 +493,17 @@ def _test_strings(
self.assertEqual(len(filters), 1)
self.assertEqual(filters[0][0], hdf5plugin.FILTERS[filter_name])

@unittest.skip(reason="segfault (#364)")
@unittest.skipIf(
h5py.version.hdf5_version_tuple < (2, 1, 0), "hdf5 v2.1.0 required"
)
Comment on lines -497 to +498

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍

@unittest.skipUnless(should_test("blosc"), "Blosc filter not available")
def testStringsBlosc(self):
"""Strings write/read test with blosc filter plugin"""
self._test_strings("blosc") # Default options

@unittest.skip(reason="segfault (#364)")
@unittest.skipIf(
h5py.version.hdf5_version_tuple < (2, 1, 0), "hdf5 v2.1.0 required"
)
@unittest.skipUnless(should_test("blosc2"), "Blosc filter not available")
def testStringsBlosc2(self):
"""Strings write/read test with blosc2 filter plugin"""
Expand Down
Loading