fix: 更新包过大时分段上传并自动拼回
This commit is contained in:
+14
-1
@@ -24,7 +24,20 @@ def test_release_needs_the_package_asset() -> None:
|
||||
assert found is not None
|
||||
assert found["latest"] == "0.1.1"
|
||||
assert "http" not in found["notes"]
|
||||
assert found["url"].endswith(".zip")
|
||||
assert found["urls"] == ["https://example.com/app.zip"]
|
||||
parts = describe_release(
|
||||
{
|
||||
"tag_name": "v0.1.2",
|
||||
"body": "",
|
||||
"assets": [
|
||||
{"name": "VideosDownTools-windows-x64.zip.part002", "browser_download_url": "https://example.com/b"},
|
||||
{"name": "VideosDownTools-windows-x64.zip.part001", "browser_download_url": "https://example.com/a"},
|
||||
],
|
||||
},
|
||||
current,
|
||||
)
|
||||
assert parts is not None
|
||||
assert parts["urls"] == ["https://example.com/a", "https://example.com/b"]
|
||||
assert describe_release({"tag_name": "v0.1.0", "assets": [{"name": "VideosDownTools-windows-x64.zip", "browser_download_url": "https://example.com/app.zip"}]}, current) is None
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user