Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Toolbox tests to GitHub actions? #358

Closed
soininen opened this issue Feb 12, 2024 · 3 comments
Closed

Add Toolbox tests to GitHub actions? #358

soininen opened this issue Feb 12, 2024 · 3 comments
Assignees
Labels
enhancement New feature or request

Comments

@soininen
Copy link
Collaborator

Toolbox uses spinedb_api heavily. It is quite possible that a change in spinedb_api breaks something in Toolbox even though the spinedb_api unit tests pass. We could add Toolbox unit tests as part of spinedb_api GitHub actions so there would be a check before PRs get merged to master. There is probably no need to run the entire test system matrix (Windows, Linux, all supported Python versions). Running the tests on a single system should suffice to give an early warning if something is broken. On that note, tests on Linux are generally faster.

@soininen soininen added enhancement New feature or request 0.8 labels Feb 12, 2024
@soininen
Copy link
Collaborator Author

Would it make sense to add SpineInterface tests to spinedb_api GitHub actions as well?

@manuelma
Copy link
Collaborator

I think so, they are also kinda quick...

Also, I have broken toolbox after modifying spine_engine so maybe we can also add toolbox tests to spine_engine CI workflow?

@soininen soininen self-assigned this Feb 12, 2024
soininen added a commit to spine-tools/Spine-Toolbox that referenced this issue Feb 12, 2024
This fixes deprecation warnings in GitHub actions due to some Node.js
version being phased out.

Re spine-tools/Spine-Database-API#358
soininen added a commit to spine-tools/spine-engine that referenced this issue Feb 12, 2024
This fixes deprecation warnings in GitHub actions due to some Node.js
version being phased out.

Re spine-tools/Spine-Database-API#358
soininen added a commit to spine-tools/Spine-Toolbox that referenced this issue Feb 13, 2024
Some tests in TestParameterValuePivotTableModel were failing due to
a timing issue. We need to wait for the Entity tree to finish fetching before
we can use it.

Re spine-tools/Spine-Database-API#358
soininen added a commit to spine-tools/Spine-Toolbox that referenced this issue Feb 13, 2024
Some tests in TestParameterValuePivotTableModel were failing due to
a timing issue. We need to wait for the Entity tree to finish fetching before
we can use it.

Re spine-tools/Spine-Database-API#358
soininen added a commit to spine-tools/Spine-Toolbox that referenced this issue Feb 13, 2024
@soininen
Copy link
Collaborator Author

I have now added Toolbox unit and execution tests to DB API repository. The test matrix includes only Linux + Python 3.8 which should be sufficient to see if something gets broken. The action is run on each push and we use the 0.8-dev branch on Toolbox. This might cause an issue when we are working on both repositories at the same time. I guess in that case a failing Toolbox unit test can be ignored and the author of the PR is responsible of running Toolbox tests manually.

I am not entirely happy that this introduces a "dependency" from DB API to Toolbox. The other option would have been to make pushes to DB API repository trigger GitHub actions in Toolbox repository but that seemed trickier to implement. It could be done later, if we feel like it, though.

For now, lets see how this works. If we find it useful, we can consider adding similar tests for SpineInterface (their tests do no pass at the time of writing, anyway) or SpineEngine -> Toolbox.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants