diff --git a/tests/test_module.py b/tests/test_module.py new file mode 100644 index 0000000..136b7a9 --- /dev/null +++ b/tests/test_module.py @@ -0,0 +1,5 @@ +import os + + +def test_module(): + assert os.system("python -m compose_viz") == 0 diff --git a/tests/test_parse_file.py b/tests/test_parse_file.py index f91249d..56f8b21 100644 --- a/tests/test_parse_file.py +++ b/tests/test_parse_file.py @@ -1551,4 +1551,9 @@ def test_parse_file(test_input: str, expected: Compose) -> None: assert actual_service.volumes == expected_service.volumes assert actual_service.depends_on == expected_service.depends_on assert actual_service.links == expected_service.links - assert actual_service.extends == expected_service.extends + + assert (actual_service.extends is not None) == (expected_service.extends is not None) + + if (actual_service.extends is not None) and (expected_service.extends is not None): + assert actual_service.extends.service_name == expected_service.extends.service_name + assert actual_service.extends.from_file == expected_service.extends.from_file