Skip to content

Commit eb00182

Browse files
authored
Merge pull request #7047 from bluetech/rm-test_assertion-abc
Remove some no-longer-needed compat code in test_assertion
2 parents 272be7e + 20956b2 commit eb00182

File tree

1 file changed

+3
-6
lines changed

1 file changed

+3
-6
lines changed

testing/test_assertion.py

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import collections.abc as collections_abc
1+
import collections.abc
22
import sys
33
import textwrap
44
from typing import Any
@@ -623,11 +623,8 @@ def test_frozenzet(self):
623623
assert len(expl) > 1
624624

625625
def test_Sequence(self):
626-
if not hasattr(collections_abc, "MutableSequence"):
627-
pytest.skip("cannot import MutableSequence")
628-
MutableSequence = collections_abc.MutableSequence
629-
630-
class TestSequence(MutableSequence): # works with a Sequence subclass
626+
# Test comparing with a Sequence subclass.
627+
class TestSequence(collections.abc.MutableSequence):
631628
def __init__(self, iterable):
632629
self.elements = list(iterable)
633630

0 commit comments

Comments
 (0)