From 408c605001f3d1fbfbda6dda275c95d378df65a4 Mon Sep 17 00:00:00 2001 From: archipelago Date: Fri, 24 Jul 2026 04:42:52 -0400 Subject: [PATCH] =?UTF-8?q?test:=20LightningChannels=20mounts=20with=20Pin?= =?UTF-8?q?ia=20=E2=80=94=20panel=20setup=20now=20uses=20the=20tx-explorer?= =?UTF-8?q?=20store?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-Authored-By: Claude Fable 5 --- .../src/views/apps/__tests__/LightningChannels.test.ts | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/neode-ui/src/views/apps/__tests__/LightningChannels.test.ts b/neode-ui/src/views/apps/__tests__/LightningChannels.test.ts index 53adcc8a..fffb75b7 100644 --- a/neode-ui/src/views/apps/__tests__/LightningChannels.test.ts +++ b/neode-ui/src/views/apps/__tests__/LightningChannels.test.ts @@ -1,5 +1,6 @@ import { flushPromises, mount } from '@vue/test-utils' import { describe, expect, it, vi } from 'vitest' +import { createPinia } from 'pinia' import LightningChannels from '@/components/LightningChannelsPanel.vue' import { rpcClient } from '@/api/rpc-client' @@ -44,7 +45,11 @@ describe('LightningChannels', () => { total_outbound: 60_000, }) - const wrapper = mount(LightningChannels) + // The panel's setup pulls a Pinia store via useTxExplorer — mount with a + // fresh Pinia or setup throws before the first render. + const wrapper = mount(LightningChannels, { + global: { plugins: [createPinia()] }, + }) await flushPromises() expect(wrapper.text()).toContain('peer-pubkey')