fix unit-test and new quality issues
This commit is contained in:
@@ -64,7 +64,7 @@ class cl_unit_test(cl_helper_withresults_base):
|
||||
cov.stop()
|
||||
cov.save()
|
||||
cov.html_report(directory=str(CoverageReportPath))
|
||||
cov.xml_report(outfile=(CoverageReportPath / f"{cls.CoverageReportName}.xml"))
|
||||
cov.xml_report(outfile=str(CoverageReportPath / f"{cls.CoverageReportName}.xml"))
|
||||
|
||||
# computing results (Only if xml available)
|
||||
if cls.enable_full_xml_export is True:
|
||||
|
||||
@@ -30,12 +30,8 @@ class Test_main(unittest.TestCase):
|
||||
self.assertNotEqual(chacha_cicd_helper.__version__, "?.?.?")
|
||||
|
||||
def test_help(self):
|
||||
|
||||
with redirect_stdout(StringIO()) as capted_stdout, redirect_stderr(StringIO()) as capted_stderr:
|
||||
with self.assertRaises(SystemExit):
|
||||
fct_main(["-h", "-pp", str(testdir_path.parent.resolve())])
|
||||
print(capted_stdout.getvalue())
|
||||
print(capted_stderr.getvalue())
|
||||
|
||||
self.assertIn("usage: chacha_cicd_helper", capted_stdout.getvalue())
|
||||
self.assertIn(f"usage: {chacha_cicd_helper.__Name__}", capted_stdout.getvalue())
|
||||
self.assertEqual(capted_stderr.getvalue(), "")
|
||||
|
||||
Reference in New Issue
Block a user