Skip to content
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

Fix a few test failures on big-endian systems #46681

Merged
merged 2 commits into from Apr 7, 2022

Conversation

musicinmybrain
Copy link
Contributor

@musicinmybrain musicinmybrain commented Apr 7, 2022

These are all due to tests expecting little-endian dtypes, where in fact the endianness of the dtype is that of the host.

  • closes #xxxx (Replace xxxx with the Github issue number) No issue filed
  • Tests added and passed if fixing a bug or adding a new feature Not applicable; fixes some tests on big-endian platforms
  • All code checks passed.
  • Added an entry in the latest doc/source/whatsnew/vX.X.X.rst file if fixing a bug or adding a new feature.

@jreback jreback added Testing pandas testing functions or related to the test suite Compat pandas objects compatability with Numpy or Python functions labels Apr 7, 2022
These are all due to tests expecting little-endian dtypes, where in fact
the endianness of the dtype is that of the host.
Setting an ENDIAN constant here to represent the character for
host-endianness to use for numpy dtypes ("<" or ">") saves an import and
a little duplicated code across a number of test modules.
@musicinmybrain
Copy link
Contributor Author

The force push was to remove a stray from sys import byteorder left over from when I rebased this from v1.3.5 to main.

@jreback jreback added this to the 1.5 milestone Apr 7, 2022
Copy link
Contributor

@jreback jreback left a comment

Choose a reason for hiding this comment

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

lgtm thanks @musicinmybrain

@jreback jreback merged commit 40e9cbe into pandas-dev:main Apr 7, 2022
yehoshuadimarsky pushed a commit to yehoshuadimarsky/pandas that referenced this pull request Jul 13, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Compat pandas objects compatability with Numpy or Python functions Testing pandas testing functions or related to the test suite
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants