Skip to content

Commit 14f2c41

Browse files
committed
don't trim, just assert the newline
1 parent 8839f04 commit 14f2c41

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

tests/integration/exec-utils.test.ts

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ describe("execFileWithInput integration tests", () => {
2222
await execFileWithInput("bash", "nonexistentcommand", {});
2323
fail("Should have thrown an error");
2424
} catch (error: any) {
25-
console.log(error)
25+
console.log(error);
2626
expect(error.stderr).toContain("bash: line 1: nonexistentcommand: command not found");
2727
expect(error.message).toContain("Command failed: bash\nbash: line 1: nonexistentcommand: command not found\n");
2828
}
@@ -34,7 +34,8 @@ describe("execFileWithInput integration tests", () => {
3434
'echo "Hello from Fish"',
3535
{}
3636
);
37-
expect(result.stdout.trim()).toBe("Hello from Fish");
37+
console.log(result);
38+
expect(result.stdout).toBe("Hello from Fish\n");
3839
expect(result.stderr).toBe("");
3940
});
4041

0 commit comments

Comments
 (0)