ansible/test/units
Toshio Kuratomi e08427a138 Correct places where match was intended
pytest.raises has two parameters, message and match.  message is meant
to be the error message that pytest gives when the tested code does not
raise the expected exception.  match is the string that pytest expects
to be a match for the repr of the exception.  Unfortunately, it seems
that message is often mistakenly used where match is meant.  Fix those
cases.

message is also deprecated so removed our usage of it.  Perhaps we
should write a sanity test later that prevents the use of
pytest.raises(message) to avoid this mistake.

seealso: https://docs.pytest.org/en/4.6-maintenance/deprecations.html#message-parameter-of-pytest-raises

Also update the exception message tested for as we're now properly
detecting that the messages have changed.

(cherry picked from commit 87601969a3)

Fix root filter test

On python-2.6 the error message is different

(cherry picked from commit 67fb3a8215)

Fix the pytest match test for python-2.6

(cherry picked from commit 8a880d6032)
2019-07-29 12:08:15 -07:00
..
cli Remove unused internal -a argument and functionality (#52602) 2019-02-19 17:49:06 -06:00
compat Move unit test compat code out of lib/ansible/. (#46996) 2018-10-12 20:01:14 -07:00
config Fix encoding issues with file paths. (#50830) 2019-01-14 13:06:47 -08:00
contrib Fix vmware_inventory unit tests so they run. 2018-10-09 22:52:04 -07:00
errors Add better error when k=v syntax is used with YAML in tasks (#41754) 2018-12-04 12:32:02 -05:00
executor Move type checking methods out of basic.py and add unit tests (#53687) 2019-03-21 09:40:19 -04:00
inventory_test_data/group_vars
mock Move unit test compat code out of lib/ansible/. (#46996) 2018-10-12 20:01:14 -07:00
module_utils [stable-2.8] Handle situation where ansible_architecure may not be defined when gathering facts (#55466) 2019-07-22 16:22:04 -07:00
modules Correct places where match was intended 2019-07-29 12:08:15 -07:00
parsing Correct places where match was intended 2019-07-29 12:08:15 -07:00
playbook Don't pollute include_variables (#54687) 2019-04-09 10:14:42 -05:00
plugins Correct places where match was intended 2019-07-29 12:08:15 -07:00
regex Add toggle to control invalid character substitution in group names (#52748) 2019-03-06 11:49:40 -05:00
template Native Jinja2: raise undefined error immediately (#52237) 2019-02-15 19:36:12 +01:00
utils [stable-2.8] Skip tests with unsatisfied deps (#55853) 2019-06-29 11:31:58 -07:00
vars Fix inventory cache interface (#50446) 2019-03-06 12:12:35 -06:00
__init__.py
ansible.cfg
conftest.py Update handling of the non_local test alias. 2019-03-22 16:05:24 -07:00
test_constants.py
test_context.py Save the command line arguments into a global context 2019-01-03 18:12:23 -08:00