Update test.support from CPython 3.11.2 by youknowone · Pull Request #4537 · RustPython/RustPython
| import_helper.import_module, "foo") | ||
|
|
||
| # TODO: RUSTPYTHON | ||
| @unittest.expectedFailure |
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| support.check_syntax_error(self, "x=1") | ||
|
|
||
| # TODO: RUSTPYTHON | ||
| @unittest.expectedFailure |
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Comment on lines +702 to +706
| # TODO: RUSTPYTHON | ||
| @unittest.expectedFailure | ||
| def test_has_strftime_extensions(self): | ||
| if support.is_emscripten or sys.platform == "win32": | ||
| self.assertFalse(support.has_strftime_extensions) | ||
| else: | ||
| self.assertTrue(support.has_strftime_extensions) |
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
support.has_strftime_extensions will always be False when sys.platform == "win32".
I suggest using the os-dependent version:
def test_whatever(self): ... # TODO: RUSTPYTHON if sys.platform != "win32": # TODO: RUSTPYTHON test_whatever = unittest.expectedFailure(test_whatever)
Comment on lines +546 to +553
| # Does strftime() support glibc extension like '%4Y'? | ||
| has_strftime_extensions = False | ||
| if sys.platform != "win32": | ||
| # bpo-47037: Windows debug builds crash with "Debug Assertion Failed" | ||
| try: | ||
| has_strftime_extensions = time.strftime("%4Y") != "%4Y" | ||
| except ValueError: | ||
| pass |
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| if _buggy_ucrt is None: | ||
| if(sys.platform == 'win32' and | ||
| locale.getdefaultlocale()[1] == 'cp65001' and | ||
| locale.getencoding() == 'cp65001' and |
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is blocked on #4155.
CPython Devleopers and others added 3 commits
CPython Developers and others added 2 commits
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM.