-
Notifications
You must be signed in to change notification settings - Fork 6
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 CI, tox config and other test adjustments #3
Conversation
So if test requires dialogs then in pytest config there is a need to add new marker: and decorate this test with |
Codecov Report
@@ Coverage Diff @@
## main #3 +/- ##
=======================================
Coverage ? 90.56%
=======================================
Files ? 5
Lines ? 1166
Branches ? 0
=======================================
Hits ? 1056
Misses ? 110
Partials ? 0 |
The tests on
with
Is this a known bug, issue or limitation? Any workarounds? It looks like it might be a race condition? cc @goanpeca |
After discussing the issue with the team on the Europe community meeting, I've added the relevant What we are seeing now:
This one happens in:
No pattern is obvious, I might just crank the timeout a bit longer?
This one happens in:
Network error? |
With 1000ms of timeout, all Windows runners passed, but on macOS we observe timeouts on:
Maybe a bit more will fix it? The Python 3.10 and 3.11 errors were not present before, so I assume they are happening at random. |
Ok, finally green! 🚀 |
qtbot.add_widget(widget) | ||
qtbot.waitUntil(lambda: widget.available_list.count() >= 2, timeout=300) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Did we know how many entries we expect here? If the test ends before the thread yelding new plugin entries it may end with a crash whole test setup. We should wait until this thread ends working.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Also lambdas are sometimes funky in these tests, so using a separate function might be slightly better
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done :)
For reference. Bug pointed on community meeting also happens in the main repository https://github.com/napari/napari/actions/runs/4824544130/jobs/8594439707?pr=5784 |
Co-authored-by: Grzegorz Bokota <[email protected]>
Yay not feeling alone anymore :D |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Two small comments/changes. Everything else looks good.
Co-authored-by: Grzegorz Bokota <[email protected]>
Thanks for the super helpful review @Czaki! I learnt a lot about Qt, operating systems and event loops! |
I had not imported the full history in my previous attempt. Restarting here.
Supersedes #1