Unified command execution and unit tests

- All arguments inits moved to own clases
- Added unified way to execute commands
- Unit test structure and very basic tests
- Command line script to test coverage
- Argument parsers moved to corresponding commands
- Automatic parsers and command mapping

Change-Id: Id099d14702d9590729583dfd9574bd57022efac5
Related-PROD: PROD-28199
diff --git a/cfg_checker/helpers/args_utils.py b/cfg_checker/helpers/args_utils.py
index daf55b1..1661c96 100644
--- a/cfg_checker/helpers/args_utils.py
+++ b/cfg_checker/helpers/args_utils.py
@@ -34,7 +34,19 @@
         raise ConfigException("'{}' not exists".format(path))
 
 
-def get_report_type_and_filename(args):
+def get_network_map_type_and_filename(args):
+    if args.html or args.text:
+        if args.html and args.text:
+            raise ConfigException("Multuple report types not supported")
+        if args.html is not None:
+            return 'html', args.html
+        if args.text is not None:
+            return 'text', args.text
+    else:
+        return 'console', None
+
+
+def get_package_report_type_and_filename(args):
     if args.html or args.csv:
         if args.html and args.csv:
             raise ConfigException("Multuple report types not supported")
diff --git a/cfg_checker/helpers/errors.py b/cfg_checker/helpers/errors.py
index ca8a8da..1f962eb 100644
--- a/cfg_checker/helpers/errors.py
+++ b/cfg_checker/helpers/errors.py
@@ -200,7 +200,7 @@
         # Detailed errors
         if self.get_errors_total() > 0:
             # create list of strings with error messages
-            for _idx in range(1, self._index - 1):
+            for _idx in range(1, self._index):
                 _list.append(self._format_error(_idx))
                 _list.append("\n")
         else: