Skip to content

Commit 4f7d28e

Browse files
Feature the Windows manifest for Python 3.16+ releases (#457)
1 parent 4b35a98 commit 4f7d28e

2 files changed

Lines changed: 26 additions & 1 deletion

File tree

‎add_to_pydotorg.py‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -126,7 +126,7 @@ def get_file_descriptions(
126126
(
127127
"Windows release manifest",
128128
"windows",
129-
False,
129+
v >= (3, 16),
130130
f"Install with 'py install {v[0]}.{v[1]}'",
131131
),
132132
),

‎tests/test_add_to_pydotorg.py‎

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -284,3 +284,28 @@ def test_list_files(fs: FakeFilesystem) -> None:
284284
"Install with 'py install 3.14'",
285285
),
286286
]
287+
288+
289+
@pytest.mark.parametrize(
290+
("release", "expected_download_button"),
291+
[
292+
("3.15.0a1", False),
293+
("3.16.0a1", True),
294+
],
295+
)
296+
def test_windows_manifest_download_button(
297+
fs: FakeFilesystem, release: str, expected_download_button: bool
298+
) -> None:
299+
ftp_root = "/fake_ftp_root"
300+
filename = f"windows-{release}.json"
301+
fs.create_file(Path(ftp_root) / add_to_pydotorg.base_version(release) / filename)
302+
303+
assert list(add_to_pydotorg.list_files(ftp_root, release)) == [
304+
(
305+
filename,
306+
"Windows release manifest",
307+
"windows",
308+
expected_download_button,
309+
f"Install with 'py install {add_to_pydotorg.minor_version(release)}'",
310+
)
311+
]

0 commit comments

Comments
 (0)