5 Commits

Author SHA1 Message Date
Jiri Podivin
b24d4ce792 Validation actions refactor
Unused workdir argument of the run_validations method removed.

Host and playbook skipping simplified.

Docstrings adjusted, including some of the more important
inline code examples.

Test sensitivity to API changes was increased.
More strict assertions have been put on the calls made in CLI.

Logging statements related to the run action
in validation_actions.py were expanded.

New debug level logging statements introduced.

One of the testing constants in the fakes.py was altered
as it was not accurate representation of the real data,
and as such was breaking the new logging statements
during unit test runs.

Deprecation notice for 'log_path' and 'groups' arguments,
in both docstring and logging.

Redundant conditionals for argument types were removed.

The checks of the arguments are implemented
in the function called in the subsequent statement.

As there is no scenario in which one set of these checks
passes, while the other fails with the same values,
we can consider one of them to be redundant.

Helper function 'get_validations_details' without active references
was removed from utils submodule.

Signed-off-by: Jiri Podivin <jpodivin@redhat.com>
Change-Id: I781f6a6f9fc4bd558af56b648f0e0ee9f165dfab
2022-01-21 13:33:22 +01:00
matbu
399d29059e Refactor set_argument_parser to fix shell regression
Openstack Client and Validation Shell is hitting a regression
due to set_argument_parser calling directly parse_known_args
from argparse.
This patch fix the regression and avoid the need to call
parse_known_args directly.

Closes-Bug: #1949596
Change-Id: Ic9a682e7c3d5431e8779064947bd379c00aba584
2021-11-17 00:02:58 +00:00
matbu
11488cd88d Add validation config file mechanism
Introduce validation config file.
The config default location of the config file will be stored
in /etc/validation.cfg

The variables precedence will be the following:
* user's cli args
* config file
* default interval values

Change-Id: I05c54a43bc0a03878793cca3f51e23f4a8b63a23
2021-08-20 08:12:16 +00:00
Jiri Podivin
07558871d6 Unit test refactor
- redundant imports in test modules were removed
- reset color code management in test simplified

Signed-off-by: Jiri Podivin <jpodivin@redhat.com>
Change-Id: Iac5e68286782c5c2fbc185650c0bdf915fe959ef
2021-07-28 12:39:24 +02:00
matbu
5fad1a4d18 Create dedicated CLI for the Validation Framework
This review adds a CLI for the Validation Framework which will become
the only entry point to run the Validation Framework.

It will deprecate the tripleo_validatior.py CLI and the
validation.py script.

This patch uses python cliff library to provide nice helpers, shell
and output formats.

Change-Id: I66800ad51cc50f4eb37efabe85fb553dce008101
2021-04-20 11:52:35 +02:00