Update enum to CPython 3.11.5 (#5074)

part of: #4564
This commit is contained in:
dvermd authored and GitHub committed 2023-10-03 22:32:38 +09:00
1 parent 5384a4766a
commit 0d0139b322
6 files changed
+4267 -1523

No files matched your search

+1 -1
View File
@@ -315,7 +315,7 @@ jobs:
with:
python-version: ${{ env.PYTHON_VERSION }}
- name: install ruff
run: python -m pip install ruff
run: python -m pip install ruff==0.0.291 # astral-sh/ruff#7778
- name: run python lint
run: ruff extra_tests wasm examples --exclude='./.*',./Lib,./vm/Lib,./benches/ --select=E9,F63,F7,F82 --show-source
- name: install prettier
Vendored
+1479 -449
View File
File diff suppressed because it is too large. Load diff
+2778 -1073
View File
File diff suppressed because it is too large. Load diff
+2
View File
@@ -2304,6 +2304,8 @@ class PatternReprTests(unittest.TestCase):
self.assertEqual(r[:30], "re.compile('Very long long lon")
self.assertEqual(r[-16:], ", re.IGNORECASE)")
# TODO: RUSTPYTHON
@unittest.expectedFailure
def test_flags_repr(self):
self.assertEqual(repr(re.I), "re.IGNORECASE")
self.assertEqual(repr(re.I|re.S|re.X),
+4
View File
@@ -1493,6 +1493,8 @@ class GeneralModuleTests(unittest.TestCase):
raise
self.assertRaises(TypeError, s.ioctl, socket.SIO_LOOPBACK_FAST_PATH, None)
# TODO: RUSTPYTHON, AssertionError: '2' != 'AddressFamily.AF_INET'
@unittest.expectedFailure
def testGetaddrinfo(self):
try:
socket.getaddrinfo('localhost', 80)
@@ -1799,6 +1801,8 @@ class GeneralModuleTests(unittest.TestCase):
nameinfo = socket.getnameinfo(sockaddr, socket.NI_NUMERICHOST | socket.NI_NUMERICSERV)
self.assertEqual(nameinfo, ('ff02::1de:c0:face:8d%' + str(ifindex), '1234'))
# TODO: RUSTPYTHON, AssertionError: '2' != 'AddressFamily.AF_INET'
@unittest.expectedFailure
def test_str_for_enums(self):
# Make sure that the AF_* and SOCK_* constants have enum-like string
# reprs.
+3
View File
@@ -1509,6 +1509,9 @@ class UnicodeTest(string_tests.CommonTest,
self.assertRaisesRegex(TypeError, '%x format: an integer is required, not PseudoFloat', operator.mod, '%x', pi),
self.assertRaises(TypeError, operator.mod, '%c', pi),
# TODO: RUSTPYTHON, AssertionError: '...15...' != '...Int.IDES...'
@unittest.expectedFailure
def test_formatting_with_enum(self):
# issue18780
import enum