ansible/test/lib/ansible_test/_data/sanity
Sam Doooran 5ecfb19cad
arg_spec - move validator lookup method to a function (#72667)
* arg_spec - move type checking lookup method to a function

* Change get_wanted_type name and behavior

Change the name to get_validator to bette describe what it is doing.

Change the interface to always return a value. This lines up with the behavior of get_*
functions always returning something or None and check_* functions raising an
Exception if something went wrong during the check.

* Add param to check_type_str()

Not meant to be a long term fix, but gets tests passing. More work is needed to figure
out how to solve this cleanly.

* Remove private attribute mapping types to validator

Since the function that needs it has moved to parameters.py, there is no need to have it as
a attribute of AnsibleModule.

Update tests that were referencing the private attribute.

* Use private method for 'str' type

To avoid having to put the string conversion warning behavior in the check_type_str() method,
use the private _check_type_str() method for 'str' type.

Import CHECK_ARGUMENT_TYPES_DISPATCHER for backwards compalitibility and store it as
a private attribute.

Revert changes to support plugins that are referencing serf._CHECK_ARGUMENT_TYPES_DISPATCHER.

* Add changelog

* Change function name to better reflect its... function

* Change dict name to better reflect its contents

CHECK_ARGUMENT_TYPES_DISPATCHER --> DEFAULT_TYPE_VALIDATORS

* Fix changelog
2020-12-17 17:15:00 -05:00
..
code-smell Compare removal and deprecation dates and versions in runtime metadata against current version and today (#72625) 2020-12-15 09:05:38 -05:00
compile Add Python 3.9 to ansible-test. 2020-03-01 17:42:06 -08:00
import Code cleanup in the import sanity test. 2020-06-23 23:09:00 -07:00
integration-aliases Use AZP config for integration-aliases test. 2020-12-03 15:35:58 -08:00
pep8
pslint
pylint import_playbook - change additional params to deprecation (#72987) 2020-12-17 14:14:58 -05:00
rstcheck Autointerpreter table (#60148) 2019-08-08 13:56:07 -05:00
shellcheck Fix sanity tests based on newer version of shellcheck (#60423) 2019-08-12 16:24:28 -04:00
validate-modules arg_spec - move validator lookup method to a function (#72667) 2020-12-17 17:15:00 -05:00
yamllint allow any type of unsafe data (#72547) 2020-11-10 10:48:20 -05:00