add test case for when build is a complex dictionary

Signed-off-by: Sergei Biriukov <svbiriukov@gmail.com>
This commit is contained in:
Sergei Biriukov
2023-04-30 15:37:52 +10:00
parent a0005db474
commit 8c66b1cda7
2 changed files with 17 additions and 5 deletions

View File

@@ -40,6 +40,21 @@ test_cases = [
{"build": {"dockerfile": "./compose-2.yaml", "context": "./dir-2"}},
{"build": {"dockerfile": "./compose-2.yaml", "context": "./dir-2"}},
),
(
{"build": {"dockerfile": "./compose-1.yaml"}},
{"build": {"dockerfile": "./compose-2.yaml", "args": ["ENV1=1"]}},
{"build": {"dockerfile": "./compose-2.yaml", "args": ["ENV1=1"]}},
),
(
{"build": {"dockerfile": "./compose-2.yaml", "args": ["ENV1=1"]}},
{"build": {"dockerfile": "./compose-1.yaml"}},
{"build": {"dockerfile": "./compose-1.yaml", "args": ["ENV1=1"]}},
),
(
{"build": {"dockerfile": "./compose-2.yaml", "args": ["ENV1=1"]}},
{"build": {"dockerfile": "./compose-1.yaml", "args": ["ENV2=2"]}},
{"build": {"dockerfile": "./compose-1.yaml", "args": ["ENV1=1", "ENV2=2"]}},
),
]