Skip to content

Commit 73c56e4

Browse files
committed
e2e/global: TestPromptExitCode: check for trailing newline
Make the test slightly more permissive; we're looking for a trailing newline, not necessarily an empty line. Signed-off-by: Sebastiaan van Stijn <[email protected]>
1 parent 30cad38 commit 73c56e4

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

e2e/global/cli_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -240,7 +240,7 @@ func TestPromptExitCode(t *testing.T) {
240240
case <-writeDone:
241241
buf.Reset()
242242
assert.NilError(t, bufioWriter.Flush())
243-
assert.Equal(t, buf.String(), "\n", "expected a new line after the process exits from SIGINT")
243+
assert.Equal(t, strings.HasSuffix(buf.String(), "\n"), true, "expected a new line after the process exits from SIGINT")
244244
}
245245
})
246246
}

0 commit comments

Comments
 (0)