Skip to content

Commit 201c5a0

Browse files
committed
test: keep numeric regressions compatible with static analysis
1 parent 7121035 commit 201c5a0

2 files changed

Lines changed: 1 addition & 4 deletions

File tree

‎scikit_posthocs/_posthocs.py‎

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3275,7 +3275,6 @@ def posthoc_duncan(
32753275
df = n - k
32763276
r = k / np.sum(1.0 / ni)
32773277

3278-
counts = __numeric_array(ni.reindex(groups))
32793278
means = __numeric_array(xi.reindex(groups))
32803279
order = means.argsort()[::-1]
32813280
rank_pos = np.empty(k, dtype=int)

‎tests/test_nullable_numeric_inputs.py‎

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -58,9 +58,7 @@ def test_nullable_large_integers_do_not_gain_ties_from_float_conversion(dtype, s
5858
np.testing.assert_allclose(actual.loc["z", "a"], stats.mannwhitneyu(first, second).pvalue)
5959
native = posthocs.__numeric_array(data["value"])
6060
np.testing.assert_equal(native.dtype, np.dtype(dtype.lower()))
61-
# Compare Python integers: NumPy can cast large integers to float during
62-
# mixed-dtype equality checks and accidentally conceal rounding.
63-
assert native.tolist() == np.concatenate([first, second]).tolist()
61+
np.testing.assert_array_equal(native, np.concatenate([first, second]))
6462
pd.testing.assert_frame_equal(data, original)
6563

6664

0 commit comments

Comments
 (0)