diff --git a/dev-packages/node-integration-tests/suites/contextLines/memory-leak/test.ts b/dev-packages/node-integration-tests/suites/contextLines/memory-leak/test.ts index 0ec5ea95e896..c58a727e1f30 100644 --- a/dev-packages/node-integration-tests/suites/contextLines/memory-leak/test.ts +++ b/dev-packages/node-integration-tests/suites/contextLines/memory-leak/test.ts @@ -1,4 +1,5 @@ import { cleanupChildProcesses, createRunner } from '../../../utils/runner'; +import { describe, afterAll, test } from 'vitest'; describe('ContextLines integration in CJS', () => { afterAll(() => { @@ -6,11 +7,12 @@ describe('ContextLines integration in CJS', () => { }); // Regression test for: https://github.com/getsentry/sentry-javascript/issues/14892 - test('does not leak open file handles', done => { - createRunner(__dirname, 'scenario.ts') + test('does not leak open file handles', async () => { + await createRunner(__dirname, 'scenario.ts') .expectN(10, { event: {}, }) - .start(done); + .start() + .completed(); }); }); diff --git a/dev-packages/node-integration-tests/suites/express-v5/multiple-routers/complex-router/test.ts b/dev-packages/node-integration-tests/suites/express-v5/multiple-routers/complex-router/test.ts index 30d1e6d0a6bc..921017909498 100644 --- a/dev-packages/node-integration-tests/suites/express-v5/multiple-routers/complex-router/test.ts +++ b/dev-packages/node-integration-tests/suites/express-v5/multiple-routers/complex-router/test.ts @@ -1,4 +1,4 @@ -import { afterAll, test } from 'vitest'; +import { afterAll, test, describe } from 'vitest'; import { cleanupChildProcesses, createRunner } from '../../../../utils/runner'; afterAll(() => { diff --git a/dev-packages/node-integration-tests/suites/tracing/apollo-graphql/useOperationNameForRootSpan/test.ts b/dev-packages/node-integration-tests/suites/tracing/apollo-graphql/useOperationNameForRootSpan/test.ts index 234cc4009b38..4aa7616cc73c 100644 --- a/dev-packages/node-integration-tests/suites/tracing/apollo-graphql/useOperationNameForRootSpan/test.ts +++ b/dev-packages/node-integration-tests/suites/tracing/apollo-graphql/useOperationNameForRootSpan/test.ts @@ -1,4 +1,5 @@ import { createRunner } from '../../../../utils/runner'; +import { describe, test, expect } from 'vitest' // Graphql Instrumentation emits some spans by default on server start const EXPECTED_START_SERVER_TRANSACTION = { @@ -6,7 +7,7 @@ const EXPECTED_START_SERVER_TRANSACTION = { }; describe('GraphQL/Apollo Tests > useOperationNameForRootSpan', () => { - test('useOperationNameForRootSpan works with single query operation', done => { + test('useOperationNameForRootSpan works with single query operation', async () => { const EXPECTED_TRANSACTION = { transaction: 'GET /test-graphql (query GetHello)', spans: expect.arrayContaining([ @@ -24,13 +25,14 @@ describe('GraphQL/Apollo Tests > useOperationNameForRootSpan', () => { ]), }; - createRunner(__dirname, 'scenario-query.js') + await createRunner(__dirname, 'scenario-query.js') .expect({ transaction: EXPECTED_START_SERVER_TRANSACTION }) .expect({ transaction: EXPECTED_TRANSACTION }) - .start(done); + .start() + .completed(); }); - test('useOperationNameForRootSpan works with single mutation operation', done => { + test('useOperationNameForRootSpan works with single mutation operation', async () => { const EXPECTED_TRANSACTION = { transaction: 'GET /test-graphql (mutation TestMutation)', spans: expect.arrayContaining([ @@ -50,13 +52,14 @@ describe('GraphQL/Apollo Tests > useOperationNameForRootSpan', () => { ]), }; - createRunner(__dirname, 'scenario-mutation.js') + await createRunner(__dirname, 'scenario-mutation.js') .expect({ transaction: EXPECTED_START_SERVER_TRANSACTION }) .expect({ transaction: EXPECTED_TRANSACTION }) - .start(done); + .start() + .completed(); }); - test('useOperationNameForRootSpan ignores an invalid root span', done => { + test('useOperationNameForRootSpan ignores an invalid root span', async () => { const EXPECTED_TRANSACTION = { transaction: 'test span name', spans: expect.arrayContaining([ @@ -74,13 +77,14 @@ describe('GraphQL/Apollo Tests > useOperationNameForRootSpan', () => { ]), }; - createRunner(__dirname, 'scenario-invalid-root-span.js') + await createRunner(__dirname, 'scenario-invalid-root-span.js') .expect({ transaction: EXPECTED_START_SERVER_TRANSACTION }) .expect({ transaction: EXPECTED_TRANSACTION }) - .start(done); + .start() + .completed(); }); - test('useOperationNameForRootSpan works with single query operation without name', done => { + test('useOperationNameForRootSpan works with single query operation without name', async () => { const EXPECTED_TRANSACTION = { transaction: 'GET /test-graphql (query)', spans: expect.arrayContaining([ @@ -97,13 +101,14 @@ describe('GraphQL/Apollo Tests > useOperationNameForRootSpan', () => { ]), }; - createRunner(__dirname, 'scenario-no-operation-name.js') + await createRunner(__dirname, 'scenario-no-operation-name.js') .expect({ transaction: EXPECTED_START_SERVER_TRANSACTION }) .expect({ transaction: EXPECTED_TRANSACTION }) - .start(done); + .start() + .completed(); }); - test('useOperationNameForRootSpan works with multiple query operations', done => { + test('useOperationNameForRootSpan works with multiple query operations', async () => { const EXPECTED_TRANSACTION = { transaction: 'GET /test-graphql (query GetHello, query GetWorld)', spans: expect.arrayContaining([ @@ -132,21 +137,23 @@ describe('GraphQL/Apollo Tests > useOperationNameForRootSpan', () => { ]), }; - createRunner(__dirname, 'scenario-multiple-operations.js') + await createRunner(__dirname, 'scenario-multiple-operations.js') .expect({ transaction: EXPECTED_START_SERVER_TRANSACTION }) .expect({ transaction: EXPECTED_TRANSACTION }) - .start(done); + .start() + .completed(); }); - test('useOperationNameForRootSpan works with more than 5 query operations', done => { + test('useOperationNameForRootSpan works with more than 5 query operations', async () => { const EXPECTED_TRANSACTION = { transaction: 'GET /test-graphql (query GetHello1, query GetHello2, query GetHello3, query GetHello4, query GetHello5, +4)', }; - createRunner(__dirname, 'scenario-multiple-operations-many.js') + await createRunner(__dirname, 'scenario-multiple-operations-many.js') .expect({ transaction: EXPECTED_START_SERVER_TRANSACTION }) .expect({ transaction: EXPECTED_TRANSACTION }) - .start(done); + .start() + .completed(); }); }); diff --git a/dev-packages/node-integration-tests/utils/assertions.ts b/dev-packages/node-integration-tests/utils/assertions.ts index 1d4e7d1b321a..4197c4a70844 100644 --- a/dev-packages/node-integration-tests/utils/assertions.ts +++ b/dev-packages/node-integration-tests/utils/assertions.ts @@ -8,6 +8,7 @@ import type { SessionAggregates, TransactionEvent, } from '@sentry/core'; +import { expect } from 'vitest'; /** * Asserts against a Sentry Event ignoring non-deterministic properties diff --git a/dev-packages/node-integration-tests/utils/index.ts b/dev-packages/node-integration-tests/utils/index.ts index b51a0a8f83c8..bf1086d82a8f 100644 --- a/dev-packages/node-integration-tests/utils/index.ts +++ b/dev-packages/node-integration-tests/utils/index.ts @@ -1,6 +1,7 @@ import type * as http from 'http'; import { parseSemver } from '@sentry/core'; import type { EnvelopeItemType } from '@sentry/core'; +import { describe } from 'vitest'; const NODE_VERSION = parseSemver(process.versions.node).major; @@ -31,9 +32,8 @@ export type DataCollectorOptions = { * Returns`describe` or `describe.skip` depending on allowed major versions of Node. * * @param {{ min?: number; max?: number }} allowedVersion - * @return {*} {jest.Describe} */ -export const conditionalTest = (allowedVersion: { min?: number; max?: number }): jest.Describe => { +export function conditionalTest(allowedVersion: { min?: number; max?: number }): typeof describe | typeof describe.skip{ if (!NODE_VERSION) { return describe.skip; } @@ -41,7 +41,7 @@ export const conditionalTest = (allowedVersion: { min?: number; max?: number }): return NODE_VERSION < (allowedVersion.min || -Infinity) || NODE_VERSION > (allowedVersion.max || Infinity) ? describe.skip : describe; -}; +} /** * Parses response body containing an Envelope diff --git a/packages/astro/test/server/index.server.test.ts b/packages/astro/test/server/index.server.test.ts index f319ef90eaad..4a89ebe16a13 100644 --- a/packages/astro/test/server/index.server.test.ts +++ b/packages/astro/test/server/index.server.test.ts @@ -1,4 +1,6 @@ +import { describe, expect, it } from 'vitest'; import sentryAstro from '../../src/index.server'; + describe('server SDK', () => { it('exports the astro integration as a default export', () => { const integration = sentryAstro(); diff --git a/packages/astro/test/server/sdk.test.ts b/packages/astro/test/server/sdk.test.ts index 3e571628d29f..ee3808204f5b 100644 --- a/packages/astro/test/server/sdk.test.ts +++ b/packages/astro/test/server/sdk.test.ts @@ -1,6 +1,6 @@ import * as SentryNode from '@sentry/node'; import { SDK_VERSION } from '@sentry/node'; -import { vi } from 'vitest'; +import { vi, describe, afterEach, expect, it } from 'vitest'; import { init } from '../../src/server/sdk'; diff --git a/packages/browser-utils/test/browser/browserMetrics.test.ts b/packages/browser-utils/test/browser/browserMetrics.test.ts index 27d489eae140..69169e01af67 100644 --- a/packages/browser-utils/test/browser/browserMetrics.test.ts +++ b/packages/browser-utils/test/browser/browserMetrics.test.ts @@ -9,6 +9,8 @@ import { spanToJSON, } from '@sentry/core'; import type { Span } from '@sentry/core'; +import { describe, beforeEach, it, expect, beforeAll, afterAll } from 'vitest'; + import { _addMeasureSpans, _addResourceSpans } from '../../src/metrics/browserMetrics'; import { WINDOW } from '../../src/types'; import { TestClient, getDefaultClientOptions } from '../utils/TestClient'; diff --git a/packages/browser-utils/test/browser/utils.test.ts b/packages/browser-utils/test/browser/utils.test.ts index 01fb5da605c4..9d8a6c301e84 100644 --- a/packages/browser-utils/test/browser/utils.test.ts +++ b/packages/browser-utils/test/browser/utils.test.ts @@ -1,4 +1,6 @@ import { SentrySpan, getCurrentScope, getIsolationScope, setCurrentClient, spanToJSON } from '@sentry/core'; +import { describe, beforeEach, it, expect, test } from 'vitest'; + import { extractNetworkProtocol, startAndEndSpan } from '../../src/metrics/utils'; import { TestClient, getDefaultClientOptions } from '../utils/TestClient'; diff --git a/packages/browser-utils/test/instrument/dom.test.ts b/packages/browser-utils/test/instrument/dom.test.ts index 102c6ba40829..a2c2a12dbf16 100644 --- a/packages/browser-utils/test/instrument/dom.test.ts +++ b/packages/browser-utils/test/instrument/dom.test.ts @@ -1,3 +1,5 @@ +import { describe, expect, it } from 'vitest'; + import { instrumentDOM } from '../../src/instrument/dom'; import { WINDOW } from '../../src/types'; diff --git a/packages/browser-utils/test/instrument/xhr.test.ts b/packages/browser-utils/test/instrument/xhr.test.ts index e53999de628b..352cce016fcb 100644 --- a/packages/browser-utils/test/instrument/xhr.test.ts +++ b/packages/browser-utils/test/instrument/xhr.test.ts @@ -1,3 +1,5 @@ +import { describe, expect, it } from 'vitest'; + import { instrumentXHR } from '../../src/instrument/xhr'; import { WINDOW } from '../../src/types'; diff --git a/packages/browser/test/sdk.test.ts b/packages/browser/test/sdk.test.ts index a6fc49edee89..6f8bdc66f450 100644 --- a/packages/browser/test/sdk.test.ts +++ b/packages/browser/test/sdk.test.ts @@ -4,7 +4,7 @@ /* eslint-disable @typescript-eslint/unbound-method */ import type { Mock } from 'vitest'; -import { afterEach, beforeEach, describe, expect, it, vi } from 'vitest'; +import { afterEach, beforeEach, describe, expect, it, vi, afterAll, test } from 'vitest'; import * as SentryCore from '@sentry/core'; import { createTransport } from '@sentry/core'; diff --git a/packages/browser/test/tracing/request.test.ts b/packages/browser/test/tracing/request.test.ts index 67cd96ee6717..717452a4dff0 100644 --- a/packages/browser/test/tracing/request.test.ts +++ b/packages/browser/test/tracing/request.test.ts @@ -1,5 +1,5 @@ import type { MockInstance } from 'vitest'; -import { beforeAll, beforeEach, describe, expect, it, vi } from 'vitest'; +import { beforeAll, beforeEach, describe, expect, it, vi, afterEach } from 'vitest'; import * as browserUtils from '@sentry-internal/browser-utils'; import * as utils from '@sentry/core'; diff --git a/packages/browser/test/transports/offline.test.ts b/packages/browser/test/transports/offline.test.ts index 070d6623f967..7b1cd5ebf6dd 100644 --- a/packages/browser/test/transports/offline.test.ts +++ b/packages/browser/test/transports/offline.test.ts @@ -1,4 +1,4 @@ -import { describe, expect, it } from 'vitest'; +import { describe, expect, it, beforeAll } from 'vitest'; import 'fake-indexeddb/auto'; diff --git a/packages/browser/test/utils/featureFlags.test.ts b/packages/browser/test/utils/featureFlags.test.ts index 48d2f20e3c91..39681a6dfe1f 100644 --- a/packages/browser/test/utils/featureFlags.test.ts +++ b/packages/browser/test/utils/featureFlags.test.ts @@ -1,7 +1,7 @@ import type { FeatureFlag } from '@sentry/core'; import { getCurrentScope, logger } from '@sentry/core'; -import { vi } from 'vitest'; +import { vi, describe, it, afterEach, expect } from 'vitest'; import { insertFlagToScope, insertToFlagBuffer } from '../../src/utils/featureFlags'; describe('flags', () => { diff --git a/packages/core/test/utils-hoist/envelope.test.ts b/packages/core/test/utils-hoist/envelope.test.ts index f80244d3d34d..4a5264978e5f 100644 --- a/packages/core/test/utils-hoist/envelope.test.ts +++ b/packages/core/test/utils-hoist/envelope.test.ts @@ -7,7 +7,7 @@ import { spanToJSON, } from '@sentry/core'; import { SentrySpan } from '@sentry/core'; -import { describe, expect, it, test, vi } from 'vitest'; +import { describe, expect, it, test, vi, afterEach } from 'vitest'; import { getSentryCarrier } from '../../src/carrier'; import { addItemToEnvelope, diff --git a/packages/eslint-plugin-sdk/test/lib/rules/no-eq-empty.test.ts b/packages/eslint-plugin-sdk/test/lib/rules/no-eq-empty.test.ts index 9a4c4c5a2ed6..08cfbf8f10e4 100644 --- a/packages/eslint-plugin-sdk/test/lib/rules/no-eq-empty.test.ts +++ b/packages/eslint-plugin-sdk/test/lib/rules/no-eq-empty.test.ts @@ -1,5 +1,5 @@ import { RuleTester } from 'eslint'; -import { describe } from 'vitest'; +import { describe, test } from 'vitest'; // @ts-expect-error untyped module import rule from '../../../src/rules/no-eq-empty'; diff --git a/packages/feedback/test/core/getFeedback.test.ts b/packages/feedback/test/core/getFeedback.test.ts index d79d2176e1c2..ce5ad0444755 100644 --- a/packages/feedback/test/core/getFeedback.test.ts +++ b/packages/feedback/test/core/getFeedback.test.ts @@ -1,4 +1,4 @@ -import { vi, describe, it, expect } from 'vitest'; +import { vi, describe, it, expect, beforeEach } from 'vitest'; import { getCurrentScope } from '@sentry/core'; import { getFeedback } from '../../src/core/getFeedback'; diff --git a/packages/feedback/test/core/sendFeedback.test.ts b/packages/feedback/test/core/sendFeedback.test.ts index c150c35ab69b..37e552090782 100644 --- a/packages/feedback/test/core/sendFeedback.test.ts +++ b/packages/feedback/test/core/sendFeedback.test.ts @@ -1,7 +1,7 @@ /** * @vitest-environment jsdom */ -import { vi, describe, it, expect } from 'vitest'; +import { vi, describe, it, expect, beforeEach, afterAll } from 'vitest'; import { addBreadcrumb, diff --git a/packages/nestjs/test/integrations/nest.test.ts b/packages/nestjs/test/integrations/nest.test.ts index b7ad5c041616..f4b60dde05df 100644 --- a/packages/nestjs/test/integrations/nest.test.ts +++ b/packages/nestjs/test/integrations/nest.test.ts @@ -1,4 +1,4 @@ -import { beforeEach, describe, expect, it, vi } from 'vitest'; +import { beforeEach, describe, expect, it, vi, afterEach } from 'vitest'; import * as core from '@sentry/core'; import { isPatched } from '../../src/integrations/helpers'; diff --git a/packages/react/vite.config.ts b/packages/react/vite.config.ts index a5523c61f601..199c74df98ce 100644 --- a/packages/react/vite.config.ts +++ b/packages/react/vite.config.ts @@ -5,6 +5,7 @@ import baseConfig from '../../vite/vite.config'; export default defineConfig({ ...baseConfig, test: { + globals: true, ...baseConfig.test, }, }); diff --git a/packages/replay-internal/test.setup.ts b/packages/replay-internal/test.setup.ts index c7d1ffa8eb51..55c5bc1704e2 100644 --- a/packages/replay-internal/test.setup.ts +++ b/packages/replay-internal/test.setup.ts @@ -1,5 +1,5 @@ import { printDiffOrStringify } from 'jest-matcher-utils'; -import { vi } from 'vitest'; +import { vi, expect } from 'vitest'; import type { Mocked, MockedFunction } from 'vitest'; /* eslint-disable @typescript-eslint/no-unsafe-member-access */ diff --git a/packages/replay-internal/test/unit/util/logger.test.ts b/packages/replay-internal/test/unit/util/logger.test.ts index 0d349b15ee62..2334ad1d83e6 100644 --- a/packages/replay-internal/test/unit/util/logger.test.ts +++ b/packages/replay-internal/test/unit/util/logger.test.ts @@ -1,4 +1,4 @@ -import { beforeEach, describe, expect, it } from 'vitest'; +import { beforeEach, describe, expect, it, vi } from 'vitest'; import * as SentryCore from '@sentry/core'; import { logger as coreLogger } from '@sentry/core'; diff --git a/packages/solidstart/test/client/errorboundary.test.tsx b/packages/solidstart/test/client/errorboundary.test.tsx index 8ce4e31e89d2..1b7b0c27e69c 100644 --- a/packages/solidstart/test/client/errorboundary.test.tsx +++ b/packages/solidstart/test/client/errorboundary.test.tsx @@ -3,7 +3,7 @@ import type * as SentryBrowser from '@sentry/browser'; import { createTransport, getCurrentScope, setCurrentClient } from '@sentry/core'; import { render } from '@solidjs/testing-library'; import userEvent from '@testing-library/user-event'; -import { vi } from 'vitest'; +import { vi, describe, beforeEach, afterEach, it, expect } from 'vitest'; import { ErrorBoundary } from 'solid-js'; import { BrowserClient, withSentryErrorBoundary } from '../../src/client'; diff --git a/packages/solidstart/test/client/sdk.test.ts b/packages/solidstart/test/client/sdk.test.ts index dc0df6993b81..fccd95eba741 100644 --- a/packages/solidstart/test/client/sdk.test.ts +++ b/packages/solidstart/test/client/sdk.test.ts @@ -1,7 +1,7 @@ import { SDK_VERSION } from '@sentry/solid'; import * as SentrySolid from '@sentry/solid'; -import { vi } from 'vitest'; +import { vi, describe, beforeEach, it, expect } from 'vitest'; import { init as solidStartInit } from '../../src/client'; import { solidRouterBrowserTracingIntegration } from '../../src/client/solidrouter'; diff --git a/packages/solidstart/test/client/solidrouter.test.tsx b/packages/solidstart/test/client/solidrouter.test.tsx index 681b8d7b5ce7..bbb510186938 100644 --- a/packages/solidstart/test/client/solidrouter.test.tsx +++ b/packages/solidstart/test/client/solidrouter.test.tsx @@ -10,7 +10,7 @@ import { import type { MemoryHistory } from '@solidjs/router'; import { MemoryRouter, Navigate, Route, createMemoryHistory } from '@solidjs/router'; import { render } from '@solidjs/testing-library'; -import { vi } from 'vitest'; +import { vi, describe, it, beforeEach, expect } from 'vitest'; import { BrowserClient } from '../../src/client'; import { solidRouterBrowserTracingIntegration, withSentryRouterRouting } from '../../src/client/solidrouter'; diff --git a/packages/solidstart/test/server/errorboundary.test.tsx b/packages/solidstart/test/server/errorboundary.test.tsx index 0d97b6b17a0d..8e03a590db2d 100644 --- a/packages/solidstart/test/server/errorboundary.test.tsx +++ b/packages/solidstart/test/server/errorboundary.test.tsx @@ -3,7 +3,7 @@ import type * as SentryCore from '@sentry/core'; import { createTransport, getCurrentScope, setCurrentClient } from '@sentry/core'; import { render } from '@solidjs/testing-library'; import userEvent from '@testing-library/user-event'; -import { vi } from 'vitest'; +import { vi, describe, beforeEach, it, expect, afterEach } from 'vitest'; import { ErrorBoundary } from 'solid-js'; import { NodeClient, withSentryErrorBoundary } from '../../src/server'; diff --git a/packages/solidstart/test/server/middleware.test.ts b/packages/solidstart/test/server/middleware.test.ts index c1d6ff644b9d..079aa799659d 100644 --- a/packages/solidstart/test/server/middleware.test.ts +++ b/packages/solidstart/test/server/middleware.test.ts @@ -1,5 +1,5 @@ import * as SentryCore from '@sentry/core'; -import { beforeEach, describe, it, vi } from 'vitest'; +import { beforeEach, describe, it, vi, expect } from 'vitest'; import { sentryBeforeResponseMiddleware } from '../../src/server'; import type { ResponseMiddlewareResponse } from '../../src/server'; diff --git a/packages/solidstart/test/server/solidrouter.test.tsx b/packages/solidstart/test/server/solidrouter.test.tsx index 17b3f265a049..c28373bdabbc 100644 --- a/packages/solidstart/test/server/solidrouter.test.tsx +++ b/packages/solidstart/test/server/solidrouter.test.tsx @@ -1,7 +1,7 @@ import type { MemoryHistory } from '@solidjs/router'; import { MemoryRouter, Route, createMemoryHistory } from '@solidjs/router'; import { render } from '@solidjs/testing-library'; -import { vi } from 'vitest'; +import { vi, describe, expect, it } from 'vitest'; import { withSentryRouterRouting as withSentryClientRouterRouting } from '../../src/client/solidrouter'; import { withSentryRouterRouting as withSentryServerRouterRouting } from '../../src/server/solidrouter'; diff --git a/packages/solidstart/test/vite/buildInstrumentation.test.ts b/packages/solidstart/test/vite/buildInstrumentation.test.ts index 52378a668870..f6692479ec74 100644 --- a/packages/solidstart/test/vite/buildInstrumentation.test.ts +++ b/packages/solidstart/test/vite/buildInstrumentation.test.ts @@ -1,5 +1,5 @@ import type { UserConfig } from 'vite'; -import { describe, expect, it, vi } from 'vitest'; +import { describe, expect, it, vi, beforeEach } from 'vitest'; import { makeBuildInstrumentationFilePlugin } from '../../src/vite/buildInstrumentationFile'; const fsAccessMock = vi.fn(); diff --git a/packages/sveltekit/test/server/rewriteFramesIntegration.test.ts b/packages/sveltekit/test/server/rewriteFramesIntegration.test.ts index 1d5ca8d4d695..dafae17c318e 100644 --- a/packages/sveltekit/test/server/rewriteFramesIntegration.test.ts +++ b/packages/sveltekit/test/server/rewriteFramesIntegration.test.ts @@ -1,6 +1,7 @@ import { rewriteFramesIntegration } from '@sentry/browser'; import { basename } from '@sentry/core'; import type { Event, StackFrame } from '@sentry/core'; +import { describe, expect, it } from 'vitest'; import { rewriteFramesIteratee } from '../../src/server-common/rewriteFramesIntegration'; import type { GlobalWithSentryValues } from '../../src/vite/injectGlobalValues'; diff --git a/vite/vite.config.ts b/vite/vite.config.ts index 2717ad778e1d..a26454ad5712 100644 --- a/vite/vite.config.ts +++ b/vite/vite.config.ts @@ -5,7 +5,6 @@ export default defineConfig({ __DEBUG_BUILD__: true, }, test: { - globals: true, coverage: { enabled: true, reportsDirectory: './coverage',