Improve artifact availability UX
CI / php-store (push) Waiting to run
CI / python-components (push) Waiting to run

This commit is contained in:
2026-08-24 22:42:56 +02:00
parent 3028bf522c
commit 0440b6a48f
12 changed files with 85 additions and 23 deletions
+21
View File
@@ -58,6 +58,27 @@ class URLPolicyTests(unittest.TestCase):
with self.assertRaises(StoreClientError):
plugin.select_release("4.6.9")
def test_only_verified_supported_artifacts_are_installable(self):
payload, _ = plugin_payload()
payload["releases"].append(
{
"version": "1.3.0",
"download_url": "https://store.example/source.tar.gz",
"sha256": "b" * 64,
"approved": False,
"immutable": True,
"artifact_kind": "source_archive",
"min_netbox_version": "4.6.5",
"max_netbox_version": "4.6.8",
}
)
plugin = CatalogPlugin.from_mapping(payload)
self.assertEqual(
tuple(release.version for release in plugin.installable_releases("4.6.8")),
("1.2.0",),
)
class _Response(io.BytesIO):
def __init__(self, body):