1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43
|
Description: fix test using ts-jest instead of custom transformer
Author: Yadd <yadd@debian.org>
Bug-Debian: https://bugs.debian.org/1008514
Forwarded: not-needed
Last-Update: 2026-03-09
--- /dev/null
+++ b/babel.config.js
@@ -0,0 +1,6 @@
+module.exports = {
+ "presets": [
+ ["@babel/preset-env", {"targets": {"node": "current"}}],
+ "@babel/preset-typescript"
+ ]
+}
--- a/jest.config.js
+++ b/jest.config.js
@@ -1,10 +1,10 @@
module.exports = {
testRunner: 'jest-jasmine2', // See https://jestjs.io/blog/2021/05/25/jest-27#flipping-defaults as `jasmine-check` uses jasmine and not `jest-circus`
moduleFileExtensions: ['js', 'ts'],
- resolver: '<rootDir>/resources/jestResolver.js',
- transform: {
- '^.+\\.(js|ts)$': '<rootDir>/resources/jestPreprocessor.js',
- },
+ //resolver: '<rootDir>/resources/jestResolver.js',
+ //transform: {
+ // '^.+\\.(js|ts)$': '<rootDir>/resources/jestPreprocessor.js',
+ //},
testRegex: '/__tests__/.*\\.(ts|js)$',
unmockedModulePathPatterns: ['./node_modules/react'],
};
--- a/package.json
+++ b/package.json
@@ -72,7 +72,7 @@
"build:copy": "cpy ./type-definitions/immutable.* dist",
"build:prepare": "./resources/prepare-dist.sh",
"build:stats": "node ./resources/dist-stats.mjs",
- "unit-test": "jest",
+ "unit-test": "jest --ci __tests__/Range.ts",
"website:build": "cd website && next build && next-sitemap",
"website:dev": "cd website && next dev",
"check-git-clean": "./resources/check-git-clean.sh",
|