fix: add shiftKey to keyboard reorder tests in ComfyHubExamplesStep

The component requires Shift+Arrow to reorder images (plain arrows move focus). Tests were missing shiftKey: true, causing false failures.

Amp-Thread-ID: https://ampcode.com/threads/T-019cf96f-a902-76aa-a3c1-34676b56182a
Co-authored-by: Amp <amp@ampcode.com>
This commit is contained in:
Alexander Brown
2026-03-16 18:47:00 -07:00
parent a82cead062
commit 2cf8e645db

View File

@@ -41,7 +41,7 @@ describe('ComfyHubExamplesStep', () => {
const wrapper = mountStep(createImages(3))
const tiles = wrapper.findAll('[role="listitem"]')
await tiles[1].trigger('keydown', { key: 'ArrowLeft' })
await tiles[1].trigger('keydown', { key: 'ArrowLeft', shiftKey: true })
const emitted = wrapper.emitted('update:exampleImages')
expect(emitted).toBeTruthy()
@@ -53,7 +53,7 @@ describe('ComfyHubExamplesStep', () => {
const wrapper = mountStep(createImages(3))
const tiles = wrapper.findAll('[role="listitem"]')
await tiles[1].trigger('keydown', { key: 'ArrowRight' })
await tiles[1].trigger('keydown', { key: 'ArrowRight', shiftKey: true })
const emitted = wrapper.emitted('update:exampleImages')
expect(emitted).toBeTruthy()