fix(oci): normalize pinned references for registry inspection

This commit is contained in:
Jonatan
2026-10-28 10:10:57 +01:00
parent e587aa7d79
commit 3d1c542a05
3 changed files with 99 additions and 7 deletions
+2 -1
View File
@@ -111,7 +111,8 @@ class OciWordingTests(TestCase):
def test_registry_nonzero_and_success_command_unchanged(self):
result = SimpleNamespace(returncode=1, stdout='', stderr='connection timed out')
run = Mock(return_value=result)
report = function(CUSTOM, 'registry_report', subprocess=SimpleNamespace(run=run))
report = function(CUSTOM, 'registry_report', subprocess=SimpleNamespace(run=run),
_registry_lookup=lambda reference: reference)
self.assertEqual(report('example:latest'),
(False, 'Could not inspect the image in its registry: example:latest'))
run.assert_called_once_with(['skopeo', 'inspect', '--raw', 'docker://example:latest'],