Skip to content

Conversation

@tanii1125
Copy link
Contributor

@tanii1125 tanii1125 commented Dec 8, 2025

Summary of Changes-

This PR Modernize test assertions in testsuite\MDAnalysisTests\analysis\test_msd.py

Changes made-

  1. Replaced deprecated assert_almost_equal with assert_allclose using tolerances equivalent to the previous decimal keyword.
  2. Replaced scalar floating-point comparisons with pytest.approx() where appropriate.
  3. Cleaned up imports (removed unused deprecated functions).
  4. Ensured all updated assertions preserve original test behavior.

Thanks, and please let me know if any further adjustments are needed.


📚 Documentation preview 📚: https://mdanalysis--5171.org.readthedocs.build/en/5171/

@codecov
Copy link

codecov bot commented Dec 8, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 86.14%. Comparing base (bbcef1b) to head (4ad7959).

❗ There is a different number of reports uploaded between BASE (bbcef1b) and HEAD (4ad7959). Click for more details.

HEAD has 3 uploads less than BASE
Flag BASE (bbcef1b) HEAD (4ad7959)
5 2
Additional details and impacted files
@@             Coverage Diff             @@
##           develop    #5171      +/-   ##
===========================================
- Coverage    92.72%   86.14%   -6.59%     
===========================================
  Files          180      180              
  Lines        22472    22472              
  Branches      3188     3188              
===========================================
- Hits         20837    19358    -1479     
- Misses        1177     2660    +1483     
+ Partials       458      454       -4     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@tanii1125
Copy link
Contributor Author

I’m seeing 11 test failures after modernizing the assertions here, and I’m not fully sure what I’m missing.

I expected this to be a mechanical change, but it seems to affect behavior in some cases. I’ve looked through the failures and tried to trace the differences, but I may be misunderstanding something.

I’d really appreciate any pointers on what I should look at or whether this approach is flawed. Happy to revise or drop this if needed.

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.

1 participant