You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
ansible/test/units
Matt Martz 56d142350d
Add support for importlib.resources (#78915)
* Add support for importlib.resources

* Remove the importlib.resources imports

* return the correct data

* Some code comments, and re-order for consistency

* Disallow traversing packages below an individual collection

* Add a traversable class for namespaces

* Re-use variable

* Utilize itertools.chain.from_iterable

Co-authored-by: Sviatoslav Sydorenko <wk.cvs.github@sydorenko.org.ua>

* Simplify logic to check for packages from ansible loaders

Co-authored-by: Sviatoslav Sydorenko <wk.cvs.github@sydorenko.org.ua>

* Just a generator expression, instead of a generator

* docstrings

* Add comment about find_spec for our namespaces

* Add some initial unit tests for importlib.resources

* normalize

* Utilize importlib.resources for listing collections

* collections_path is already in config, just use config

* install uses a different default for collections_path

* Remove unused import

* Remove duplicate __truediv__

* Bring back TraversableResources

* Apply some small suggestions from code review

Co-authored-by: Sviatoslav Sydorenko <wk.cvs.github@sydorenko.org.ua>
Co-authored-by: Matt Davis <6775756+nitzmahone@users.noreply.github.com>

* Remove cross contamination between plugin loader code and CLI code

* Remove unused import

Co-authored-by: Sviatoslav Sydorenko <wk.cvs.github@sydorenko.org.ua>
Co-authored-by: Matt Davis <6775756+nitzmahone@users.noreply.github.com>
1 year ago
..
_vendor Use unittest.mock instead of mock. (#77883) 2 years ago
ansible_test Avoid deprecated method in unit tests. 2 years ago
cli Add support for importlib.resources (#78915) 1 year ago
compat Remove unit test Python 2.6 compat. (#78369) 2 years ago
config Yolo (#77554) 2 years ago
errors Clean up unit tests. (#78498) 2 years ago
executor Add support for importlib.resources (#78915) 1 year ago
galaxy Add support for importlib.resources (#78915) 1 year ago
inventory Fix pytest collection during test_host partial run 2 years ago
inventory_test_data/group_vars Merge branch 'v2_final' into devel_switch_v2 9 years ago
mock Use unittest.mock instead of mock. (#77883) 2 years ago
module_utils Allow test to run on system with selinux enabled. Fixes #77564 (#79510) 1 year ago
modules Prefer unittest.mock over mock. (#77886) 2 years ago
parsing Add support for importlib.resources (#78915) 1 year ago
playbook Add support for importlib.resources (#78915) 1 year ago
plugins Add support for importlib.resources (#78915) 1 year ago
regex Add toggle to control invalid character substitution in group names (#52748) 5 years ago
template Add support for importlib.resources (#78915) 1 year ago
utils Add support for importlib.resources (#78915) 1 year ago
vars Use unittest.mock instead of mock. (#77883) 2 years ago
__init__.py Add empty-init code-smell script. (#18406) 8 years ago
requirements.txt Update unit test controller requirements. (#78376) 2 years ago
test_constants.py Remove some constants.py deprecated items (#70466) 4 years ago
test_context.py Clean up unit test boilerplate. 4 years ago
test_no_tty.py ansible-test - Fix subprocess management. (#77641) 2 years ago