@@ -934,8 +934,6 @@ var _ = Describe("Install Plan", func() {
934
934
mainPackageDelta := fmt .Sprintf ("%s-delta" , mainPackageName )
935
935
936
936
stableChannel := "stable"
937
- betaChannel := "beta"
938
- deltaChannel := "delta"
939
937
940
938
// Create manifests
941
939
mainManifests := []registry.PackageManifest {
@@ -998,30 +996,17 @@ var _ = Describe("Install Plan", func() {
998
996
{
999
997
PackageName : mainPackageName ,
1000
998
Channels : []registry.PackageChannel {
1001
- {Name : stableChannel , CurrentCSVName : mainPackageStable },
1002
- {Name : betaChannel , CurrentCSVName : mainPackageBeta },
999
+ {Name : stableChannel , CurrentCSVName : mainPackageBeta },
1003
1000
},
1004
- DefaultChannelName : betaChannel ,
1001
+ DefaultChannelName : stableChannel ,
1005
1002
},
1006
1003
}
1007
1004
1008
1005
updateInternalCatalog (GinkgoT (), c , crc , mainCatalogSourceName , testNamespace , []apiextensions.CustomResourceDefinition {* tt .intermediateCRD }, []operatorsv1alpha1.ClusterServiceVersion {mainStableCSV , mainBetaCSV }, mainManifests )
1009
-
1010
1006
// Attempt to get the catalog source before creating install plan(s)
1011
1007
_ , err = fetchCatalogSourceOnStatus (crc , mainCatalogSourceName , testNamespace , catalogSourceRegistryPodSynced )
1012
1008
require .NoError (GinkgoT (), err )
1013
-
1014
- // Update the subscription resource to point to the beta CSV
1015
- err = crc .OperatorsV1alpha1 ().Subscriptions (testNamespace ).DeleteCollection (context .TODO (), * metav1 .NewDeleteOptions (0 ), metav1.ListOptions {})
1016
- require .NoError (GinkgoT (), err )
1017
-
1018
- // Delete orphaned csv
1019
- require .NoError (GinkgoT (), crc .OperatorsV1alpha1 ().ClusterServiceVersions (testNamespace ).Delete (context .TODO (), mainStableCSV .GetName (), metav1.DeleteOptions {}))
1020
-
1021
- // existing cleanup should remove this
1022
- createSubscriptionForCatalog (crc , testNamespace , subscriptionName , mainCatalogSourceName , mainPackageName , betaChannel , "" , operatorsv1alpha1 .ApprovalAutomatic )
1023
-
1024
- subscription , err = fetchSubscription (crc , testNamespace , subscriptionName , subscriptionHasInstallPlanChecker )
1009
+ subscription , err = fetchSubscription (crc , testNamespace , subscriptionName , subscriptionHasInstallPlanDifferentChecker (installPlanName ))
1025
1010
require .NoError (GinkgoT (), err )
1026
1011
require .NotNil (GinkgoT (), subscription )
1027
1012
@@ -1047,35 +1032,21 @@ var _ = Describe("Install Plan", func() {
1047
1032
validateCRDVersions (GinkgoT (), c , tt .oldCRD .GetName (), expectedVersions )
1048
1033
1049
1034
// Update the manifest
1050
- mainBetaCSV = newCSV (mainPackageBeta , testNamespace , "" , semver .MustParse ("0.2.0" ), []apiextensions.CustomResourceDefinition {* tt .intermediateCRD }, nil , mainNamedStrategy )
1051
1035
mainManifests = []registry.PackageManifest {
1052
1036
{
1053
1037
PackageName : mainPackageName ,
1054
1038
Channels : []registry.PackageChannel {
1055
- {Name : betaChannel , CurrentCSVName : mainPackageBeta },
1056
- {Name : deltaChannel , CurrentCSVName : mainPackageDelta },
1039
+ {Name : stableChannel , CurrentCSVName : mainPackageDelta },
1057
1040
},
1058
- DefaultChannelName : deltaChannel ,
1041
+ DefaultChannelName : stableChannel ,
1059
1042
},
1060
1043
}
1061
1044
1062
- updateInternalCatalog (GinkgoT (), c , crc , mainCatalogSourceName , testNamespace , []apiextensions.CustomResourceDefinition {* tt .newCRD }, []operatorsv1alpha1.ClusterServiceVersion {mainBetaCSV , mainDeltaCSV }, mainManifests )
1063
-
1045
+ updateInternalCatalog (GinkgoT (), c , crc , mainCatalogSourceName , testNamespace , []apiextensions.CustomResourceDefinition {* tt .newCRD }, []operatorsv1alpha1.ClusterServiceVersion {mainStableCSV , mainBetaCSV , mainDeltaCSV }, mainManifests )
1064
1046
// Attempt to get the catalog source before creating install plan(s)
1065
1047
_ , err = fetchCatalogSourceOnStatus (crc , mainCatalogSourceName , testNamespace , catalogSourceRegistryPodSynced )
1066
1048
require .NoError (GinkgoT (), err )
1067
-
1068
- // Update the subscription resource to point to the beta CSV
1069
- err = crc .OperatorsV1alpha1 ().Subscriptions (testNamespace ).DeleteCollection (context .TODO (), * metav1 .NewDeleteOptions (0 ), metav1.ListOptions {})
1070
- require .NoError (GinkgoT (), err )
1071
-
1072
- // Delete orphaned csv
1073
- require .NoError (GinkgoT (), crc .OperatorsV1alpha1 ().ClusterServiceVersions (testNamespace ).Delete (context .TODO (), mainBetaCSV .GetName (), metav1.DeleteOptions {}))
1074
-
1075
- // existing cleanup should remove this
1076
- createSubscriptionForCatalog (crc , testNamespace , subscriptionName , mainCatalogSourceName , mainPackageName , deltaChannel , "" , operatorsv1alpha1 .ApprovalAutomatic )
1077
-
1078
- subscription , err = fetchSubscription (crc , testNamespace , subscriptionName , subscriptionHasInstallPlanChecker )
1049
+ subscription , err = fetchSubscription (crc , testNamespace , subscriptionName , subscriptionHasInstallPlanDifferentChecker (installPlanName ))
1079
1050
require .NoError (GinkgoT (), err )
1080
1051
require .NotNil (GinkgoT (), subscription )
1081
1052
0 commit comments