Skip to content

Commit 279d25f

Browse files
committed
Fix broken tests
1 parent 2db824a commit 279d25f

File tree

3 files changed

+8
-8
lines changed

3 files changed

+8
-8
lines changed

jscomp/build_tests/cli_help/input.js

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -214,7 +214,7 @@ async function test() {
214214

215215
{
216216
// Shows format help with --help arg
217-
const out = await exec(`../../../rescript format`, ["--help"], {
217+
const out = await exec(`../../../rescript`, ["format", "--help"], {
218218
cwd: __dirname,
219219
});
220220
assert.equal(out.stdout, formatHelp);
@@ -224,7 +224,7 @@ async function test() {
224224

225225
{
226226
// Shows format help with -h arg
227-
const out = await exec(`../../../rescript format`, ["-h"], {
227+
const out = await exec(`../../../rescript`, ["format", "-h"], {
228228
cwd: __dirname,
229229
});
230230
assert.equal(out.stdout, formatHelp);
@@ -234,7 +234,7 @@ async function test() {
234234

235235
{
236236
// Shows convert help with --help arg
237-
const out = await exec(`../../../rescript convert`, ["--help"], {
237+
const out = await exec(`../../../rescript`, ["convert", "--help"], {
238238
cwd: __dirname,
239239
});
240240
assert.equal(out.stdout, convertHelp);
@@ -244,7 +244,7 @@ async function test() {
244244

245245
{
246246
// Shows convert help with -h arg
247-
const out = await exec(`../../../rescript convert`, ["-h"], {
247+
const out = await exec(`../../../rescript`, ["convert", "-h"], {
248248
cwd: __dirname,
249249
});
250250
assert.equal(out.stdout, convertHelp);
@@ -254,7 +254,7 @@ async function test() {
254254

255255
{
256256
// Shows dump help with --help arg
257-
const out = await exec(`../../../rescript dump`, ["--help"], {
257+
const out = await exec(`../../../rescript`, ["dump", "--help"], {
258258
cwd: __dirname,
259259
});
260260
assert.equal(out.stdout, dumpHelp);
@@ -264,7 +264,7 @@ async function test() {
264264

265265
{
266266
// Shows dump help with -h arg
267-
const out = await exec(`../../../rescript dump`, ["-h"], {
267+
const out = await exec(`../../../rescript`, ["dump", "-h"], {
268268
cwd: __dirname,
269269
});
270270
assert.equal(out.stdout, dumpHelp);

jscomp/build_tests/utils.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ async function exec(command, args, options) {
4444
code = signals[signal] + 128;
4545
}
4646

47-
resolve({ code, stdout, stderr });
47+
resolve({ status: code, stdout, stderr });
4848
});
4949
});
5050
}

scripts/ciTest.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@ async function runTests() {
7171
const out = await exec(`node`, ["input.js"], { cwd: testDir });
7272
console.log(out.stdout);
7373

74-
if (out.code === 0) {
74+
if (out.status === 0) {
7575
console.log("✅ success in", file);
7676
} else {
7777
console.log(`❌ error in ${file} with stderr:\n`, out.stderr);

0 commit comments

Comments
 (0)