Skip to content

Commit f579921

Browse files
committed
update some tests
1 parent 2abcd92 commit f579921

File tree

2 files changed

+2
-0
lines changed

2 files changed

+2
-0
lines changed

packages/react-router/test/server/instrumentation/reactRouterServer.test.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,7 @@ vi.mock('./util', async () => {
2828

2929
const mockSpan = {
3030
spanContext: () => ({ traceId: '1', spanId: '2', traceFlags: 1 }),
31+
setAttributes: vi.fn(),
3132
};
3233

3334
function createRequest(url: string, method = 'GET') {

packages/react-router/test/server/wrapSentryHandleRequest.test.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -70,6 +70,7 @@ describe('wrapSentryHandleRequest', () => {
7070
expect(getRootSpan).toHaveBeenCalledWith(mockActiveSpan);
7171
expect(mockRootSpan.setAttributes).toHaveBeenCalledWith({
7272
[ATTR_HTTP_ROUTE]: '/some-path',
73+
'sentry.custom-span-name': 'GET /some-path',
7374
[SEMANTIC_ATTRIBUTE_SENTRY_SOURCE]: 'route',
7475
});
7576
expect(mockRpcMetadata.route).toBe('/some-path');

0 commit comments

Comments
 (0)