aboutsummaryrefslogtreecommitdiff
path: root/test.cxx
diff options
context:
space:
mode:
authorPavel Belikov <pavel.fuchs.belikov@gmail.com>2017-11-06 13:58:51 +0300
committerPavel Belikov <pavel.fuchs.belikov@gmail.com>2017-11-06 13:58:51 +0300
commit34c1a3bbfb094ac1e794a70d8e7d9e5d9b03900c (patch)
tree6653b3bc131c48825b1e4582b16ed04ebf6cd3d8 /test.cxx
parentadd HelpParams::showCommandChildren and HelpParams::showCommandFullHelp (diff)
downloadargs.hxx-34c1a3bbfb094ac1e794a70d8e7d9e5d9b03900c.tar.xz
add COMMAND to program line
Diffstat (limited to 'test.cxx')
-rw-r--r--test.cxx9
1 files changed, 4 insertions, 5 deletions
diff --git a/test.cxx b/test.cxx
index 597eaae..0726619 100644
--- a/test.cxx
+++ b/test.cxx
@@ -769,7 +769,7 @@ TEST_CASE("Subparser help works as expected", "[args]")
auto d = p.GetDescription(p.helpParams, 0);
s << p;
- REQUIRE(s.str() == R"( git {OPTIONS}
+ REQUIRE(s.str() == R"( git [COMMAND] {OPTIONS}
git-like parser
@@ -797,7 +797,7 @@ TEST_CASE("Subparser help works as expected", "[args]")
p.ParseArgs(std::vector<std::string>{});
s.str("");
s << p;
- REQUIRE(s.str() == R"( git {OPTIONS}
+ REQUIRE(s.str() == R"( git [COMMAND] {OPTIONS}
git-like parser
@@ -809,12 +809,11 @@ TEST_CASE("Subparser help works as expected", "[args]")
)");
-
p.helpParams.showCommandChildren = true;
p.ParseArgs(std::vector<std::string>{});
s.str("");
s << p;
- REQUIRE(s.str() == R"( git {OPTIONS}
+ REQUIRE(s.str() == R"( git [COMMAND] {OPTIONS}
git-like parser
@@ -833,7 +832,7 @@ TEST_CASE("Subparser help works as expected", "[args]")
p.ParseArgs(std::vector<std::string>{});
s.str("");
s << p;
- REQUIRE(s.str() == R"( git {OPTIONS}
+ REQUIRE(s.str() == R"( git [COMMAND] {OPTIONS}
git-like parser