recrownedathenaeum/RecrownedAthenaeum.ConsoleTools/CommandProcessor/Commands/TestCommand.cs

40 lines
1.7 KiB
C#
Raw Normal View History

using System;
using System.Collections.Generic;
using System.Text;
2018-12-09 20:27:31 +00:00
namespace RecrownedAthenaeum.Tools.CommandProcessor.Commands
{
class TestCommand : EngineCommand
{
public TestCommand() : base("test")
{
}
public override string Help(string argument = null)
{
2018-12-09 07:23:07 +00:00
switch (argument)
{
case null:
return "Test command. Meant for testing random stuff. Current arguments: \"-textWrap\".\n" +
"Its ironic that the help section is also meant to test things.";
case "-textWrap":
return "-textWrap prints a large amount of text to test the text wrap.";
}
return "Test command.";
}
public override void Run(string[] arguments = null)
{
2018-12-09 07:23:07 +00:00
if (arguments != null && arguments[0] == "-textWrap")
{
ConsoleUtilities.WriteWrapped("Lorem ipsum dolor sit amet, consectetur adipiscing elit.[here]\n Duis semper lacinia nisl, eget efficitur massa feugiat vel. Ut egestas elit id sollicitudin pellentesque.[here no space after break.]\nFusce ullamcorper nec turpis at aliquam. Donec cursus mi nec porttitor convallis. Nullam condimentum sollicitudin volutpat. Pellentesque tellus ligula, eleifend sit amet ante ac, accumsan volutpat lorem. Suspendisse potenti. Vestibulum at sodales ipsum. Mauris dignissim maximus purus sagittis elementum.", true);
ConsoleUtilities.WriteWrapped("test");
ConsoleUtilities.WriteWrapped(". ");
ConsoleUtilities.WriteWrapped("test.");
}
base.Run(arguments);
}
}
}