Skip to content

Add continuous integration testing#36

Merged
hdrake merged 6 commits intomainfrom
add-tests
Feb 24, 2026
Merged

Add continuous integration testing#36
hdrake merged 6 commits intomainfrom
add-tests

Conversation

@hdrake
Copy link
Owner

@hdrake hdrake commented Feb 24, 2026

This pull request introduces several improvements and fixes across the codebase, focusing on enhanced CI support, compatibility, and improved testing. The most significant changes are the addition of a CI workflow for multi-version Python testing, improved handling of bin types in the mass budget calculation, and new synthetic tests for the budget module.

Continuous Integration and Compatibility:

  • Added a new GitHub Actions CI workflow (.github/workflows/ci.yml) to test across Python versions 3.11–3.14, including Conda environment setup and pytest execution.
  • Updated ci/environment.yml to support Python versions >=3.11, improving compatibility with the new CI matrix.

Testing Enhancements:

  • Introduced a synthetic dataset and grid, along with a new test (test_mass_budget) in xwmb/tests/test_budget.py to validate mass budget calculations using the new bin handling.

Functionality Improvements:

  • Updated mass_budget in xwmb/budget.py to accept xr.DataArray as bins, enhancing flexibility in input types.

Dependency and Version Updates:

  • Bumped xwmt dependency to version >=0.2.0 in pyproject.toml for improved compatibility.
  • Updated package version to 0.5.7 in xwmb/version.py.

In the process of writing this test, I uncovered several places
where there is unnecessary friction in applying the package
to very simple examples. This test should be used to expand
testing coverage to all options of the keyword arguments in order
to find remaining bugs!
@hdrake
Copy link
Owner Author

hdrake commented Feb 24, 2026

This starts to address #13, although we should have much better coverage.

@hdrake hdrake marked this pull request as ready for review February 24, 2026 23:59
@hdrake hdrake merged commit ddf58fa into main Feb 24, 2026
4 checks passed
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