Skip to content
Merged
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
15 changes: 4 additions & 11 deletions pandas/tests/libs/test_hashtable.py
Original file line number Diff line number Diff line change
Expand Up @@ -246,24 +246,17 @@ def test_lookup_overflow(self, writable):
(ht.Float64HashTable, ht.Float64Vector, "float64", False),
(ht.Int64HashTable, ht.Int64Vector, "int64", False),
(ht.Int32HashTable, ht.Int32Vector, "int32", False),
pytest.param(
ht.UInt64HashTable,
ht.UInt64Vector,
"uint64",
False,
marks=pytest.mark.xfail(
reason="Sometimes doesn't raise.",
strict=False,
),
),
(ht.UInt64HashTable, ht.UInt64Vector, "uint64", False),
],
)
def test_vector_resize(
self, writable, htable, uniques, dtype, safely_resizes, nvals
):
# Test for memory errors after internal vector
# reallocations (GH 7157)
vals = np.array(np.random.randn(1000), dtype=dtype)
# Changed from using np.random.rand to range
# which could cause flaky CI failures when safely_resizes=False
vals = np.array(range(1000), dtype=dtype)

# GH 21688 ensures we can deal with read-only memory views
vals.setflags(write=writable)
Expand Down