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: 1 addition & 0 deletions pandas/tests/frame/indexing/test_where.py
Original file line number Diff line number Diff line change
Expand Up @@ -950,6 +950,7 @@ def test_where_nullable_invalid_na(frame_or_series, any_numeric_ea_dtype):
obj.mask(mask, null)


@pytest.mark.slow
@given(data=OPTIONAL_ONE_OF_ALL)
def test_where_inplace_casting(data):
# GH 22051
Expand Down
2 changes: 0 additions & 2 deletions pandas/tests/frame/test_constructors.py
Original file line number Diff line number Diff line change
Expand Up @@ -3247,7 +3247,6 @@ def test_from_out_of_bounds_ns_datetime(
assert item.asm8.dtype == exp_dtype
assert dtype == exp_dtype

@pytest.mark.skip_ubsan
def test_out_of_s_bounds_datetime64(self, constructor):
scalar = np.datetime64(np.iinfo(np.int64).max, "D")
result = constructor(scalar)
Expand Down Expand Up @@ -3283,7 +3282,6 @@ def test_from_out_of_bounds_ns_timedelta(
assert item.asm8.dtype == exp_dtype
assert dtype == exp_dtype

@pytest.mark.skip_ubsan
@pytest.mark.parametrize("cls", [np.datetime64, np.timedelta64])
def test_out_of_s_bounds_timedelta64(self, constructor, cls):
scalar = cls(np.iinfo(np.int64).max, "D")
Expand Down
1 change: 0 additions & 1 deletion pandas/tests/groupby/test_cumulative.py
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,6 @@ def test_groupby_cumprod():
tm.assert_series_equal(actual, expected)


@pytest.mark.skip_ubsan
def test_groupby_cumprod_overflow():
# GH#37493 if we overflow we return garbage consistent with numpy
df = DataFrame({"key": ["b"] * 4, "value": 100_000})
Expand Down
1 change: 1 addition & 0 deletions pandas/tests/indexes/ranges/test_setops.py
Original file line number Diff line number Diff line change
Expand Up @@ -459,6 +459,7 @@ def assert_range_or_not_is_rangelike(index):
assert not (diff == diff[0]).all()


@pytest.mark.slow
@given(
st.integers(-20, 20),
st.integers(-20, 20),
Expand Down
3 changes: 1 addition & 2 deletions pandas/tests/io/parser/common/test_float.py
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ def test_scientific_no_exponent(all_parsers_all_precisions):
[
-617,
-100000,
pytest.param(-99999999999999999, marks=pytest.mark.skip_ubsan),
-99999999999999999,
],
)
def test_very_negative_exponent(all_parsers_all_precisions, neg_exp):
Expand All @@ -59,7 +59,6 @@ def test_very_negative_exponent(all_parsers_all_precisions, neg_exp):
tm.assert_frame_equal(result, expected)


@pytest.mark.skip_ubsan
@xfail_pyarrow # AssertionError: Attributes of DataFrame.iloc[:, 0] are different
@pytest.mark.parametrize("exp", [999999999999999999, -999999999999999999])
def test_too_many_exponent_digits(all_parsers_all_precisions, exp, request):
Expand Down
2 changes: 2 additions & 0 deletions pandas/tests/io/sas/test_byteswap.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@
import pandas._testing as tm


@pytest.mark.slow
@given(read_offset=st.integers(0, 11), number=st.integers(min_value=0))
@example(number=2**16, read_offset=0)
@example(number=2**32, read_offset=0)
Expand All @@ -29,6 +30,7 @@ def test_int_byteswap(read_offset, number, int_type, should_byteswap):
_test(number, int_type, read_offset, should_byteswap)


@pytest.mark.slow
@pytest.mark.filterwarnings("ignore:overflow encountered:RuntimeWarning")
@given(read_offset=st.integers(0, 11), number=st.floats())
@pytest.mark.parametrize("float_type", [np.float32, np.float64])
Expand Down
3 changes: 1 addition & 2 deletions pandas/tests/scalar/timedelta/methods/test_round.py
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,6 @@ def test_round_invalid(self):
with pytest.raises(ValueError, match=msg):
t1.round(freq)

@pytest.mark.skip_ubsan
def test_round_implementation_bounds(self):
# See also: analogous test for Timestamp
# GH#38964
Expand All @@ -89,7 +88,7 @@ def test_round_implementation_bounds(self):
with pytest.raises(OutOfBoundsTimedelta, match=msg):
Timedelta.max.round("s")

@pytest.mark.skip_ubsan
@pytest.mark.slow
@given(val=st.integers(min_value=iNaT + 1, max_value=lib.i8max))
@pytest.mark.parametrize(
"method", [Timedelta.round, Timedelta.floor, Timedelta.ceil]
Expand Down
1 change: 0 additions & 1 deletion pandas/tests/scalar/timedelta/test_arithmetic.py
Original file line number Diff line number Diff line change
Expand Up @@ -969,7 +969,6 @@ def test_td_op_timedelta_timedeltalike_array(self, op, arr):


class TestTimedeltaComparison:
@pytest.mark.skip_ubsan
def test_compare_pytimedelta_bounds(self):
# GH#49021 don't overflow on comparison with very large pytimedeltas

Expand Down
2 changes: 1 addition & 1 deletion pandas/tests/scalar/timedelta/test_timedelta.py
Original file line number Diff line number Diff line change
Expand Up @@ -587,7 +587,7 @@ def test_timedelta_hash_equality(self):
ns_td = Timedelta(1, "ns")
assert hash(ns_td) != hash(ns_td.to_pytimedelta())

@pytest.mark.skip_ubsan
@pytest.mark.slow
@pytest.mark.xfail(
reason="pd.Timedelta violates the Python hash invariant (GH#44504).",
)
Expand Down
1 change: 1 addition & 0 deletions pandas/tests/scalar/timestamp/methods/test_round.py
Original file line number Diff line number Diff line change
Expand Up @@ -288,6 +288,7 @@ def test_round_implementation_bounds(self):
with pytest.raises(OutOfBoundsDatetime, match=msg):
Timestamp.max.round("s")

@pytest.mark.slow
@given(val=st.integers(iNaT + 1, lib.i8max))
@pytest.mark.parametrize(
"method", [Timestamp.round, Timestamp.floor, Timestamp.ceil]
Expand Down
1 change: 0 additions & 1 deletion pandas/tests/scalar/timestamp/methods/test_tz_localize.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@


class TestTimestampTZLocalize:
@pytest.mark.skip_ubsan
def test_tz_localize_pushes_out_of_bounds(self):
# GH#12677
# tz_localize that pushes away from the boundary is OK
Expand Down
1 change: 0 additions & 1 deletion pandas/tests/scalar/timestamp/test_constructors.py
Original file line number Diff line number Diff line change
Expand Up @@ -843,7 +843,6 @@ def test_barely_out_of_bounds(self):
with pytest.raises(OutOfBoundsDatetime, match=msg):
Timestamp("2262-04-11 23:47:16.854775808")

@pytest.mark.skip_ubsan
def test_bounds_with_different_units(self):
out_of_bounds_dates = ("1677-09-21", "2262-04-12")

Expand Down
1 change: 1 addition & 0 deletions pandas/tests/scalar/timestamp/test_timestamp.py
Original file line number Diff line number Diff line change
Expand Up @@ -240,6 +240,7 @@ def test_dow_historic(self, date_string, expected):
dow = ts.weekday()
assert dow == expected

@pytest.mark.slow
@given(
ts=st.datetimes(),
sign=st.sampled_from(["-", ""]),
Expand Down
1 change: 0 additions & 1 deletion pandas/tests/tools/test_to_datetime.py
Original file line number Diff line number Diff line change
Expand Up @@ -1129,7 +1129,6 @@ def test_to_datetime_dt64s_out_of_ns_bounds(self, cache, dt, errors):
assert ts.unit == "s"
assert ts.asm8 == dt

@pytest.mark.skip_ubsan
def test_to_datetime_dt64d_out_of_bounds(self, cache):
dt64 = np.datetime64(np.iinfo(np.int64).max, "D")

Expand Down
2 changes: 2 additions & 0 deletions pandas/tests/tseries/offsets/test_offsets_properties.py
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@
# Offset-specific behaviour tests


@pytest.mark.slow
@pytest.mark.arm_slow
@given(DATETIME_JAN_1_1900_OPTIONAL_TZ, YQM_OFFSET)
def test_on_offset_implementations(dt, offset):
Expand Down Expand Up @@ -57,6 +58,7 @@ def test_on_offset_implementations(dt, offset):
assert offset.is_on_offset(dt) == (compare == dt)


@pytest.mark.slow
@given(YQM_OFFSET)
def test_shift_across_dst(offset):
# GH#18319 check that 1) timezone is correctly normalized and
Expand Down
2 changes: 2 additions & 0 deletions pandas/tests/tseries/offsets/test_ticks.py
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,7 @@ def test_delta_to_tick():
assert tick == Nano(5)


@pytest.mark.slow
@pytest.mark.parametrize("cls", tick_classes)
@example(n=2, m=3)
@example(n=800, m=300)
Expand All @@ -80,6 +81,7 @@ def test_tick_add_sub(cls, n, m):
assert left - right == expected


@pytest.mark.slow
@pytest.mark.arm_slow
@pytest.mark.parametrize("cls", tick_classes)
@example(n=2, m=3)
Expand Down
1 change: 1 addition & 0 deletions pandas/tests/tslibs/test_ccalendar.py
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,7 @@ def test_dt_correct_iso_8601_year_week_and_day(input_date_tuple, expected_iso_tu
assert result == expected_iso_tuple


@pytest.mark.slow
@given(DATETIME_IN_PD_TIMESTAMP_RANGE_NO_TZ)
def test_isocalendar(dt):
expected = dt.isocalendar()
Expand Down
1 change: 1 addition & 0 deletions pandas/tests/tslibs/test_parsing.py
Original file line number Diff line number Diff line change
Expand Up @@ -388,6 +388,7 @@ def _helper_hypothesis_delimited_date(call, date_string, **kwargs):
return msg, result


@pytest.mark.slow
@given(DATETIME_NO_TZ)
@pytest.mark.parametrize("delimiter", list(" -./"))
@pytest.mark.parametrize("dayfirst", [True, False])
Expand Down
1 change: 0 additions & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -485,7 +485,6 @@ markers = [
"db: tests requiring a database (mysql or postgres)",
"clipboard: mark a pd.read_clipboard test",
"arm_slow: mark a test as slow for arm64 architecture",
"skip_ubsan: Tests known to fail UBSAN check",
# TODO: someone should investigate this ...
# these tests only fail in the wheel builder and don't fail in regular
# ARM CI
Expand Down
Loading