Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ terminal_size = { workspace = true }
textwrap = { workspace = true }
unicode-width = { workspace = true }
uucore = { workspace = true }
rustix = { workspace = true }
rustix = { workspace = true, features = ["fs", "pipe"] }

[dev-dependencies]
assert_fs = { workspace = true }
Expand Down
7 changes: 6 additions & 1 deletion src/sed/compiler.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1831,7 +1831,12 @@ mod tests {
let err = result.unwrap_err();
let msg = err.to_string();

assert_eq!(msg, "input.txt:3:1: error: invalid command 'x'");
// When stderr is a terminal, diagnostics may append an underlined
// snippet; only the leading location line is required.
assert!(
msg.contains("input.txt:3:1: error: invalid command 'x'"),
"unexpected error message: {msg:?}"
);
}

// get_verified_cmd_spec
Expand Down
Loading
Loading