-
Notifications
You must be signed in to change notification settings - Fork 1.4k
Update test.support from CPython 3.11.2 #4537
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
Lib/test/test_support.py
Outdated
| import_helper.import_module, "foo") | ||
|
|
||
| # TODO: RUSTPYTHON | ||
| @unittest.expectedFailure |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
broken due to #4540
Lib/test/test_support.py
Outdated
| support.check_syntax_error(self, "x=1") | ||
|
|
||
| # TODO: RUSTPYTHON | ||
| @unittest.expectedFailure |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
broken due to #4540
5ad9566 to
3e50134
Compare
3e50134 to
121a86d
Compare
Lib/test/test_support.py
Outdated
| # 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) |
There was a problem hiding this comment.
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)| # 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 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@itsankitkp This is probably what I was looking for in #4474.
| if _buggy_ucrt is None: | ||
| if(sys.platform == 'win32' and | ||
| locale.getdefaultlocale()[1] == 'cp65001' and | ||
| locale.getencoding() == 'cp65001' and |
There was a problem hiding this comment.
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.
121a86d to
994afe3
Compare
994afe3 to
7de0564
Compare
fanninpm
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM.
blockers
localelib, tests and Addlocale.getencoding#4155non-blockers
wasiinstead ofunknown#4539PYTHONSAFEPATH#4541