@@ -66,18 +66,17 @@ suite(`Login to Openshift console and start WebTerminal ${BASE_TEST_CONSTANTS.TE
66
66
expect ( commandResult ) . contains ( 'admin' ) ;
67
67
} ) ;
68
68
test ( 'Verify help command under admin user' , async function ( ) : Promise < void > {
69
- const helpCommandExpectedResult : string =
70
- 'oc.*\\d+\\.\\d+\\.\\d+.*OpenShift CLI\n' +
71
- 'kubectl.*\\d+\\.\\d+\\.\\d+.*Kubernetes CLI\n' +
72
- 'kustomize.*\\d+\\.\\d+\\.\\d+.*Kustomize CLI\n' +
73
- 'helm.*\\d+\\.\\d+\\.\\d+.*Helm CLI\n' +
74
- 'kn.*\\d+\\.\\d+\\.\\d+.*KNative CLI\n' +
75
- 'tkn.*\\d+\\.\\d+\\.\\d+.*Tekton CLI\n' +
76
- 'subctl.*\\d+\\.\\d+\\.\\d+.*Submariner CLI\n' +
77
- 'odo.*\\d+\\.\\d+\\.\\d+.*Red Hat OpenShift Developer CLI\n' +
78
- 'virtctl.*\\d+\\.\\d+\\.\\d+.*KubeVirt CLI\n' +
79
- 'rhoas.*\\d+\\.\\d+\\.\\d+.*Red Hat OpenShift Application Services CLI\n' +
80
- 'jq.*\\d+\\.\\d+.*jq' ;
69
+ const expectedStrings : string [ ] = [
70
+ 'OpenShift CLI' ,
71
+ 'Kubernetes CLI' ,
72
+ 'Kustomize CLI (built-in to kubectl)' ,
73
+ 'Helm CLI' ,
74
+ 'KNative CLI' ,
75
+ 'Tekton CLI' ,
76
+ 'Submariner CLI' ,
77
+ 'KubeVirt CLI' ,
78
+ 'jq'
79
+ ] ;
81
80
82
81
await webTerminal . typeAndEnterIntoWebTerminal ( `help > ${ fileForVerificationTerminalCommands } ` ) ;
83
82
@@ -87,7 +86,10 @@ suite(`Login to Openshift console and start WebTerminal ${BASE_TEST_CONSTANTS.TE
87
86
`cat /home/user/${ fileForVerificationTerminalCommands } ` ,
88
87
webTerminalToolContainerName
89
88
) ;
90
- expect ( commandResult ) . to . match ( new RegExp ( helpCommandExpectedResult ) ) ;
89
+
90
+ expectedStrings . forEach ( ( expectedString ) : void => {
91
+ expect ( commandResult ) . to . contain ( expectedString ) ;
92
+ } ) ;
91
93
} ) ;
92
94
93
95
test ( 'Verify help command under admin user' , async function ( ) : Promise < void > {
0 commit comments