Skip to content

Self-hosted, Self-Improving, Federated Everything App — dev management, agent orchestration, persistent mind, digital twin, second brain, and creative pipeline from a single dashboard over Tailscale to port the user into the OS

fix: await async gallery load in flaky per-scene clip import test (#10232)

Adam Eivy08b54248b1d8
diff --git a/client/src/pages/MusicVideo.test.jsx b/client/src/pages/MusicVideo.test.jsx
index fb8fa33204..ffb5c7d1d4 100644
--- a/client/src/pages/MusicVideo.test.jsx
+++ b/client/src/pages/MusicVideo.test.jsx
@@ -2369,7 +2369,8 @@ describe('MusicVideo per-scene clip import (#8978)', () => {
fireEvent.click(await screen.findByRole('button', { name: /^Import clip take$/ }));
const dialog = await screen.findByRole('dialog', { name: /Pick a video from your gallery/i });
- fireEvent.click(within(dialog).getByText('(no prompt)').closest('.bg-port-card').querySelector('button'));
+ const galleryItem = await within(dialog).findByText('(no prompt)');
+ fireEvent.click(galleryItem.closest('.bg-port-card').querySelector('button'));
await waitFor(() => expect(addMusicVideoSceneTake).toHaveBeenCalledWith(
'mv-2', 's1', { kind: 'video', assetId: 'rh-9', source: 'imported' }, { silent: true },