28 lines
666 B
YAML
28 lines
666 B
YAML
- name: Patch with basedir
|
|
patch:
|
|
src: patch
|
|
basedir: "/opt/patch-dest"
|
|
strip: 1
|
|
register: result
|
|
ignore_errors: true
|
|
|
|
- assert:
|
|
that:
|
|
- "result.failed == true"
|
|
- "'Accessing files from outside the working dir' in result.msg"
|
|
msg: Patch must fail due to accessing files outside the working dir
|
|
|
|
- name: Patch with dest
|
|
patch:
|
|
src: patch
|
|
dest: "/opt/patch-dest/readme"
|
|
strip: 1
|
|
register: result
|
|
ignore_errors: true
|
|
|
|
- assert:
|
|
that:
|
|
- "result.failed == true"
|
|
- "'Accessing files from outside the working dir' in result.msg"
|
|
msg: Patch must fail due to accessing files outside the working dir
|