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

Function test_help_summarize_symbols

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

Source from the content-addressed store, hash-verified

746
747 #[test]
748 fn test_help_summarize_symbols() {
749 let mut t = tester_with(vec![DoNothingCommand::new(), EmptyFunction::new()]);
750 t.get_console().borrow_mut().set_color(Some(100), Some(200)).unwrap();
751 t.run("HELP")
752 .expect_output([CapturedOut::SetColor(Some(100), Some(200))])
753 .expect_prints(header())
754 .expect_prints([""])
755 .expect_output([
756 CapturedOut::SetColor(Some(TITLE_COLOR), Some(200)),
757 CapturedOut::Print(" Top-level help topics".to_owned()),
758 CapturedOut::SetColor(Some(100), Some(200)),
759 ])
760 .expect_prints([""])
761 .expect_output([
762 CapturedOut::Write(" >> ".to_owned()),
763 CapturedOut::SetColor(Some(LINK_COLOR), Some(200)),
764 CapturedOut::Print("Interpreter".to_owned()),
765 CapturedOut::SetColor(Some(100), Some(200)),
766 ])
767 .expect_output([
768 CapturedOut::Write(" >> ".to_owned()),
769 CapturedOut::SetColor(Some(LINK_COLOR), Some(200)),
770 CapturedOut::Print("Language reference".to_owned()),
771 CapturedOut::SetColor(Some(100), Some(200)),
772 ])
773 .expect_output([
774 CapturedOut::Write(" >> ".to_owned()),
775 CapturedOut::SetColor(Some(LINK_COLOR), Some(200)),
776 CapturedOut::Print("Testing".to_owned()),
777 CapturedOut::SetColor(Some(100), Some(200)),
778 ])
779 .expect_prints([
780 "",
781 " Type HELP followed by the name of a topic for details.",
782 " Type HELP \"HELP\" for details on how to specify topic names.",
783 " Type LOAD \"DEMOS:/TOUR.BAS\": RUN for a guided tour.",
784 " Type END or press CTRL+D to exit.",
785 "",
786 ])
787 .check();
788 }
789
790 #[test]
791 fn test_help_includes_scripting_categories() {

Callers

nothing calls this directly

Calls 8

tester_withFunction · 0.85
headerFunction · 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