FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

gh-116622: Test updates for Android by mhsmith · Pull Request #117299 · python/cpython · GitHub

/ cpython Public

gh-116622: Test updates for Android - #117299

Merged
erlend-aasland merged 5 commits into
python:mainfrom
mhsmith:android-test-updates
Apr 5, 2024
Merged

gh-116622: Test updates for Android#117299
erlend-aasland merged 5 commits into
python:mainfrom
mhsmith:android-test-updates

Conversation

mhsmith commented Mar 27, 2024
edited by bedevere-app Bot
Loading

Copy link
Copy Markdown
Member

This PR fixes various Android test issues which I've discovered over the last few weeks.

Comment thread Lib/test/test_fcntl.py
Comment thread Lib/test/test_math.py
Comment on lines +2696 to 2700
@unittest.skipIf(
sys.platform.startswith(("freebsd", "wasi"))
or (sys.platform == "android" and platform.machine() == "x86_64"),
f"this platform doesn't implement IEE 754-2008 properly")
def test_fma_zero_result(self):

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

See discussion at #116667 (comment).

mhsmith commented Apr 4, 2024

Copy link
Copy Markdown
Member Author

@erlend-aasland: Are you able to review this PR? It's a continuation of the previous Android test updates from #115918.

erlend-aasland left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

LGTM, with some nits. BTW, last time I checked, the sys.platform.startswith idiom was still recommended practice. I'd prefer if we could follow that.

Comment thread Lib/test/test_os.py Outdated
# The Android testbed redirects the native stdout to a pipe,
# which returns a different error code.
known_errnos.append(errno.EACCES)
if (sys.platform == "win32") or (e.errno in known_errnos):

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

The parentheses are not needed.

mhsmith commented Apr 5, 2024

Copy link
Copy Markdown
Member Author

The parentheses are not needed.

Fixed.

last time I checked, the sys.platform.startswith idiom was still recommended practice

I actually updated the sys.platform documentation in #116215 (comment) to limit this recommendation to FreeBSD. Ever since Python 3.3, all other PEP 11-supported platforms have returned a fixed string without a version number.

Copy link
Copy Markdown
Contributor

@mhsmith, thanks for the heads-up, I missed that docs update (and I've must have looked at the 3.12 docs). Perhaps we should consider backporting that doc patch.

erlend-aasland enabled auto-merge (squash) April 5, 2024 20:54
erlend-aasland merged commit 1d3225a into python:main Apr 5, 2024
diegorusso pushed a commit to diegorusso/cpython that referenced this pull request Apr 17, 2024
- re-enable test_fcntl_64_bit on Linux aarch64, but disable it on all
  Android ABIs
- use support.setswitchinterval in all relevant tests
- skip test_fma_zero_result on Android x86_64
- accept EACCES when calling os.get_terminal_size on Android
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

skip news tests Tests in the Lib/test dir

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants


Back | FazBrowse Home | New Git URL