1
0
Fork 0
mirror of https://github.com/containers/ansible-podman-collections.git synced 2026-02-04 07:11:49 +00:00

Add new options for podman_container (#750)

Signed-off-by: Sagi Shnaidman <sshnaidm@redhat.com>
This commit is contained in:
Sergey 2024-05-22 14:30:28 +03:00 committed by GitHub
parent a9e92c902b
commit 2f5da14c30
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
13 changed files with 1376 additions and 410 deletions

View file

@ -66,7 +66,15 @@ def test_container_add_params(test_input, expected):
[
None, # module
{"conmon_pidfile": "bbb"}, # module params
{"conmonpidfile": "ccc"}, # container info
{"conmonpidfile": "ccc",
"config": {
"createcommand": [
"podman",
"create",
"--conmon-pidfile=ccc",
"testcont",
]}
}, # container info
{}, # image info
"4.1.1", # podman version
],
@ -76,7 +84,67 @@ def test_container_add_params(test_input, expected):
[
None, # module
{"conmon_pidfile": None}, # module params
{"conmonpidfile": "ccc"}, # container info
{"conmonpidfile": "ccc",
"config": {
"createcommand": [
"podman",
"create",
"--conmon-pidfile=ccc",
"testcont",
]}
}, # container info
{}, # image info
"4.1.1", # podman version
],
True,
),
(
[
None, # module
{"conmon_pidfile": None}, # module params
{"conmonpidfile": None,
"config": {
"createcommand": [
"podman",
"create",
"testcont",
]}
}, # container info
{}, # image info
"4.1.1", # podman version
],
False,
),
(
[
None, # module
{"conmon_pidfile": 'aaa'}, # module params
{"conmonpidfile": None,
"config": {
"createcommand": [
"podman",
"create",
"testcont",
]}
}, # container info
{}, # image info
"4.1.1", # podman version
],
True,
),
(
[
None, # module
{"conmon_pidfile": 'aaa'}, # module params
{"conmonpidfile": 'aaa',
"config": {
"createcommand": [
"podman",
"create",
"--conmon-pidfile=aaa",
"testcont",
]}
}, # container info
{}, # image info
"4.1.1", # podman version
],