Skip to content

Refactor @Lie macro: extract helper functions and improve testability#164

Merged
ocots merged 3 commits intomainfrom
macro-lie
Mar 26, 2026
Merged

Refactor @Lie macro: extract helper functions and improve testability#164
ocots merged 3 commits intomainfrom
macro-lie

Conversation

@ocots
Copy link
Copy Markdown
Member

@ocots ocots commented Mar 26, 2026

  • Extract __is_mixed_usage() function to detect mixed Lie/Poisson brackets
  • Extract __parse_lie_args() function to parse keyword arguments
  • Extract __transform_lie_poisson_expression() function to transform expressions
  • Add comprehensive docstrings with examples for all helper functions
  • Add 40+ new tests covering all helper functions and error cases
  • Use CTBase.Exceptions.IncorrectArgument instead of ArgumentError
  • Qualify function calls with CTFlows. to avoid namespace conflicts
  • Simplify macro logic and improve maintainability
  • All tests pass: 223/223

- Extract __is_mixed_usage() function to detect mixed Lie/Poisson brackets
- Extract __parse_lie_args() function to parse keyword arguments
- Extract __transform_lie_poisson_expression() function to transform expressions
- Add comprehensive docstrings with examples for all helper functions
- Add 40+ new tests covering all helper functions and error cases
- Use CTBase.Exceptions.IncorrectArgument instead of ArgumentError
- Qualify function calls with CTFlows. to avoid namespace conflicts
- Simplify macro logic and improve maintainability
- All tests pass: 223/223
@codecov
Copy link
Copy Markdown

codecov bot commented Mar 26, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 94.58%. Comparing base (c75e770) to head (f152879).
⚠️ Report is 4 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #164      +/-   ##
==========================================
+ Coverage   94.35%   94.58%   +0.22%     
==========================================
  Files          15       15              
  Lines         585      591       +6     
==========================================
+ Hits          552      559       +7     
+ Misses         33       32       -1     

☔ 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.

@github-actions
Copy link
Copy Markdown
Contributor

github-actions bot commented Mar 26, 2026

Breakage test results
Date: 2026-03-26 17:29:02

Name Latest Stable
OptimalControl compat: v0.8.17-beta compat: v0.8.17-beta

@ocots ocots merged commit 8b5b7ea into main Mar 26, 2026
19 checks passed
@ocots ocots deleted the macro-lie branch March 26, 2026 17:33
@ocots ocots mentioned this pull request Apr 1, 2026
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