diff --git a/__tests__/Card.test.tsx.no b/__tests__/Card.test.tsx similarity index 100% rename from __tests__/Card.test.tsx.no rename to __tests__/Card.test.tsx diff --git a/jest.config.ts b/jest.config.ts index 04838b2..f9b193f 100644 --- a/jest.config.ts +++ b/jest.config.ts @@ -13,9 +13,9 @@ const config: Config = { coverageProvider: "v8", setupFilesAfterEnv: ['/jest.setup.ts'], testEnvironment: "jsdom", - transform: { - '^.+\\.(ts|tsx|js|jsx)$': 'babel-jest', - }, + // transform: { + // '^.+\\.(ts|tsx|js|jsx)$': 'babel-jest', + // }, moduleFileExtensions: [...defaults.moduleFileExtensions, 'ts', 'tsx', 'js', 'jsx'], }; diff --git a/jest.setup.ts b/jest.setup.ts index 7b0828b..2e44dbb 100644 --- a/jest.setup.ts +++ b/jest.setup.ts @@ -1 +1,14 @@ +import { jest } from '@jest/globals'; import '@testing-library/jest-dom'; +import mockedConfig from './bro.config.js' + +jest.mock('@brojs/cli', () => { + return { + getNavigations() { + return mockedConfig.navigations + }, + getNavigationsValue(key) { + return mockedConfig.navigations[key] + } + } +})