File tree Expand file tree Collapse file tree 2 files changed +18
-1
lines changed Expand file tree Collapse file tree 2 files changed +18
-1
lines changed Original file line number Diff line number Diff line change 1010 "test:integration" : " DEPLOYMENT_TYPE=YAML TEST_PLATFORM=kind CREATE_CLUSTER=true tap test/integration/kubernetes.test.ts --timeout=900" ,
1111 "test:integration:kind" : " DEPLOYMENT_TYPE=YAML TEST_PLATFORM=kind CREATE_CLUSTER=true tap test/integration/kubernetes.test.ts --timeout=900" ,
1212 "test:integration:eks" : " DEPLOYMENT_TYPE=YAML TEST_PLATFORM=eks CREATE_CLUSTER=false tap test/integration/kubernetes.test.ts --timeout=900" ,
13+ "test:integration:openshift3" : " DEPLOYMENT_TYPE=YAML TEST_PLATFORM=openshift3 CREATE_CLUSTER=true tap test/integration/kubernetes.test.ts --timeout=900" ,
1314 "test:integration:openshift4" : " DEPLOYMENT_TYPE=Operator TEST_PLATFORM=openshift4 CREATE_CLUSTER=false tap test/integration/kubernetes.test.ts --timeout=900" ,
1415 "test:coverage" : " npm run test:unit -- --coverage" ,
1516 "test:watch" : " tsc-watch --onSuccess 'npm run test:unit'" ,
Original file line number Diff line number Diff line change @@ -35,6 +35,16 @@ const eksSetup: IPlatformSetup = {
3535 setupTester : eks . setupTester ,
3636} ;
3737
38+ // Use a kind cluster pinned to a specific Kubernetes version to mimic OS3.
39+ const openshift3Setup : IPlatformSetup = {
40+ create : kind . createCluster ,
41+ loadImage : kind . loadImageInCluster ,
42+ delete : kind . deleteCluster ,
43+ config : kind . exportKubeConfig ,
44+ clean : kind . clean ,
45+ setupTester : kind . setupTester ,
46+ } ;
47+
3848const openshift4Setup : IPlatformSetup = {
3949 create : openshift4 . createCluster ,
4050 loadImage : openshift4 . returnUnchangedImageNameAndTag ,
@@ -45,11 +55,17 @@ const openshift4Setup: IPlatformSetup = {
4555} ;
4656
4757export function getKubernetesVersionForPlatform ( testPlatform : string ) : string {
48- return 'latest' ;
58+ switch ( testPlatform ) {
59+ case 'openshift3' :
60+ return 'v1.11.10' ;
61+ default :
62+ return 'latest' ;
63+ }
4964}
5065
5166export default {
5267 kind : kindSetup ,
5368 eks : eksSetup ,
69+ openshift3 : openshift3Setup ,
5470 openshift4 : openshift4Setup ,
5571} ;
You can’t perform that action at this time.
0 commit comments