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
Sam Doran 091c7c46d3 [stable-2.7] Ensure Clear Linux parsing is actually parsing a Clear Linux host and all others fall back to NA (#53298) (#53541)
* [stable-2.7] Ensure Clear Linux parsing is actually parsing a Clear Linux host and all others fall back to NA (#53298)

Fixes a bug where parse_distribution_file_ClearLinux() was called on CoreOS (and probably many other distros) and it returned True since it successfully parses the distribution file. Since this file exists on many Linux distributions and they are a very similar format, add an additional check to make sure it is Clear Linux.

Change the order in which distribution files are processed so NA is last. This prevents a match on CoreOS hosts since they also have /etc/os-release and the called matching function for NA is very general and will match CoreOS.

* Add changelog

* Add unit tests

Only add tests for Clear Linux parsing since that was the cause of this issue.
(cherry picked from commit 1d91e03119)

Co-authored-by: Sam Doran <sdoran@redhat.com>

* Use different import for 2.7
7 years ago
..
cli Fix trackback on providing arguemnt --all to ansible-doc command (#52034) 7 years ago
config Fix another corner case of too many warnings for world readable current working directory 7 years ago
contrib Update vmware_inventory (#26308) 9 years ago
errors test/: PEP8 compliancy (#24803) 9 years ago
executor Fix unittests for always adding basic to the AnsiBallZ zips 7 years ago
inventory_test_data/group_vars Merge branch 'v2_final' into devel_switch_v2 11 years ago
mock AnsiballZ improvements 8 years ago
module_utils [stable-2.7] Ensure Clear Linux parsing is actually parsing a Clear Linux host and all others fall back to NA (#53298) (#53541) 7 years ago
modules [stable-2.7] FTD HTTP Api plugin bug fixes (#47747) (#48982) 7 years ago
parsing [stable-2.7] Support nested JSON decoding in AnsibleJSONDecoder (#45924) 7 years ago
playbook [stable-2.7] Do not use mutable defaults in FieldAttribute, instead allow supplying a callable for defaults of mutable types. Fixes #46824 (#46833). 7 years ago
plugins [stable-2.7] Disallow use of remote home directories containing .. in their path (CVE-2019-3828) (#52133) (#52173) 7 years ago
template Native Jinja2: raise undefined error immediately (#52237) 7 years ago
utils [aws unit test utils] only create a recordings directory when the env var is set (#45752) 7 years ago
vars Don't use copy.deepcopy in high workload areas, use naive_deepcopy (#44337) 8 years ago
__init__.py Add empty-init code-smell script. (#18406) 9 years ago
ansible.cfg Fix ansible-test config management. 8 years ago
conftest.py Run unit tests in parallel. (#45812) 7 years ago
test_constants.py 1st part of ansible config, adds ansible-config to view/manage configs (#12797) 9 years ago