File tree Expand file tree Collapse file tree 4 files changed +24
-12
lines changed
Expand file tree Collapse file tree 4 files changed +24
-12
lines changed Original file line number Diff line number Diff line change @@ -11,4 +11,5 @@ uncaughtExceptions.log
1111src /* .json
1212.idea
1313test.ts
14- notes.md
14+ notes.md
15+ .nvmrc
Original file line number Diff line number Diff line change @@ -9,19 +9,28 @@ const config: Config = {
99 testTimeout : 100_000 ,
1010 coverageProvider : 'v8' ,
1111 moduleDirectories : [ 'node_modules' , 'src' ] ,
12- preset : 'ts-jest/presets/js-with-ts -esm' ,
12+ preset : 'ts-jest/presets/default -esm' ,
1313 setupFilesAfterEnv : [ '<rootDir>/test/jest-setup.ts' ] ,
1414 testEnvironment : 'node' ,
1515 testRegex : [ '.*\\.test\\.ts$' ] ,
16- transformIgnorePatterns : [ 'node_modules/(?!cli-testing-library)' ] ,
16+ transformIgnorePatterns : [
17+ 'node_modules/(?!(cli-testing-library|@clack|cleye)/.*)'
18+ ] ,
1719 transform : {
18- '^.+\\.(ts|tsx)$' : [
20+ '^.+\\.(ts|tsx|js|jsx|mjs )$' : [
1921 'ts-jest' ,
2022 {
2123 diagnostics : false ,
2224 useESM : true
2325 }
2426 ]
27+ } ,
28+ // Fix Haste module naming collision
29+ modulePathIgnorePatterns : [
30+ '<rootDir>/test/e2e/prompt-module/data/'
31+ ] ,
32+ moduleNameMapper : {
33+ '^(\\.{1,2}/.*)\\.js$' : '$1'
2534 }
2635} ;
2736
Original file line number Diff line number Diff line change 5454 "test" : " node --no-warnings --experimental-vm-modules $( [ -f ./node_modules/.bin/jest ] && echo ./node_modules/.bin/jest || which jest ) test/unit" ,
5555 "test:all" : " npm run test:unit:docker && npm run test:e2e:docker" ,
5656 "test:docker-build" : " docker build -t oco-test -f test/Dockerfile ." ,
57- "test:unit" : " NODE_OPTIONS=--experimental-vm-modules jest test/unit" ,
57+ "test:unit" : " rimraf /tmp/jest_rs && NODE_OPTIONS=--experimental-vm-modules jest test/unit" ,
5858 "test:unit:docker" : " npm run test:docker-build && DOCKER_CONTENT_TRUST=0 docker run --rm oco-test npm run test:unit" ,
5959 "test:e2e" : " npm run test:e2e:setup && jest test/e2e" ,
6060 "test:e2e:setup" : " sh test/e2e/setup.sh" ,
108108 "ajv" : " ^8.17.1" ,
109109 "whatwg-url" : " ^14.0.0"
110110 }
111- }
111+ }
Original file line number Diff line number Diff line change 1- import 'cli-testing-library/extend-expect'
2- import { configure } from 'cli-testing-library'
31import { jest } from '@jest/globals' ;
42
3+ // Setup jest globally since we're using ESM
54global . jest = jest ;
65
7- /**
8- * Adjusted the wait time for waitFor/findByText to 2000ms, because the default 1000ms makes the test results flaky
9- */
10- configure ( { asyncUtilTimeout : 2000 } )
6+ // NOTE: cli-testing-library imports removed as they caused CI issues.
7+ // Import 'cli-testing-library/extend-expect' and
8+ // import { configure } from 'cli-testing-library'
9+ // directly in the test files that need them (likely e2e tests).
10+
11+ // // Configure cli-testing-library - This needs to be moved to specific tests or a separate e2e setup
12+ // configure({ asyncUtilTimeout: 2000 });
You can’t perform that action at this time.
0 commit comments