diff options
author | Sam Doran <sdoran@redhat.com> | 2021-07-12 11:34:03 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-07-12 10:34:03 -0500 |
commit | 78c7721052e0366e2540d63dcc9a20eaf350d122 (patch) | |
tree | 8dce3ce10370e04c0629fb1652d6ecf55c973bfe /changelogs | |
parent | 420527bebfe535ecb646b5f40e347b767560a6ce (diff) | |
download | ansible-78c7721052e0366e2540d63dcc9a20eaf350d122.tar.gz |
[stable-2.11] slurp - improve error code and test coverage (#75038) (#75045)
* Improve the error handling code
Rather than multiple return paths, have a single return and set the message based
on the type of failure.
* Add another test for non-specific failures
* Reorganize tests so failure tests are in one tasks file
* Remove os.stat() call and add changelog.
(cherry picked from commit afe6eb574ef8e53e805cc1ff2b25dd9108b29e1c)
Co-authored-by: Sam Doran <sdoran@redhat.com>
Diffstat (limited to 'changelogs')
-rw-r--r-- | changelogs/fragments/slurp-improve-error-handling-readability.yml | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/changelogs/fragments/slurp-improve-error-handling-readability.yml b/changelogs/fragments/slurp-improve-error-handling-readability.yml new file mode 100644 index 0000000000..099c5b3e64 --- /dev/null +++ b/changelogs/fragments/slurp-improve-error-handling-readability.yml @@ -0,0 +1,2 @@ +bugfixes: + - slurp - improve the logic in the error handling and remove ``os.stat()`` call (https://github.com/ansible/ansible/pull/75038) |