fix(desktop): import GatewayEvent type in the background.complete test
The salvaged test imported RpcEvent from @/types/hermes; main's event type lives in @hermes/shared as GatewayEvent.
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
import { act, cleanup } from '@testing-library/react'
|
||||
import { afterEach, beforeEach, describe, expect, it, vi } from 'vitest'
|
||||
|
||||
import type { RpcEvent } from '@/types/hermes'
|
||||
import type { GatewayEvent } from '@hermes/shared'
|
||||
|
||||
import { type MessageStreamHarness, renderMessageStream } from './test-harness'
|
||||
|
||||
@@ -14,7 +14,7 @@ function mountStream() {
|
||||
stream = renderMessageStream(SID)
|
||||
}
|
||||
|
||||
function emit(type: RpcEvent['type'], payload: RpcEvent['payload'] = {}, sessionId = SID) {
|
||||
function emit(type: GatewayEvent['type'], payload: GatewayEvent['payload'] = {}, sessionId = SID) {
|
||||
act(() => stream.handleEvent({ payload, session_id: sessionId, type }))
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user