File tree Expand file tree Collapse file tree 2 files changed +7
-2
lines changed Expand file tree Collapse file tree 2 files changed +7
-2
lines changed Original file line number Diff line number Diff line change @@ -375,7 +375,13 @@ def check_replaces_availability(bundle: Bundle) -> Iterator[CheckResult]:
375375 return
376376 delimiter = ".v" if ".v" in replaces else "."
377377 replaces_version = replaces .split (delimiter , 1 )[1 ]
378- replaces_bundle = bundle .operator .bundle (replaces_version )
378+
379+ ver_to_dir = {
380+ x .csv_operator_version : x .operator_version
381+ for x in bundle .operator .all_bundles ()
382+ }
383+ replaces_bundle = bundle .operator .bundle (ver_to_dir [replaces_version ])
384+
379385 ocp_versions_str = bundle .annotations .get ("com.redhat.openshift.versions" )
380386 replaces_ocp_version_str = replaces_bundle .annotations .get (
381387 "com.redhat.openshift.versions"
Original file line number Diff line number Diff line change 88
99@patch ("operatorcert.entrypoints.validate_catalog_format.run_command" )
1010def test_validate_catalog_format (mock_run_command : MagicMock ) -> None :
11-
1211 validate_catalog_format .validate_catalog_format ("path/to/catalogs" , "catalog1" )
1312
1413 mock_run_command .assert_called_once_with (
You can’t perform that action at this time.
0 commit comments