Skip to content

Commit

Permalink
Remove some more tests
Browse files Browse the repository at this point in the history
  • Loading branch information
Daniel Saxton authored and Daniel Saxton committed Feb 3, 2020
1 parent 6991394 commit f6e9ce5
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 27 deletions.
11 changes: 0 additions & 11 deletions pandas/tests/arrays/categorical/test_indexing.py
Original file line number Diff line number Diff line change
Expand Up @@ -239,17 +239,6 @@ def test_mask_with_boolean(index):
tm.assert_series_equal(result, expected)


@pytest.mark.parametrize("index", [True, False])
def test_mask_with_boolean_raises(index):
s = Series(range(3))
idx = Categorical([True, False, None])
if index:
idx = CategoricalIndex(idx)

with pytest.raises(ValueError, match="NA / NaN"):
s[idx]


@pytest.fixture
def non_coercible_categorical(monkeypatch):
"""
Expand Down
16 changes: 0 additions & 16 deletions pandas/tests/extension/base/getitem.py
Original file line number Diff line number Diff line change
Expand Up @@ -158,22 +158,6 @@ def test_getitem_boolean_array_mask(self, data):
result = pd.Series(data)[mask]
self.assert_series_equal(result, expected)

def test_getitem_boolean_array_mask_raises(self, data):
mask = pd.array(np.zeros(data.shape, dtype="bool"), dtype="boolean")
mask[:2] = pd.NA

msg = (
"Cannot mask with a boolean indexer containing NA values|"
"cannot mask with array containing NA / NaN values"
)
with pytest.raises(ValueError, match=msg):
data[mask]

s = pd.Series(data)

with pytest.raises(ValueError):
s[mask]

@pytest.mark.parametrize(
"idx",
[[0, 1, 2], pd.array([0, 1, 2], dtype="Int64"), np.array([0, 1, 2])],
Expand Down

0 comments on commit f6e9ce5

Please sign in to comment.