summaryrefslogtreecommitdiffstats
path: root/Lib/test/test_enum.py
diff options
context:
space:
mode:
authorEthan Furman <ethan@stoneleaf.us>2022-07-18 20:56:21 (GMT)
committerGitHub <noreply@github.com>2022-07-18 20:56:21 (GMT)
commitbe84daf52aec7b963a743d0c2d66dbd175810803 (patch)
treec3c67c05291dc90d3057b178fed3562541ae93a6 /Lib/test/test_enum.py
parenteda2f90094731a7a1a30bc4a50a6c1bc050a4b2c (diff)
downloadcpython-be84daf52aec7b963a743d0c2d66dbd175810803.zip
cpython-be84daf52aec7b963a743d0c2d66dbd175810803.tar.gz
cpython-be84daf52aec7b963a743d0c2d66dbd175810803.tar.bz2
Revert "gh-93910: [Enum] restore member.member restriction while keeping performance boost (GH-94913)" (#94981)
This reverts commit 30f28ac296e506b336e0ab56c41422a53c36d0c2.
Diffstat (limited to 'Lib/test/test_enum.py')
-rw-r--r--Lib/test/test_enum.py7
1 files changed, 1 insertions, 6 deletions
diff --git a/Lib/test/test_enum.py b/Lib/test/test_enum.py
index 80834f2..4a42c73 100644
--- a/Lib/test/test_enum.py
+++ b/Lib/test/test_enum.py
@@ -2611,6 +2611,7 @@ class TestSpecial(unittest.TestCase):
self.assertEqual(Private._Private__corporal, 'Radar')
self.assertEqual(Private._Private__major_, 'Hoolihan')
+ @unittest.skip("Accessing all values retained for performance reasons, see GH-93910")
def test_exception_for_member_from_member_access(self):
with self.assertRaisesRegex(AttributeError, "<enum .Di.> member has no attribute .NO."):
class Di(Enum):
@@ -2618,12 +2619,6 @@ class TestSpecial(unittest.TestCase):
NO = 0
nope = Di.YES.NO
- def test_no_exception_for_overridden_member_from_member_access(self):
- class Di(Enum):
- YES = 1
- NO = 0
- Di.YES.NO = Di.NO
- nope = Di.YES.NO
def test_dynamic_members_with_static_methods(self):
#