summaryrefslogtreecommitdiff
path: root/test/integration
diff options
context:
space:
mode:
authorJordan Borean <jborean93@gmail.com>2018-01-19 11:42:20 +1000
committerToshio Kuratomi <a.badger@gmail.com>2018-01-31 17:31:51 -0800
commit159b0f628d6fe838b007ab8efc2039d9822c69f1 (patch)
tree51f9a6ec6a8e9c6a1a9df6c6754181bf5f758e4c /test/integration
parent02e5c0d0ca2cf56c0a45e9814403dab57a29d8dc (diff)
downloadansible-159b0f628d6fe838b007ab8efc2039d9822c69f1.tar.gz
copy tests: only create recursive symlink in tests (#35073)
(cherry picked from commit 9106284c1ce4b7b298ec0c5d87ac372917e7eb94)
Diffstat (limited to 'test/integration')
l---------test/integration/targets/copy/files/subdir/subdir1/circles1
-rw-r--r--test/integration/targets/copy/tasks/main.yml15
2 files changed, 15 insertions, 1 deletions
diff --git a/test/integration/targets/copy/files/subdir/subdir1/circles b/test/integration/targets/copy/files/subdir/subdir1/circles
deleted file mode 120000
index b870225aa0..0000000000
--- a/test/integration/targets/copy/files/subdir/subdir1/circles
+++ /dev/null
@@ -1 +0,0 @@
-../ \ No newline at end of file
diff --git a/test/integration/targets/copy/tasks/main.yml b/test/integration/targets/copy/tasks/main.yml
index 274712a7e7..9b48afab6f 100644
--- a/test/integration/targets/copy/tasks/main.yml
+++ b/test/integration/targets/copy/tasks/main.yml
@@ -10,6 +10,15 @@
# output_dir is hardcoded in test/runner/lib/executor.py and created there
remote_dir: '{{ output_dir }}'
+ - file: path={{local_temp_dir}} state=directory
+ name: ensure temp dir exists
+
+ # file cannot do this properly, use command instead
+ - name: Create ciruclar symbolic link
+ command: ln -s ../ circles
+ args:
+ chdir: '{{role_path}}/files/subdir/subdir1'
+
- name: Create remote unprivileged remote user
user:
name: '{{ remote_unprivileged_user }}'
@@ -46,6 +55,12 @@
state: absent
connection: local
+ - name: Remove circular symbolic link
+ file:
+ path: subdir/subdir1/circles
+ state: absent
+ connection: local
+
- name: Remote unprivileged remote user
user:
name: '{{ remote_unprivileged_user }}'