community.internal_test_tools._fetch_url_test_module module – Test module for fetch_url test framework (DO NOT USE THIS!)

Note

This module is part of the community.internal_test_tools collection (version 0.12.0).

It is not included in ansible-core. To check whether it is installed, run ansible-galaxy collection list.

To install it, use: ansible-galaxy collection install community.internal_test_tools.

To use it in a playbook, specify: community.internal_test_tools._fetch_url_test_module.

New in community.internal_test_tools 0.1.1

Synopsis

  • DO NOT USE THIS!

Parameters

Parameter

Comments

call_sequence

list / elements=dictionary / required

List of HTTP calls to make.

data

string

Data to send (Base64 encoded).

Mutually exclusive with call_sequence[].data_path.

data_path

path

added in community.internal_test_tools 0.3.0

File to read data from.

Mutually exclusive with call_sequence[].data.

force_basic_auth

boolean

added in community.internal_test_tools 0.7.0

Force passing Authorization header on the first request when call_sequence[].url_username and call_sequence[].url_password are used.

Choices:

  • false

  • true

headers

dictionary

HTTP headers.

method

string

HTTP method.

Default: "GET"

timeout

float

added in community.internal_test_tools 0.7.0

Timeout in seconds

url

string / required

The URL.

url_password

string

added in community.internal_test_tools 0.7.0

The password for use with HTTP Basic Authentication.

url_username

string

added in community.internal_test_tools 0.7.0

The username for use with HTTP Basic Authentication.

fail_me

boolean

added in community.internal_test_tools 0.3.0

If set to true, fails the module.

Choices:

  • false ← (default)

  • true

set_changed

boolean

added in community.internal_test_tools 0.3.0

If set to true, claims the module changed something.

Choices:

  • false ← (default)

  • true

Notes

Note

  • Does not support check_mode.

Examples

- name: Does nothing
  community.internal_test_tools.fetch_url_test_module:
    call_sequence: []

Return Values

Common return values are documented here, the following are the fields unique to this module:

Key

Description

call_results

list / elements=dictionary

Results of HTTP calls.

Returned: success

Sample: [{"content": "1.2.3.4", "headers": {}, "status": 200}]

content

string

Content (Base64 encoded).

Returned: success

Sample: "1.2.3.4"

headers

dictionary

Headers.

Returned: success

Sample: {}

status

integer

HTTP status of request.

Returned: success

Sample: 200

Authors

  • Felix Fontein (@felixfontein)