test: cover drag-reorder, per-editor validation, and a11y on stable stories#58
Merged
Conversation
…tories Three test-coverage additions backing the highest-leverage gaps identified when auditing the suite: - A drag-reorder play test in BlockKitchen exercises the headline @dnd-kit flow end-to-end (pointerDown → activation move → drop on target row), catching dnd-kit regressions on React/dep upgrades. - Per-editor play tests (Header, Markdown, Image) plus a shared helper assert that field edits produce payloads accepted by @tightknitai/slack-block-kit-validator, and the palette factory unit tests now validate every defaultPalette / legacy variant through the same path the runtime uses (toSlackBlocks → validateBlockKit). - a11y is flipped from "todo" to "error" on the stable stories (Button, Palette, Toolbar, TemplatePicker) so axe violations fail CI. vitest.config.ts inlines the validator package so its extension-less ESM imports route through Vite's resolver (Node's pure-ESM resolver rejects them); this is a workaround for an upstream packaging quirk, not a behavior change. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Contributor
Deploying with
|
| Status | Name | Latest Commit | Preview URL | Updated (UTC) |
|---|---|---|---|---|
| ✅ Deployment successful! View logs |
block-kitchen | 317a400 | Commit Preview URL Branch Preview URL |
May 16 2026, 05:21 PM |
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.
Summary
Adds the three highest-leverage testing gaps identified in the suite audit: end-to-end drag-reorder coverage, payload-level validation around the editor forms, and enforced a11y assertions on stable stories.
Why
The current suite catches type errors and core pure-function regressions, but leaves the most user-visible behaviors uncovered: dnd-kit dragging (zero tests, dep upgrades could silently break the headline UX), editor → Slack payload shape drift (factories validated to "has a type" but not to "Slack would accept it"), and a11y (`addon-a11y` installed but configured as `'todo'` everywhere). These additions are cheap, ride on the existing Storybook + Playwright/chromium infrastructure, and turn the validator dep that's already in production into a safety net.
What changed
Test plan
Notes for reviewer
🤖 Generated with Claude Code