Commit 06909ab8 authored by Luis Araujo's avatar Luis Araujo

Rename the analyse command to new name report

This is a more accurate name for such a command. This commit also
updates the test unit to use the new name.
parent 9f1384a1
......@@ -88,12 +88,12 @@ class StatusCliTestCase(CliTestCase):
with self.assertRaises(SystemExit):
self.cli._parse_args(["status"])
class AnalyseCliTestCase(CliTestCase):
class ReportCliTestCase(CliTestCase):
@redirect_stderr
def test_cli_analyse_requires_args(self):
def test_cli_report_requires_args(self):
with self.assertRaises(SystemExit):
self.cli._parse_args(["analyse"])
self.cli._parse_args(["report"])
class ResultsCliTestCase(CliTestCase):
......
......@@ -183,18 +183,19 @@ class Cli(object):
help="save test attachments to DIR")
test_parser.set_defaults(func=test)
# Analyse
analyse_parser = subparsers.add_parser('analyse', help="Analyse results"
" for job id")
analyse_parser.add_argument('job_ids', nargs='+', type=str,
metavar='JOB_ID', help="job id to analyse")
analyse_parser.add_argument('-a', '--all-results', action='store_true',
# Report
report_parser = subparsers.add_parser('report', help="Generate report"
" for job id's")
report_parser.add_argument('job_ids', nargs='+', type=str,
metavar='JOB_ID',
help="job id to generate report")
report_parser.add_argument('-a', '--all-results', action='store_true',
help="expand and show all test results (not "
"only failed results)")
analyse_parser.add_argument('-n', '--no-limit', action='store_true',
report_parser.add_argument('-n', '--no-limit', action='store_true',
help="ignore the number limit (set to 500) to "
"show test results")
analyse_parser.set_defaults(func=analyse)
report_parser.set_defaults(func=report)
# Results
results_parser = subparsers.add_parser('results', help="Get (raw) results")
......@@ -284,9 +285,9 @@ def test(args):
from lqa_tool.commands.test import TestCmd
TestCmd(args).run()
def analyse(args):
from lqa_tool.commands.analyse import AnalyseCmd
AnalyseCmd(args).run()
def report(args):
from lqa_tool.commands.report import ReportCmd
ReportCmd(args).run()
def results(args):
from lqa_tool.commands.results import ResultsCmd
......
......@@ -29,7 +29,7 @@ from lqa_tool.settings import lqa_logger
from lqa_tool.commands import Command
from lqa_tool.version import __version__
class AnalyseCmd(Command):
class ReportCmd(Command):
"""Sub-command to generate a LAVA lqa report"""
def __init__(self, args):
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment