mirror of
https://github.com/pybind/pybind11.git
synced 2024-11-22 13:15:12 +00:00
Fix Python 3.8 test regression
This commit is contained in:
parent
e825205ac6
commit
21d0eb460f
@ -192,12 +192,15 @@ def test_binary_operators():
|
|||||||
|
|
||||||
|
|
||||||
def test_enum_to_int():
|
def test_enum_to_int():
|
||||||
m.test_enum_to_int(m.Flags.Read)
|
import sys
|
||||||
m.test_enum_to_int(m.ClassWithUnscopedEnum.EMode.EFirstMode)
|
# Implicit conversion to integers is deprecated in Python >= 3.8
|
||||||
m.test_enum_to_uint(m.Flags.Read)
|
if sys.version_info < (3, 8):
|
||||||
m.test_enum_to_uint(m.ClassWithUnscopedEnum.EMode.EFirstMode)
|
m.test_enum_to_int(m.Flags.Read)
|
||||||
m.test_enum_to_long_long(m.Flags.Read)
|
m.test_enum_to_int(m.ClassWithUnscopedEnum.EMode.EFirstMode)
|
||||||
m.test_enum_to_long_long(m.ClassWithUnscopedEnum.EMode.EFirstMode)
|
m.test_enum_to_uint(m.Flags.Read)
|
||||||
|
m.test_enum_to_uint(m.ClassWithUnscopedEnum.EMode.EFirstMode)
|
||||||
|
m.test_enum_to_long_long(m.Flags.Read)
|
||||||
|
m.test_enum_to_long_long(m.ClassWithUnscopedEnum.EMode.EFirstMode)
|
||||||
|
|
||||||
|
|
||||||
def test_duplicate_enum_name():
|
def test_duplicate_enum_name():
|
||||||
|
Loading…
Reference in New Issue
Block a user