From 2b8fb4fe0033242c6750655d79b3b1feb7c3fd7d Mon Sep 17 00:00:00 2001 From: Douglas <32344964+NotTheDr01ds@users.noreply.github.com> Date: Sat, 15 Feb 2025 18:55:33 -0500 Subject: [PATCH] Fix failing test when using man version 2.13.0 (#15123) The test added in #15115 fails on systems using later versions of `man` (2.13.0 triggers the issue, at least). This updates the test to ignore formatting characters. Thanks to @fdncred and @blindFS for the debugging assistance. --- crates/nu-lsp/src/lib.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/crates/nu-lsp/src/lib.rs b/crates/nu-lsp/src/lib.rs index 6d75ab0e3a..336496e719 100644 --- a/crates/nu-lsp/src/lib.rs +++ b/crates/nu-lsp/src/lib.rs @@ -1025,7 +1025,7 @@ mod tests { .to_string(); #[cfg(not(windows))] - assert!(hover_text.starts_with("SLEEP(1)")); + assert!(hover_text.contains("SLEEP")); #[cfg(windows)] assert!(hover_text.starts_with("NAME\r\n Start-Sleep")); }