Skip to content

Improve the find bar integration tests - #22069

Open
timvandermeij wants to merge 3 commits into
mozilla:masterfrom
timvandermeij:find-bar-coverage
Open

timvandermeij wants to merge 3 commits into
mozilla:masterfrom
timvandermeij:find-bar-coverage

Conversation

@timvandermeij

Copy link
Copy Markdown
Collaborator

The commit messages contain more details about the individual changes.

@codecov-commenter

codecov-commenter commented Oct 4, 2026 •

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 90.24%. Comparing base (f5e56f0) to head (4212096).

Additional details and impacted files
@@            Coverage Diff             @@
##           master   #22069      +/-   ##
==========================================
+ Coverage   90.23%   90.24%   +0.01%     
==========================================
  Files         277      277              
  Lines       67807    67807              
==========================================
+ Hits        61186    61195       +9     
+ Misses       6621     6612       -9     
Flag Coverage Δ
integrationtest 69.33% <ø> (+0.02%) ⬆️
unittestcli 58.25% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Harness.
📢 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.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

Comment thread test/integration/find_spec.mjs Outdated
Comment thread test/integration/find_spec.mjs Outdated
Comment thread test/integration/find_spec.mjs Outdated
Comment thread test/integration/find_spec.mjs
Comment thread test/integration/find_spec.mjs Outdated
@timvandermeij
timvandermeij force-pushed the find-bar-coverage branch 2 times, most recently from 3cf7746 to d9b38d7 Compare October 6, 2026 19:10
…tion tests

This refactoring makes the existing tests more compact/expressive, and
makes it easier to add more find bar tests in a next commit without
having to duplicate this logic more often.
This makes the test names more consistent to improve clarity on what the
tests aim to check, and avoids using duplicate test names to make
discovery of e.g. failed tests easier in the logs.
This commit brings code coverage for the `web/pdf_find_bar.js` file to
100% by covering all missing cases, which include:

- searching with no results;
- searching with multiple results;
- highlighting all search results using keyboard navigation;
- closing the find bar via the toolbar button and the Escape key.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants