mirror of
https://github.com/SabreTools/SabreTools.CommandLine.git
synced 2026-09-21 22:25:15 +00:00
Clean up formatting to personal taste
This commit is contained in:
@@ -846,7 +846,11 @@ namespace SabreTools.CommandLine.Test
|
||||
public void OutputManpage_Structure_ContainsRequiredSections()
|
||||
{
|
||||
var set = BuildSampleSet();
|
||||
var info = new ManpageInfo("sample") { Version = "sample 1.0", Description = "do sample things" };
|
||||
var info = new ManpageInfo("sample")
|
||||
{
|
||||
Version = "sample 1.0",
|
||||
Description = "do sample things",
|
||||
};
|
||||
|
||||
string page = set.OutputManpage(info);
|
||||
|
||||
@@ -965,11 +969,15 @@ namespace SabreTools.CommandLine.Test
|
||||
{
|
||||
var set = new CommandSet("Sample header line");
|
||||
|
||||
var help = new MockFeature("Help", ["?", "h", "help"], "Show this help",
|
||||
var help = new MockFeature("Help",
|
||||
["?", "h", "help"],
|
||||
"Show this help",
|
||||
"Built-in to most of the programs is a basic help text.");
|
||||
set.Add(help);
|
||||
|
||||
var convert = new MockFeature("Convert", "--convert", "Convert input files",
|
||||
var convert = new MockFeature("Convert",
|
||||
"--convert",
|
||||
"Convert input files",
|
||||
"Converts the provided input files into the desired output format.");
|
||||
convert.Add(new StringInput("output", "--output", "Set the output path"));
|
||||
convert.Add(new FlagInput("force", "--force", "Overwrite existing files"));
|
||||
|
||||
@@ -17,7 +17,6 @@ namespace SabreTools.CommandLine.Test.Features
|
||||
|
||||
var original = Console.Out;
|
||||
var writer = new StringWriter();
|
||||
string output;
|
||||
try
|
||||
{
|
||||
Console.SetOut(writer);
|
||||
@@ -29,10 +28,10 @@ namespace SabreTools.CommandLine.Test.Features
|
||||
Console.SetOut(original);
|
||||
}
|
||||
|
||||
output = writer.ToString();
|
||||
Assert.Contains(".TH \"SAMPLE\" \"1\"", output);
|
||||
Assert.Contains(".SH NAME", output);
|
||||
Assert.Contains(".B \\-\\-convert", output);
|
||||
string actual = writer.ToString();
|
||||
Assert.Contains(".TH \"SAMPLE\" \"1\"", actual);
|
||||
Assert.Contains(".SH NAME", actual);
|
||||
Assert.Contains(".B \\-\\-convert", actual);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
@@ -42,11 +41,15 @@ namespace SabreTools.CommandLine.Test.Features
|
||||
{
|
||||
var set = new CommandSet("Sample header line");
|
||||
|
||||
var help = new MockFeature("Help", ["?", "h", "help"], "Show this help",
|
||||
var help = new MockFeature("Help",
|
||||
["?", "h", "help"],
|
||||
"Show this help",
|
||||
"Built-in to most of the programs is a basic help text.");
|
||||
set.Add(help);
|
||||
|
||||
var convert = new MockFeature("Convert", "--convert", "Convert input files",
|
||||
var convert = new MockFeature("Convert",
|
||||
"--convert",
|
||||
"Convert input files",
|
||||
"Converts the provided input files into the desired output format.");
|
||||
convert.Add(new StringInput("output", "--output", "Set the output path"));
|
||||
convert.Add(new FlagInput("force", "--force", "Overwrite existing files"));
|
||||
|
||||
Reference in New Issue
Block a user