enso/app/ide-desktop/lib/dashboard/vitest.config.ts
Sergei Garin 55d43a3d8a
Rename Connector to Datalinks (#9948)
#### Tl;dr
Closes: enso-org/cloud-v2#1132
This PR renames Connector to Datalink

---

#### Test Plan:
Everything should work as before,  but instead of sending `connectorId` we send `dataLinkId` and endpoint now is `/datalink`

---
2024-05-20 08:45:55 +00:00

28 lines
774 B
TypeScript

/** @file Configuration for vitest. */
import * as url from 'node:url'
import * as vitestConfig from 'vitest/config'
import * as appConfig from 'enso-common/src/appConfig'
/* eslint-disable @typescript-eslint/naming-convention */
appConfig.loadTestEnvironmentVariables()
// @ts-expect-error This is required, otherwise importing node modules is broken.
// This is required for `datalinkSchema.test.ts`.
process.env.NODE_ENV = 'development'
const VITE_CONFIG = (await import('./vite.config')).default
export default vitestConfig.mergeConfig(
VITE_CONFIG,
vitestConfig.defineConfig({
test: {
environment: 'jsdom',
exclude: ['**/*.spec.{ts,tsx}'],
root: url.fileURLToPath(new URL('./', import.meta.url)),
restoreMocks: true,
},
})
)