Skip to content

Commit dcf30f2

Browse files
committed
test: fix context process timeout error codes
1 parent dd3c611 commit dcf30f2

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

test/unit/context-process-exit-test.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ describe("context process exit", function () {
3636
socket1.receive()
3737
})
3838

39-
assert.equal(code, 1)
39+
assert.equal(code, -1)
4040
})
4141

4242
it("should produce warning when messages are queued with blocky", async function () {
@@ -141,7 +141,7 @@ describe("context process exit", function () {
141141
socket1.receive()
142142
})
143143

144-
assert.equal(code, 1)
144+
assert.equal(code, -1)
145145
})
146146
})
147147
})

test/unit/helpers.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -181,6 +181,7 @@ export function createProcess(fn: () => void): Promise<Result> {
181181

182182
setTimeout(() => {
183183
resolve({code: -1, stdout, stderr})
184+
console.warn("Process timeout")
184185
child.kill()
185186
}, 750)
186187
})

0 commit comments

Comments
 (0)