Skip to content

Commit 025c769

Browse files
committed
Correct CJS tests
1 parent 27ba1ed commit 025c769

File tree

2 files changed

+14
-4
lines changed

2 files changed

+14
-4
lines changed

integration-tests/node.test.ts

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,15 @@
11
import { describe, test, expect, beforeAll } from 'vitest';
22
import { execa as execaBase } from 'execa';
33

4-
const execa = execaBase({ cwd: './integration-tests/node' });
4+
const execa = execaBase({
5+
cwd: './integration-tests/node',
6+
env: {
7+
...process.env,
8+
NODE_OPTIONS: '',
9+
TS_NODE_PROJECT: '',
10+
TS_NODE_COMPILER_OPTIONS: '',
11+
},
12+
});
513

614
describe('Node.js', () => {
715
beforeAll(async () => {
Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,12 @@
11
{
22
"private": true,
3+
"type": "commonjs",
34
"scripts": {
4-
"start:cjs": "node index.cjs",
5-
"start:esm": "node index.mjs"
5+
"start:cjs": "node --no-experimental-require-module index.cjs",
6+
"start:esm": "node --no-experimental-require-module index.mjs"
67
},
78
"dependencies": {
8-
"@openai/agents": "latest"
9+
"@openai/agents": "latest",
10+
"typescript": "^5.9.2"
911
}
1012
}

0 commit comments

Comments
 (0)