Skip to content

Move test helpers to dedicated module#125

Merged
fnattino merged 2 commits into
mainfrom
test-module
Jun 10, 2026
Merged

Move test helpers to dedicated module#125
fnattino merged 2 commits into
mainfrom
test-module

Conversation

@fnattino

@fnattino fnattino commented Jun 9, 2026

Copy link
Copy Markdown
Collaborator

As part of #124 I wanted to import some functions from utils.py to engine.py - this is currently not possible due to circular imports. With this PR I am only moving the test helper functions to a new module (test.py), so that circular imports are solved. I think this will also draw a clearer separation between utility functions actively used in diffwofost and functions used only to support tests.

@fnattino fnattino marked this pull request as ready for review June 9, 2026 14:30
@sonarqubecloud

sonarqubecloud Bot commented Jun 9, 2026

Copy link
Copy Markdown

@fnattino fnattino requested a review from SarahAlidoost June 9, 2026 19:43

@SarahAlidoost SarahAlidoost left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

As discussed, only please keep get_test_data and prepare_engine_input in utils as notebooks use them. Thanks! 👍

@fnattino

Copy link
Copy Markdown
Collaborator Author

As discussed, only please keep get_test_data and prepare_engine_input in utils as notebooks use them. Thanks! 👍

Unfortunately, this turns out not to help to solve the circular import issue. I will still move get_test_data and prepare_engine_input to test, and add an issue to update notebooks before releasing!

@fnattino fnattino merged commit cdb5cff into main Jun 10, 2026
11 checks passed
@fnattino fnattino deleted the test-module branch June 10, 2026 11:48
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.

2 participants