File tree Expand file tree Collapse file tree
crates/vespertide-cli/src/commands Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -84,6 +84,8 @@ fn print_fill_with_item_and_get_prompt(
8484}
8585
8686/// Prompt the user for a fill_with value using dialoguer.
87+ /// This function wraps terminal I/O and cannot be unit tested without a real terminal.
88+ #[ cfg( not( tarpaulin_include) ) ]
8789fn prompt_fill_with_value ( prompt : & str ) -> Result < String > {
8890 Input :: new ( )
8991 . with_prompt ( prompt)
@@ -894,8 +896,8 @@ mod tests {
894896 #[ test]
895897 fn test_prompt_fill_with_value_function_exists ( ) {
896898 // This test verifies that prompt_fill_with_value has the correct signature.
897- // We cannot actually call it in tests because dialoguer::Input requires a real terminal.
898- // This test ensures the function compiles and has the expected type signature .
899+ // We cannot actually call it in tests because dialoguer::Input blocks waiting for terminal input .
900+ // The function is excluded from coverage with #[cfg_attr(coverage_nightly, coverage(off))] .
899901 let _: fn ( & str ) -> Result < String > = prompt_fill_with_value;
900902 }
901903
You can’t perform that action at this time.
0 commit comments