Skip to content

Commit 833003d

Browse files
committed
Skip test for btune
1 parent 3d12b4d commit 833003d

File tree

1 file changed

+9
-6
lines changed

1 file changed

+9
-6
lines changed

blosc2/core.py

Lines changed: 9 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -600,8 +600,9 @@ def pack_tensor(tensor, chunksize=None, **kwargs):
600600
>>> import numpy as np
601601
>>> th = np.arange(1e6, dtype=np.float32)
602602
>>> cframe = blosc2.pack_tensor(th)
603-
>>> len(cframe) < th.size * th.itemsize
604-
True
603+
>>> if not os.getenv("BTUNE_TRADEOFF"):
604+
... assert len(cframe) < th.size * th.itemsize
605+
...
605606
606607
See also
607608
--------
@@ -732,8 +733,9 @@ def save_tensor(tensor, urlpath, chunksize=None, **kwargs):
732733
>>> import numpy as np
733734
>>> th = np.arange(1e6, dtype=np.float32)
734735
>>> serial_size = blosc2.save_tensor(th, "test.bl2", mode="w")
735-
>>> serial_size < th.size * th.itemsize
736-
True
736+
>>> if not os.getenv("BTUNE_TRADEOFF"):
737+
... assert serial_size < th.size * th.itemsize
738+
...
737739
738740
See also
739741
--------
@@ -769,8 +771,9 @@ def load_tensor(urlpath):
769771
>>> import numpy as np
770772
>>> th = np.arange(1e6, dtype=np.float32)
771773
>>> size = blosc2.save_tensor(th, "test.bl2", mode="w")
772-
>>> size < th.size * th.itemsize
773-
True
774+
>>> if not os.getenv("BTUNE_TRADEOFF"):
775+
... assert size < th.size * th.itemsize
776+
...
774777
>>> th2 = blosc2.load_tensor("test.bl2")
775778
>>> np.array_equal(th, th2)
776779
True

0 commit comments

Comments
 (0)