tony · GitHub

@tony

@tony

@tony

@tony

@tony

tony marked this pull request as ready for review

February 23, 2025 19:06

sourcery-ai[bot]

@tony

@tony

@tony

tony deleted the test-refactor branch

February 23, 2025 19:20

tony added a commit that referenced this pull request

Feb 23, 2025

tony added a commit that referenced this pull request

Feb 23, 2025

@tony tony mentioned this pull request

Feb 25, 2025

Merged

tony added a commit that referenced this pull request

Feb 25, 2025
This PR completes the refactoring of test helpers started in PR #578 by removing direct imports from the `libtmux.test` root module. Users must now import from specific submodules like `libtmux.test.named` and `libtmux.test.constants`.
Improvements include:
- Enhanced `EnvironmentVarGuard` for more reliable environment variable handling
- Added comprehensive test suites for constants and environment utilities
- Improved code coverage with proper exclusion markers for type checking blocks
- Better docstrings and examples in the random module
These changes improve maintainability and robustness of test helpers that are used both internally and by downstream packages that depend on libtmux.

Read the original on github.com ↗