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

Improve utilities for structure comparison in tests #896

Merged
merged 8 commits into from
Oct 24, 2024

Conversation

gonzaponte
Copy link
Collaborator

@gonzaponte gonzaponte commented Oct 14, 2024

When a table or a dataframe comparion fails in a test, we don't get much information. This PR adds a bit of information to the failure to help identify their causes.

This branch is currently on top of #895, the corresponding commits will be removed before merging.

Closes #840

@gonzaponte gonzaponte marked this pull request as ready for review October 17, 2024 18:45
@gonzaponte gonzaponte requested a review from jwaiton October 17, 2024 18:45
@jwaiton
Copy link
Collaborator

jwaiton commented Oct 21, 2024

The code is self explanatory, adds beneficial structure to the comparison of two tables, and runs with no issues.

There seems to be no testing of the conditions in which the function assert_tables_equality() provides a False return in testing_utils_test.py. Would this be beneficial to add to make sure the function returns False when we desire it to?

@gonzaponte
Copy link
Collaborator Author

Added 3 tests.

Copy link
Collaborator

@jwaiton jwaiton left a comment

Choose a reason for hiding this comment

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

The code is self explanatory, adds beneficial structure to the comparison of two tables (or arrays), and runs with no issues. Good job!

@jwaiton jwaiton merged commit 086f111 into next-exp:master Oct 24, 2024
1 check passed
@gonzaponte gonzaponte deleted the improve-table-cmp branch October 25, 2024 10:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Improve error messages in assertions
2 participants