Skip to content

Commit 0001ab9

Browse files
fix: unit tests
1 parent cbfaa03 commit 0001ab9

File tree

1 file changed

+8
-1
lines changed

1 file changed

+8
-1
lines changed

packages/kit/src/exports/hooks/sequence.spec.js

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,18 @@
11
import { assert, expect, test } from 'vitest';
22
import { sequence } from './sequence.js';
33
import { installPolyfills } from '../node/polyfills.js';
4+
import { EVENT_STATE } from '../../runtime/server/event-state.js';
45

56
installPolyfills();
67

78
const dummy_event = /** @type {import('@sveltejs/kit').RequestEvent} */ ({
8-
tracing: { root: {} }
9+
tracing: { root: {} },
10+
[EVENT_STATE]: {
11+
tracing: {
12+
// @ts-expect-error
13+
record_span: ({ fn }) => fn()
14+
}
15+
}
916
});
1017

1118
test('applies handlers in sequence', async () => {

0 commit comments

Comments
 (0)