Skip to content

Commit

Permalink
task component test added
Browse files Browse the repository at this point in the history
  • Loading branch information
lisaaksionova committed Dec 11, 2024
1 parent 0d9788f commit 9f55ce7
Show file tree
Hide file tree
Showing 10 changed files with 6,764 additions and 3,591 deletions.
6 changes: 6 additions & 0 deletions babel.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
module.exports = {
presets: [
["@babel/preset-env", { targets: { node: "current" } }],
"@babel/preset-typescript",
],
};
30 changes: 30 additions & 0 deletions jest.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
module.exports = {
// The root of your source code, typically /src
// `<rootDir>` is a token Jest substitutes
roots: ["<rootDir>/src"],

// Jest transformations -- this adds support for TypeScript
// using ts-jest
transform: {
"^.+\\.tsx?$": "ts-jest",
},
transformIgnorePatterns: ["node_modules/(?!antd)/"],

// Runs special logic, such as cleaning up components
// when using React Testing Library and adds special
// extended assertions to Jest
setupFilesAfterEnv: ["@testing-library/jest-dom"],

// Test spec file resolution pattern
// Matches parent folder `__tests__` and filename
// should contain `test` or `spec`.
testRegex: "(/__tests__/.*|(\\.|/)(test|spec))\\.tsx?$",

// Module file extensions for importing
moduleFileExtensions: ["ts", "tsx", "js", "jsx", "json", "node", "scss"],
moduleNameMapper: {
"\\.(css|scss)$": "identity-obj-proxy",
},
resolver: undefined,
testEnvironment: "jsdom",
};
Loading

0 comments on commit 9f55ce7

Please sign in to comment.