init
Some checks failed
Node CI / build (14.x, macOS-latest) (push) Has been cancelled
Node CI / build (14.x, ubuntu-latest) (push) Has been cancelled
Node CI / build (14.x, windows-latest) (push) Has been cancelled
Node CI / build (16.x, macOS-latest) (push) Has been cancelled
Node CI / build (16.x, ubuntu-latest) (push) Has been cancelled
Node CI / build (16.x, windows-latest) (push) Has been cancelled
coverage CI / build (push) Has been cancelled
Node pnpm CI / build (16.x, macOS-latest) (push) Has been cancelled
Node pnpm CI / build (16.x, ubuntu-latest) (push) Has been cancelled
Node pnpm CI / build (16.x, windows-latest) (push) Has been cancelled
CodeQL / Analyze (javascript) (push) Has been cancelled
Some checks failed
Node CI / build (14.x, macOS-latest) (push) Has been cancelled
Node CI / build (14.x, ubuntu-latest) (push) Has been cancelled
Node CI / build (14.x, windows-latest) (push) Has been cancelled
Node CI / build (16.x, macOS-latest) (push) Has been cancelled
Node CI / build (16.x, ubuntu-latest) (push) Has been cancelled
Node CI / build (16.x, windows-latest) (push) Has been cancelled
coverage CI / build (push) Has been cancelled
Node pnpm CI / build (16.x, macOS-latest) (push) Has been cancelled
Node pnpm CI / build (16.x, ubuntu-latest) (push) Has been cancelled
Node pnpm CI / build (16.x, windows-latest) (push) Has been cancelled
CodeQL / Analyze (javascript) (push) Has been cancelled
This commit is contained in:
23
jest.config.ts
Normal file
23
jest.config.ts
Normal file
@@ -0,0 +1,23 @@
|
||||
import { configUmiAlias, createConfig } from '@umijs/max/test';
|
||||
|
||||
export default async () => {
|
||||
const config = await configUmiAlias({
|
||||
...createConfig({
|
||||
target: 'browser',
|
||||
}),
|
||||
});
|
||||
|
||||
console.log();
|
||||
return {
|
||||
...config,
|
||||
testEnvironmentOptions: {
|
||||
...(config?.testEnvironmentOptions || {}),
|
||||
url: 'http://localhost:8000',
|
||||
},
|
||||
setupFiles: [...(config.setupFiles || []), './tests/setupTests.jsx'],
|
||||
globals: {
|
||||
...config.globals,
|
||||
localStorage: null,
|
||||
},
|
||||
};
|
||||
};
|
||||
Reference in New Issue
Block a user