From baf26eff73588b236d5c1261b462d76f8998838b Mon Sep 17 00:00:00 2001 From: Kanagaraj Manickam k00365106 Date: Tue, 26 Sep 2017 11:30:31 +0530 Subject: Add commands help generation code CLI-34 Change-Id: Ic71c0a0d79ad4e1e1be74d5f98c3e1c40f300e2a Signed-off-by: Kanagaraj Manickam k00365106 --- .../src/test/java/org/onap/cli/validation/OnapCliMainTest.java | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) (limited to 'validation') diff --git a/validation/src/test/java/org/onap/cli/validation/OnapCliMainTest.java b/validation/src/test/java/org/onap/cli/validation/OnapCliMainTest.java index f89e265d..836505d7 100644 --- a/validation/src/test/java/org/onap/cli/validation/OnapCliMainTest.java +++ b/validation/src/test/java/org/onap/cli/validation/OnapCliMainTest.java @@ -60,14 +60,17 @@ public class OnapCliMainTest { } @Test - public void commandHelpTest() throws OnapCommandException { + public void usageReadTheDocsTest() throws OnapCommandException { for (String version: OnapCommandRegistrar.getRegistrar().getAvailableProductVersions()) { OnapCommandRegistrar.getRegistrar().setEnabledProductVersion(version); + System.out.println(version); + System.out.println("==========================\n\n"); for (ExternalSchema sch : OnapCommandRegistrar.getRegistrar().listCommandInfo()) { if (sch.getCmdVersion().equals(version)) { - System.out.println( - "************************* help '" + sch.getCmdName() + "' *******************************"); + System.out.println(sch.getCmdName()); + System.out.println("-----------------------------------------------\n\n"); this.handle(new String[] { sch.getCmdName(), "-h"}); + System.out.println("\n"); } } } -- cgit 1.2.3-korg