1
0
Fork 0
mirror of https://github.com/ansible-collections/community.general.git synced 2024-09-14 20:13:21 +02:00
community.general/test/units
Marc Abramowitz 372a29744b Make AnsibleError a plain ol' exception
Python's Exception constructor already takes a `message` as a parameter,
which you can then get at by doing str(e) (e.message was deprecated).

The reason I bothered to make this change was because I was debugging
with pdb and I noticed that AnsibleErrors don't give useful information
in pdb (probably because they don't have a __repr__ method that prints
the `msg` attribute).

    (Pdb) c
    > /Users/marca/dev/git-repos/ansible/lib/ansible/runner/__init__.py(599)_executor()
    -> msg = str(ae)
    (Pdb) ae
    AnsibleError()
2015-01-29 10:36:06 -08:00
..
inventory_test_data Add stub tests for module args parsing. 2014-10-07 17:00:01 -04:00
module_tests Docker test does not require the mock module 2014-11-14 08:59:36 -08:00
vault_test_data Make VaultEditor Tests compatible with FIPS mode 2014-11-12 12:05:25 -08:00
ansible.cfg Rename tests to test, use old directory name. 2014-02-20 19:11:15 -05:00
README.md Rename tests to test, use old directory name. 2014-02-20 19:11:15 -05:00
TestConstants.py Rename tests to test, use old directory name. 2014-02-20 19:11:15 -05:00
TestFilters.py Add filter to turn a string into a UUID 2015-01-21 08:07:17 +08:00
TestInventory.py Merge branch 'svg_and_inventory_refactor' into devel 2014-07-10 14:43:07 -05:00
TestModules.py Update module test code to avoid pycs (that are not used) 2014-09-26 10:57:12 -04:00
TestModuleUtilsBasic.py typofixes - https://github.com/vlajos/misspell_fixer 2014-12-04 22:23:35 +00:00
TestModuleUtilsDatabase.py Exception message changes 2014-11-25 02:36:38 -08:00
TestPlayVarsFiles.py Split out various vars-related things to avoid merging too early 2014-11-17 15:31:55 -06:00
TestSynchronize.py fixed typos found by RETF rules in PY files 2014-05-03 18:40:05 +02:00
TestUtils.py Make AnsibleError a plain ol' exception 2015-01-29 10:36:06 -08:00
TestUtilsStringFunctions.py Unit tests for ansible.utils 2014-03-14 10:38:33 -05:00
TestVault.py Skip some md5 related unit tests when running in fips mode 2014-11-12 11:47:11 -08:00
TestVaultEditor.py Make VaultEditor Tests compatible with FIPS mode 2014-11-12 12:05:25 -08:00

Unit tests

Tests at code level. Should be concise and to the point, and organized by subject.