Skip to content

Commit 8e4622a

Browse files
committed
Fix milestone screen sanitization clippy lint
1 parent a687364 commit 8e4622a

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

  • crates/pty_terminal_test/src

crates/pty_terminal_test/src/lib.rs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,9 @@ impl TestTerminal {
4646

4747
impl Reader {
4848
fn sanitized_screen_contents(&self) -> String {
49-
self.pty.get_ref().screen_contents().replace(MILESTONE_FENCE_CHAR, "")
49+
let mut screen = self.pty.get_ref().screen_contents();
50+
screen.retain(|ch| ch != MILESTONE_FENCE_CHAR);
51+
screen
5052
}
5153

5254
/// Reads from the PTY until a milestone with the given name is encountered.

0 commit comments

Comments
 (0)