Skip to content

Commit 879d8c4

Browse files
authored
[3.11] gh-115252: Fix test_enum with -OO mode (GH-115253) (#115279)
(cherry picked from commit 33f56b7) Co-authored-by: Nikita Sobolev <[email protected]>
1 parent b9e9003 commit 879d8c4

File tree

1 file changed

+15
-4
lines changed

1 file changed

+15
-4
lines changed

Lib/test/test_enum.py

Lines changed: 15 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4474,7 +4474,7 @@ class Color(enum.Enum)
44744474
Help on class Color in module %s:
44754475
44764476
class Color(enum.Enum)
4477-
| Color(value, names=None, *, module=None, qualname=None, type=None, start=1)
4477+
| Color(value, names=None, *, module=None, qualname=None, type=None, start=1, boundary=None)
44784478
|\x20\x20
44794479
| Method resolution order:
44804480
| Color
@@ -4483,11 +4483,11 @@ class Color(enum.Enum)
44834483
|\x20\x20
44844484
| Data and other attributes defined here:
44854485
|\x20\x20
4486-
| YELLOW = <Color.YELLOW: 3>
4486+
| CYAN = <Color.CYAN: 1>
44874487
|\x20\x20
44884488
| MAGENTA = <Color.MAGENTA: 2>
44894489
|\x20\x20
4490-
| CYAN = <Color.CYAN: 1>
4490+
| YELLOW = <Color.YELLOW: 3>
44914491
|\x20\x20
44924492
| ----------------------------------------------------------------------
44934493
| Data descriptors inherited from enum.Enum:
@@ -4497,7 +4497,18 @@ class Color(enum.Enum)
44974497
| value
44984498
|\x20\x20
44994499
| ----------------------------------------------------------------------
4500-
| Data descriptors inherited from enum.EnumType:
4500+
| Methods inherited from enum.EnumType:
4501+
|\x20\x20
4502+
| __contains__(member) from enum.EnumType
4503+
|\x20\x20
4504+
| __getitem__(name) from enum.EnumType
4505+
|\x20\x20
4506+
| __iter__() from enum.EnumType
4507+
|\x20\x20
4508+
| __len__() from enum.EnumType
4509+
|\x20\x20
4510+
| ----------------------------------------------------------------------
4511+
| Readonly properties inherited from enum.EnumType:
45014512
|\x20\x20
45024513
| __members__"""
45034514

0 commit comments

Comments
 (0)