tape-six-proc 1.2.7 → 1.2.9
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +1 -1
- package/README.md +2 -0
- package/bin/tape6-proc-node.js +6 -4
- package/package.json +6 -4
- package/src/TestWorker.js +7 -7
package/LICENSE
CHANGED
package/README.md
CHANGED
|
@@ -88,6 +88,8 @@ LLM-friendly documentation is available:
|
|
|
88
88
|
|
|
89
89
|
The most recent releases:
|
|
90
90
|
|
|
91
|
+
- 1.2.9 _Added `js-check`, Bun + Deno CI, tuned dependabot. Updated dependencies._
|
|
92
|
+
- 1.2.8 _Fixed Bun stdout flush bug. Added GitHub Actions CI. Updated dependencies._
|
|
91
93
|
- 1.2.7 _Added `--help` and `--version` flags. Updated dependencies._
|
|
92
94
|
- 1.2.6 _Updated dependencies. Added AI agent rule files. Improved workflows._
|
|
93
95
|
- 1.2.5 _Synchronized with `tape-six` 1.7.6+. Simplified CLI via shared config utilities. Added `--info` flag. Fixed Deno stdout flush._
|
package/bin/tape6-proc-node.js
CHANGED
|
@@ -90,17 +90,19 @@ const main = async () => {
|
|
|
90
90
|
if (options.optionFlags['--info'] === '') {
|
|
91
91
|
showInfo(options, files);
|
|
92
92
|
await new Promise(r => process.stdout.write('', r));
|
|
93
|
-
process.
|
|
93
|
+
process.exitCode = 0;
|
|
94
|
+
return;
|
|
94
95
|
}
|
|
95
96
|
|
|
96
97
|
if (!files.length) {
|
|
97
98
|
console.log('No files found.');
|
|
98
99
|
await new Promise(r => process.stdout.write('', r));
|
|
99
|
-
process.
|
|
100
|
+
process.exitCode = 1;
|
|
101
|
+
return;
|
|
100
102
|
}
|
|
101
103
|
|
|
102
104
|
const reporter = getReporter(),
|
|
103
|
-
worker = new TestWorker(reporter, options.parallel, options.flags);
|
|
105
|
+
worker = /** @type {*} */ (new TestWorker(reporter, options.parallel, options.flags));
|
|
104
106
|
|
|
105
107
|
reporter.report({type: 'test', test: 0});
|
|
106
108
|
|
|
@@ -118,7 +120,7 @@ const main = async () => {
|
|
|
118
120
|
});
|
|
119
121
|
|
|
120
122
|
await new Promise(r => process.stdout.write('', r));
|
|
121
|
-
process.
|
|
123
|
+
process.exitCode = hasFailed ? 1 : 0;
|
|
122
124
|
};
|
|
123
125
|
|
|
124
126
|
main().catch(error => console.error('ERROR:', error));
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "tape-six-proc",
|
|
3
|
-
"version": "1.2.
|
|
3
|
+
"version": "1.2.9",
|
|
4
4
|
"description": "Process-isolated test runner for tape-six. Runs each test file in its own subprocess. Works with Node, Deno, and Bun. Supports TypeScript without transpilation.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"bin": {
|
|
@@ -9,6 +9,7 @@
|
|
|
9
9
|
"scripts": {
|
|
10
10
|
"lint": "prettier --check .",
|
|
11
11
|
"lint:fix": "prettier --write .",
|
|
12
|
+
"js-check": "tsc --project tsconfig.check.json",
|
|
12
13
|
"test": "node ./bin/tape6-proc.js --flags FO",
|
|
13
14
|
"test:bun": "bun run ./bin/tape6-proc.js --flags FO",
|
|
14
15
|
"test:deno": "deno run -A ./bin/tape6-proc.js -r --allow-read -r --allow-env --flags FO"
|
|
@@ -56,8 +57,8 @@
|
|
|
56
57
|
"llms-full.txt"
|
|
57
58
|
],
|
|
58
59
|
"dependencies": {
|
|
59
|
-
"dollar-shell": "^1.1.
|
|
60
|
-
"tape-six": "^1.
|
|
60
|
+
"dollar-shell": "^1.1.14",
|
|
61
|
+
"tape-six": "^1.9.0"
|
|
61
62
|
},
|
|
62
63
|
"tape6": {
|
|
63
64
|
"tests": [
|
|
@@ -65,6 +66,7 @@
|
|
|
65
66
|
]
|
|
66
67
|
},
|
|
67
68
|
"devDependencies": {
|
|
68
|
-
"
|
|
69
|
+
"@types/node": "^25.6.0",
|
|
70
|
+
"typescript": "^6.0.3"
|
|
69
71
|
}
|
|
70
72
|
}
|
package/src/TestWorker.js
CHANGED
|
@@ -23,34 +23,34 @@ export default class TestWorker extends EventServer {
|
|
|
23
23
|
this.prefix = crypto.randomUUID();
|
|
24
24
|
}
|
|
25
25
|
makeTask(fileName) {
|
|
26
|
+
const self = /** @type {*} */ (this);
|
|
26
27
|
const testName = new URL(fileName, baseName),
|
|
27
|
-
id = String(++
|
|
28
|
+
id = String(++self.counter),
|
|
28
29
|
worker = spawn(
|
|
29
|
-
[currentExecPath(), ...runFileArgs, ...
|
|
30
|
+
[currentExecPath(), ...runFileArgs, ...self.options.runFileArgs, fileURLToPath(testName)],
|
|
30
31
|
{
|
|
31
32
|
stdin: 'ignore',
|
|
32
33
|
stdout: 'pipe',
|
|
33
34
|
stderr: 'pipe',
|
|
34
35
|
env: {
|
|
35
36
|
...process.env,
|
|
36
|
-
TAPE6_FLAGS:
|
|
37
|
+
TAPE6_FLAGS: self.options.flags,
|
|
37
38
|
TAPE6_TEST: id,
|
|
38
39
|
TAPE6_TEST_FILE_NAME: fileName,
|
|
39
40
|
TAPE6_JSONL: 'Y',
|
|
40
|
-
TAPE6_JSONL_PREFIX:
|
|
41
|
+
TAPE6_JSONL_PREFIX: self.prefix,
|
|
41
42
|
TAPE6_MIN: '',
|
|
42
43
|
TAPE6_TAP: '',
|
|
43
44
|
TAPE6_TTY: ''
|
|
44
45
|
}
|
|
45
46
|
}
|
|
46
47
|
);
|
|
47
|
-
|
|
48
|
-
const self = this;
|
|
48
|
+
self.idToWorker[id] = worker;
|
|
49
49
|
const stdoutDeferred = makeDeferred();
|
|
50
50
|
worker.stdout
|
|
51
51
|
.pipeThrough(new TextDecoderStream())
|
|
52
52
|
.pipeThrough(lines())
|
|
53
|
-
.pipeThrough(parse(
|
|
53
|
+
.pipeThrough(parse(self.prefix))
|
|
54
54
|
.pipeTo(
|
|
55
55
|
new WritableStream({
|
|
56
56
|
write(msg) {
|