2018-04-18 14:43:54 +00:00
|
|
|
- name: integration/runner__custom_binary_single_null.yml
|
2018-04-22 18:40:58 +00:00
|
|
|
hosts: test-targets
|
2018-04-02 07:05:37 +00:00
|
|
|
tasks:
|
2018-04-18 14:43:54 +00:00
|
|
|
- custom_binary_single_null:
|
2018-04-02 07:05:37 +00:00
|
|
|
foo: true
|
2018-04-04 19:01:23 +00:00
|
|
|
with_sequence: start=1 end={{end|default(1)}}
|
2018-04-02 07:05:37 +00:00
|
|
|
ignore_errors: true
|
2018-04-04 19:01:23 +00:00
|
|
|
register: out
|
|
|
|
|
2018-04-22 18:40:58 +00:00
|
|
|
- hosts: test-targets
|
2018-04-04 23:11:29 +00:00
|
|
|
any_errors_fatal: true
|
|
|
|
tasks:
|
2018-04-04 19:01:23 +00:00
|
|
|
- assert:
|
2018-04-17 14:02:21 +00:00
|
|
|
that:
|
|
|
|
- "out.failed"
|
|
|
|
- "out.results[0].failed"
|
|
|
|
- "out.results[0].msg == 'MODULE FAILURE'"
|
|
|
|
- "out.results[0].module_stdout.startswith('/bin/sh: ')"
|
|
|
|
- |
|
|
|
|
out.results[0].module_stdout.endswith('/custom_binary_single_null: cannot execute binary file\r\n') or
|
|
|
|
out.results[0].module_stdout.endswith('/custom_binary_single_null: Exec format error\r\n')
|
2018-04-04 23:41:14 +00:00
|
|
|
|
|
|
|
|
|
|
|
# Can't test this: Mitogen returns 126, 2.5.x returns 126, 2.4.x discarded the
|
|
|
|
# return value and always returned 0.
|
|
|
|
# out.results[0].rc == 126
|