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
Alex Willmer 163819efa2
tests: Fix `test_ansible_version()` when run within a git checkout (#78636)
When running the unit tests locally, in a git clone, `ansible --test`
prints additional information about the git revision, e.g.

```
~/src/ansible$ ansible --version
ansible 2.10.8
...
~/src/ansible$ source hacking/env-setup
...

Setting up Ansible to run out of checkout...
...
~/src/ansible$ ansible --version
[WARNING]: You are running the development version of Ansible. You
should only run Ansible from "devel" if you are modifying the Ansible
engine, or trying out features under development. This is a rapidly
changing source of code and can become unstable at any point.
ansible [core 2.14.0.dev0] (test_ansible_version-devel df497ea13b) last
updated 2022/08/25 10:37:07 (GMT +100)
...
```

which causes `test_ansible_version()` to fail.

Also removed an unused argument from previous parameterisation.

Co-authored-by: Alex Willmer <alex.willmer@cgi.com>
2 years ago
..
_vendor Use unittest.mock instead of mock. (#77883) 3 years ago
ansible_test Avoid deprecated method in unit tests. 3 years ago
cli tests: Fix `test_ansible_version()` when run within a git checkout (#78636) 2 years ago
compat Remove unit test Python 2.6 compat. (#78369) 2 years ago
config Yolo (#77554) 3 years ago
errors Clean up unit tests. (#78498) 2 years ago
executor Replace get_persistent_connection_options in task_executor with get_options (#74446) 2 years ago
galaxy Add --offline option to 'ansible-galaxy collection install' (#78678) 2 years 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 10 years ago
mock Use unittest.mock instead of mock. (#77883) 3 years ago
module_utils Add OSMC to Debian OS_FAMILY_MAP (#78778) 2 years ago
modules Prefer unittest.mock over mock. (#77886) 3 years ago
parsing Remove unit test pytz requirement. (#78368) 2 years ago
playbook Use classproperty to access field attributes of a class (#78180) 2 years ago
plugins add ansible_name/ansible_aliases attrs to plugin objects (#78700) 2 years ago
regex Add toggle to control invalid character substitution in group names (#52748) 6 years ago
template Use unittest.mock instead of mock. (#77883) 3 years ago
utils Skip test if no there are no problematic chars for wcswidth (#78645) 2 years ago
vars Use unittest.mock instead of mock. (#77883) 3 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. 5 years ago
test_no_tty.py ansible-test - Fix subprocess management. (#77641) 3 years ago