From c8b69c73a9a84d045da87ac348f90f9edc415e5d Mon Sep 17 00:00:00 2001 From: ldericher <40151420+ldericher@users.noreply.github.com> Date: Thu, 2 Dec 2021 17:32:55 +0100 Subject: [PATCH] Fix pytests --- tests/test_project.py | 2 ++ tests/test_service.py | 4 ++++ tests/test_services.py | 1 + 3 files changed, 7 insertions(+) diff --git a/tests/test_project.py b/tests/test_project.py index f6fabff..6247950 100644 --- a/tests/test_project.py +++ b/tests/test_project.py @@ -13,6 +13,7 @@ class TestDefault: def test_example(self): p = Project( directory=Path("example/hello-world.project"), + parent=None, ) ss = p.services @@ -30,6 +31,7 @@ class TestDefault: def test_empty(self): p = Project( directory=Path("nonexistent"), + parent=None, ) with pytest.raises(FileNotFoundError) as exc_info: diff --git a/tests/test_service.py b/tests/test_service.py index 9206374..4024bdd 100644 --- a/tests/test_service.py +++ b/tests/test_service.py @@ -10,6 +10,7 @@ class TestDefault: s = Service( name="s", content=CommentedMap(), + parent=None, ) assert s.name == "s" @@ -21,6 +22,7 @@ class TestDefault: content=CommentedMap({ "image": "repo/image:tag", }), + parent=None, ) assert s.name == "s" @@ -37,6 +39,7 @@ class TestDefault: "$TARGETDIR/other/dir:/path/to/other/mountpoint", ] }), + parent=None, ) assert s.name == "s" @@ -52,6 +55,7 @@ class TestDefault: "$CONFDIR/other/config:/path/to/other/config", ] }), + parent=None, ) assert s.name == "s" diff --git a/tests/test_services.py b/tests/test_services.py index b6dd451..151d242 100644 --- a/tests/test_services.py +++ b/tests/test_services.py @@ -9,6 +9,7 @@ class TestServices: s = Service( name="s", content=CommentedMap(), + parent=None, ) ss = Services([s])