@@ -6,6 +6,27 @@ def test_bake_project_api_only_podman(cookies, bake_project_api_only_podman):
66 assert result .project_path .name == "api-only"
77 assert result .project_path .is_dir ()
88 assert result .project_path .joinpath ("README.md" ).is_file ()
9+ assert result .project_path .joinpath ("requirements.txt" ).is_file ()
10+ assert result .project_path .joinpath ("requirements-dev.txt" ).is_file ()
11+ assert result .project_path .joinpath ("api_only" ).is_dir ()
12+ assert result .project_path .joinpath ("containers" ).is_dir ()
13+ assert result .project_path .joinpath ("containers" , "Containerfile" ).is_file ()
14+ assert not result .project_path .joinpath ("containers" , "Dockerfile" ).is_file ()
15+ assert not result .project_path .joinpath ("api_only" , "static" ).is_dir ()
16+ assert not result .project_path .joinpath ("api_only" , "templates" ).is_dir ()
17+ assert not result .project_path .joinpath ("api_only" , "routers" , "hello_world.py" ).is_file ()
18+
19+
20+ def test_bake_project_uv_api_only_podman (cookies , bake_project_uv_api_only_podman ):
21+ result = cookies .bake (extra_context = bake_project_uv_api_only_podman )
22+
23+ assert result .exit_code == 0
24+ assert result .exception is None
25+ assert result .project_path .name == "api-only"
26+ assert result .project_path .is_dir ()
27+ assert result .project_path .joinpath ("README.md" ).is_file ()
28+ assert not result .project_path .joinpath ("requirements.txt" ).is_file ()
29+ assert not result .project_path .joinpath ("requirements-dev.txt" ).is_file ()
930 assert result .project_path .joinpath ("api_only" ).is_dir ()
1031 assert result .project_path .joinpath ("containers" ).is_dir ()
1132 assert result .project_path .joinpath ("containers" , "Containerfile" ).is_file ()
@@ -23,6 +44,27 @@ def test_bake_project_api_only_docker(cookies, bake_project_api_only_docker):
2344 assert result .project_path .name == "api-only"
2445 assert result .project_path .is_dir ()
2546 assert result .project_path .joinpath ("README.md" ).is_file ()
47+ assert result .project_path .joinpath ("requirements.txt" ).is_file ()
48+ assert result .project_path .joinpath ("requirements-dev.txt" ).is_file ()
49+ assert result .project_path .joinpath ("api_only" ).is_dir ()
50+ assert result .project_path .joinpath ("containers" ).is_dir ()
51+ assert not result .project_path .joinpath ("containers" , "Containerfile" ).is_file ()
52+ assert result .project_path .joinpath ("containers" , "Dockerfile" ).is_file ()
53+ assert not result .project_path .joinpath ("api_only" , "static" ).is_dir ()
54+ assert not result .project_path .joinpath ("api_only" , "templates" ).is_dir ()
55+ assert not result .project_path .joinpath ("api_only" , "routers" , "hello_world.py" ).is_file ()
56+
57+
58+ def test_bake_project_uv_api_only_docker (cookies , bake_project_uv_api_only_docker ):
59+ result = cookies .bake (extra_context = bake_project_uv_api_only_docker )
60+
61+ assert result .exit_code == 0
62+ assert result .exception is None
63+ assert result .project_path .name == "api-only"
64+ assert result .project_path .is_dir ()
65+ assert result .project_path .joinpath ("README.md" ).is_file ()
66+ assert not result .project_path .joinpath ("requirements.txt" ).is_file ()
67+ assert not result .project_path .joinpath ("requirements-dev.txt" ).is_file ()
2668 assert result .project_path .joinpath ("api_only" ).is_dir ()
2769 assert result .project_path .joinpath ("containers" ).is_dir ()
2870 assert not result .project_path .joinpath ("containers" , "Containerfile" ).is_file ()
@@ -40,6 +82,27 @@ def test_bake_project_api_with_webpages_podman(cookies, bake_project_api_with_we
4082 assert result .project_path .name == "api-with-webpages"
4183 assert result .project_path .is_dir ()
4284 assert result .project_path .joinpath ("README.md" ).is_file ()
85+ assert result .project_path .joinpath ("requirements.txt" ).is_file ()
86+ assert result .project_path .joinpath ("requirements-dev.txt" ).is_file ()
87+ assert result .project_path .joinpath ("api_with_webpages" ).is_dir ()
88+ assert result .project_path .joinpath ("containers" ).is_dir ()
89+ assert result .project_path .joinpath ("containers" , "Containerfile" ).is_file ()
90+ assert not result .project_path .joinpath ("containers" , "Dockerfile" ).is_file ()
91+ assert result .project_path .joinpath ("api_with_webpages" , "static" ).is_dir ()
92+ assert result .project_path .joinpath ("api_with_webpages" , "templates" ).is_dir ()
93+ assert result .project_path .joinpath ("api_with_webpages" , "routers" , "hello_world.py" ).is_file ()
94+
95+
96+ def test_bake_project_uv_api_with_webpages_podman (cookies , bake_project_uv_api_with_webpages_podman ):
97+ result = cookies .bake (extra_context = bake_project_uv_api_with_webpages_podman )
98+
99+ assert result .exit_code == 0
100+ assert result .exception is None
101+ assert result .project_path .name == "api-with-webpages"
102+ assert result .project_path .is_dir ()
103+ assert result .project_path .joinpath ("README.md" ).is_file ()
104+ assert not result .project_path .joinpath ("requirements.txt" ).is_file ()
105+ assert not result .project_path .joinpath ("requirements-dev.txt" ).is_file ()
43106 assert result .project_path .joinpath ("api_with_webpages" ).is_dir ()
44107 assert result .project_path .joinpath ("containers" ).is_dir ()
45108 assert result .project_path .joinpath ("containers" , "Containerfile" ).is_file ()
@@ -57,6 +120,27 @@ def test_bake_project_api_with_webpages_docker(cookies, bake_project_api_with_we
57120 assert result .project_path .name == "api-with-webpages"
58121 assert result .project_path .is_dir ()
59122 assert result .project_path .joinpath ("README.md" ).is_file ()
123+ assert result .project_path .joinpath ("requirements.txt" ).is_file ()
124+ assert result .project_path .joinpath ("requirements-dev.txt" ).is_file ()
125+ assert result .project_path .joinpath ("api_with_webpages" ).is_dir ()
126+ assert result .project_path .joinpath ("containers" ).is_dir ()
127+ assert not result .project_path .joinpath ("containers" , "Containerfile" ).is_file ()
128+ assert result .project_path .joinpath ("containers" , "Dockerfile" ).is_file ()
129+ assert result .project_path .joinpath ("api_with_webpages" , "static" ).is_dir ()
130+ assert result .project_path .joinpath ("api_with_webpages" , "templates" ).is_dir ()
131+ assert result .project_path .joinpath ("api_with_webpages" , "routers" , "hello_world.py" ).is_file ()
132+
133+
134+ def test_bake_project_uv_api_with_webpages_docker (cookies , bake_project_uv_api_with_webpages_docker ):
135+ result = cookies .bake (extra_context = bake_project_uv_api_with_webpages_docker )
136+
137+ assert result .exit_code == 0
138+ assert result .exception is None
139+ assert result .project_path .name == "api-with-webpages"
140+ assert result .project_path .is_dir ()
141+ assert result .project_path .joinpath ("README.md" ).is_file ()
142+ assert not result .project_path .joinpath ("requirements.txt" ).is_file ()
143+ assert not result .project_path .joinpath ("requirements-dev.txt" ).is_file ()
60144 assert result .project_path .joinpath ("api_with_webpages" ).is_dir ()
61145 assert result .project_path .joinpath ("containers" ).is_dir ()
62146 assert not result .project_path .joinpath ("containers" , "Containerfile" ).is_file ()
0 commit comments