MCPcopy
hub / github.com/pandas-dev/pandas / test_union_nan_in_both

Function test_union_nan_in_both

pandas/tests/indexes/test_setops.py:627–633  ·  view source on GitHub ↗
(dup)

Source from the content-addressed store, hash-verified

625
626@pytest.mark.parametrize("dup", [1, np.nan])
627def test_union_nan_in_both(dup):
628 # GH#36289
629 a = Index([np.nan, 1, 2, 2])
630 b = Index([np.nan, dup, 1, 2])
631 result = a.union(b, sort=False)
632 expected = Index([np.nan, dup, 1.0, 2.0, 2.0])
633 tm.assert_index_equal(result, expected)
634
635
636def test_union_rangeindex_sort_true():

Callers

nothing calls this directly

Calls 2

unionMethod · 0.95
IndexClass · 0.90

Tested by

no test coverage detected