MCPcopy Index your code
hub / github.com/endbasic/endbasic / test_help_describe_command

Function test_help_describe_command

std/src/help.rs:847–868  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

845
846 #[test]
847 fn test_help_describe_command() {
848 let mut t = tester_with(vec![DoNothingCommand::new()]);
849 t.get_console().borrow_mut().set_color(Some(20), Some(21)).unwrap();
850 t.run(r#"help "Do_Nothing""#)
851 .expect_output([CapturedOut::SetColor(Some(20), Some(21))])
852 .expect_prints([""])
853 .expect_output([
854 CapturedOut::SetColor(Some(TITLE_COLOR), Some(21)),
855 CapturedOut::Print(" DO_NOTHING sample$".to_owned()),
856 CapturedOut::SetColor(Some(20), Some(21)),
857 ])
858 .expect_prints([
859 "",
860 " This is the blurb.",
861 "",
862 " First paragraph of the extended description.",
863 "",
864 " Second paragraph of the extended description.",
865 "",
866 ])
867 .check();
868 }
869
870 fn do_help_describe_function_test(name: &str) {
871 let mut t = tester_with(vec![EmptyFunction::new()]);

Callers

nothing calls this directly

Calls 7

tester_withFunction · 0.85
set_colorMethod · 0.45
get_consoleMethod · 0.45
checkMethod · 0.45
expect_printsMethod · 0.45
expect_outputMethod · 0.45
runMethod · 0.45

Tested by

no test coverage detected