Repository navigation
Conversation
…worker Since storytold#1493 a PDF dropped after the first frame is prepared on the open worker, while dropping_a_pdf_on_the_window_opens_it and files_dropped_outside_the_page_grid_still_open_as_documents still check for its tab after three frames. Under load the worker loses that race. Both tests are about where a drop goes, not about the worker, so they set run_inline, the switch tests already use for background jobs. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
7 tasks done
Contributor
Author
|
Closing this: #1914 already fixed both tests on |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What this changes
Two UI tests fail intermittently since #1493 moved preparing a PDF opened after the first frame
onto the open worker:
ui::dropping_a_pdf_on_the_window_opens_itfailed in 3 of 4 runs of theuisuite onmain(7437bde), on macOS, and also failed when run alone.
editing::files_dropped_outside_the_page_grid_still_open_as_documentsfails when theeditingsuite is busier. With one unrelated test added to the suite, it failed in 5 of 10runs.
Both tests drop a PDF and then check for its tab after three frames. The worker often isn't done
by then. #1493 kept startup and test flows inline ("this also preserves deterministic inline
startup and test flows"), but a drop arrives after the first frame, so these two tests ended up
on the worker.
The tests are about where a drop goes (a tab, not the page grid), not about the worker, which
open_worker_tests.rscovers. So both now setrun_inline, the switch documented forbackground jobs in tests and already used by several test setups. The drop then opens in the
same frame. This removes the race instead of waiting longer for it, and adds no time to the
suite.
Related: these are two of the UI test failures since #1493 that are listed in #1691. #1681
fixes another one with the same cause.
How you verified it
cargo fmt --check-D warningsonpdfcraft-ui-egui(--all-targets)Before and after, under the same conditions:
ui::dropping_a_pdf_on_the_window_opens_it(fulluisuite)editing::files_dropped_outside_the_page_grid_still_open_as_documents(fulleditingsuite plus one extra test)No other test changed result.