Skip to content

test: trim component snapshots in favour of behaviour - #3505

Merged
setchy merged 1 commit into
mainfrom
test/component-snapshot-trim
Oct 25, 2026
Merged

setchy merged 1 commit into
mainfrom
test/component-snapshot-trim

Conversation

@setchy

@setchy setchy commented Oct 25, 2026 •

Copy link
Copy Markdown
Member

Summary

  • Replace the large NotificationRow snapshots with assertions for content, actions, and reference visibility. The reference now exposes a stable data-hidden state.
  • Replace the ReasonFilter snapshot with an assertion for every reason option, counting duplicate titles.
  • Replace the FilterSection snapshots with enabled/disabled checkbox assertions.
  • Replace the Sidebar snapshots with role-based control assertions and variant checks for notifications, focused mode, and highlighted filters.
  • Remove the now-unused snapshots.

Why

These snapshots were 4.5k lines of markup that changed on every styling tweak. The replacements assert the behaviour and contract the tests actually care about; visual regression still covers the rendered icons and layout.

Verification

  • pnpm test: 200 files, 1,968 tests passed
  • pnpm exec vp check --no-fmt: 465 files passed
  • Visual regression unaffected

Follow-up

NotificationFooter and the remaining filter-section snapshots can get the same treatment later.

@setchy
setchy requested a review from afonsojramos as a code owner October 25, 2026 13:58
@github-actions github-actions Bot added the test Enhancements to test coverage or quality label Oct 25, 2026
@setchy
setchy force-pushed the test/component-snapshot-trim branch from ccb6039 to 03d4606 Compare October 25, 2026 13:59
Replace the large NotificationRow, ReasonFilter, FilterSection, and Sidebar snapshots with content, option-count, enabled-state, and role assertions. Restore the removed sidebar icon-state coverage through notification and focused-mode variant assertions, and keep the notification reference and exit state on stable data attributes. Visual regression continues to cover the rendered icons.
@setchy
setchy force-pushed the test/component-snapshot-trim branch from 03d4606 to c3d2244 Compare October 25, 2026 14:05
@sonarqubecloud

Copy link
Copy Markdown

@setchy
setchy merged commit a116803 into main Oct 25, 2026
23 checks passed
@setchy
setchy deleted the test/component-snapshot-trim branch October 25, 2026 14:09
@github-actions github-actions Bot added this to the Release 7.11.0 milestone Oct 25, 2026
@github-actions

github-actions Bot commented Nov 5, 2026

Copy link
Copy Markdown
Contributor

🎉 This pull request is included in Gitify v8.0.0! 🎉

Downloads for macOS, Windows, and Linux are available on the release page.

Thanks for helping make Gitify better!

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

Labels

test Enhancements to test coverage or quality

Development

Successfully merging this pull request may close these issues.

1 participant