File: custom_python_new_style_module.yml

package info (click to toggle)
python-mitogen 0.3.3-9%2Bdeb12u1
  • links: PTS, VCS
  • area: main
  • in suites: bookworm
  • size: 6,816 kB
  • sloc: python: 22,086; sh: 171; makefile: 74; perl: 19; ansic: 18; javascript: 5
file content (32 lines) | stat: -rw-r--r-- 882 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
- name: integration/runner/custom_python_new_style_module.yml
  hosts: test-targets
  any_errors_fatal: true
  tasks:
    # without Mitogen Ansible 2.10 hangs on this play
    - meta: end_play
      when: not is_mitogen

    - custom_python_new_style_module:
        foo: true
      with_sequence: start=0 end={{end|default(1)}}
      register: out

    - assert:
        that:
        - "not out.changed"
        - "not out.results[0].changed"
        # Random breaking interface change since 2.7.x
        #- "out.results[0].input[0].ANSIBLE_MODULE_ARGS.foo"
        - "out.results[0].msg == 'Here is my input'"
        fail_msg: out={{out}}

    # Verify sys.argv is not Unicode.
    - custom_python_detect_environment:
      register: out

    - assert:
        that:
          - out.argv_types_correct
        fail_msg: out={{out}}
  tags:
    - custom_python_new_style_module