mirror of
https://github.com/ansible-collections/community.general.git
synced 2025-07-24 05:40:23 -07:00
Cause copy module to fail on empty string as source (#27975)
* Fail if an empty string is set as src for copy module Fixes #27363 * Cleanup task formatting on copy tests Use multi-line YAML Add debug statements with verbosity: 1 rather than leave them in there commented out. * Add test for empty string as source * Do more checks in order to add more specific errors messages Add more integration tests for the various failure scenarios. Cleanup some syntax on existing integration test tasks.
This commit is contained in:
parent
d69440c4ef
commit
a8e4c9be7a
3 changed files with 434 additions and 212 deletions
|
@ -10,7 +10,7 @@
|
|||
# output_dir is hardcoded in test/runner/lib/executor.py and created there
|
||||
remote_dir: '{{ output_dir }}'
|
||||
|
||||
- name: create remote unprivileged remote user
|
||||
- name: Create remote unprivileged remote user
|
||||
user:
|
||||
name: '{{ remote_unprivileged_user }}'
|
||||
register: user
|
||||
|
@ -21,7 +21,7 @@
|
|||
state: directory
|
||||
mode: 0700
|
||||
|
||||
- name: 'duplicate authorized_keys'
|
||||
- name: Duplicate authorized_keys
|
||||
copy:
|
||||
src: $HOME/.ssh/authorized_keys
|
||||
dest: '{{ user.home }}/.ssh/authorized_keys'
|
||||
|
@ -46,7 +46,7 @@
|
|||
state: absent
|
||||
connection: local
|
||||
|
||||
- name: remote unprivileged remote user
|
||||
- name: Remote unprivileged remote user
|
||||
user:
|
||||
name: '{{ remote_unprivileged_user }}'
|
||||
state: absent
|
||||
|
|
File diff suppressed because it is too large
Load diff
Loading…
Add table
Add a link
Reference in a new issue