@eclipse-che/che-e2e 7.74.0-dev-1d09cb7 → 7.74.0-dev-aace77a
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.eslintignore +10 -0
- package/.eslintrc.js +197 -0
- package/.prettierignore +10 -0
- package/.prettierrc.json +10 -0
- package/CODE_STYLE.md +144 -0
- package/README.md +47 -47
- package/configs/inversify.config.ts +39 -14
- package/configs/inversify.types.ts +44 -30
- package/configs/mocharc.ts +21 -24
- package/constants/API_TEST_CONSTANTS.ts +67 -0
- package/constants/BASE_TEST_CONSTANTS.ts +80 -0
- package/constants/CHROME_DRIVER_CONSTANTS.ts +42 -0
- package/constants/FACTORY_TEST_CONSTANTS.ts +61 -0
- package/constants/MONACO_CONSTANTS.ts +25 -0
- package/constants/OAUTH_CONSTANTS.ts +67 -0
- package/constants/PLUGIN_TEST_CONSTANTS.ts +15 -0
- package/constants/REPORTER_CONSTANTS.ts +53 -0
- package/constants/TIMEOUT_CONSTANTS.ts +131 -0
- package/dist/configs/inversify.config.js +36 -9
- package/dist/configs/inversify.config.js.map +1 -1
- package/dist/configs/inversify.types.js +19 -5
- package/dist/configs/inversify.types.js.map +1 -1
- package/dist/configs/mocharc.js +13 -16
- package/dist/configs/mocharc.js.map +1 -1
- package/dist/constants/{APITestConstants.js → API_TEST_CONSTANTS.js} +12 -12
- package/dist/constants/API_TEST_CONSTANTS.js.map +1 -0
- package/dist/constants/{BaseTestConstants.js → BASE_TEST_CONSTANTS.js} +16 -16
- package/dist/constants/BASE_TEST_CONSTANTS.js.map +1 -0
- package/dist/constants/CHROME_DRIVER_CONSTANTS.js +36 -0
- package/dist/constants/CHROME_DRIVER_CONSTANTS.js.map +1 -0
- package/dist/constants/{FactoryTestConstants.js → FACTORY_TEST_CONSTANTS.js} +14 -13
- package/dist/constants/FACTORY_TEST_CONSTANTS.js.map +1 -0
- package/dist/constants/{MonacoConstants.js → MONACO_CONSTANTS.js} +7 -7
- package/dist/constants/MONACO_CONSTANTS.js.map +1 -0
- package/dist/constants/{OAuthConstants.js → OAUTH_CONSTANTS.js} +14 -14
- package/dist/constants/OAUTH_CONSTANTS.js.map +1 -0
- package/dist/constants/{PluginsTestConstants.js → PLUGIN_TEST_CONSTANTS.js} +7 -7
- package/dist/constants/PLUGIN_TEST_CONSTANTS.js.map +1 -0
- package/dist/constants/{ReporterConstants.js → REPORTER_CONSTANTS.js} +12 -12
- package/dist/constants/REPORTER_CONSTANTS.js.map +1 -0
- package/dist/constants/{TimeoutConstants.js → TIMEOUT_CONSTANTS.js} +24 -24
- package/dist/constants/TIMEOUT_CONSTANTS.js.map +1 -0
- package/dist/driver/ChromeDriver.js +12 -22
- package/dist/driver/ChromeDriver.js.map +1 -1
- package/dist/index.js +18 -12
- package/dist/index.js.map +1 -1
- package/dist/pageobjects/dashboard/CreateWorkspace.js +15 -15
- package/dist/pageobjects/dashboard/CreateWorkspace.js.map +1 -1
- package/dist/pageobjects/dashboard/Dashboard.js +20 -21
- package/dist/pageobjects/dashboard/Dashboard.js.map +1 -1
- package/dist/pageobjects/dashboard/Workspaces.js +55 -60
- package/dist/pageobjects/dashboard/Workspaces.js.map +1 -1
- package/dist/pageobjects/dashboard/workspace-details/WorkspaceDetails.js +58 -48
- package/dist/pageobjects/dashboard/workspace-details/WorkspaceDetails.js.map +1 -1
- package/dist/pageobjects/git-providers/OauthPage.js +22 -20
- package/dist/pageobjects/git-providers/OauthPage.js.map +1 -1
- package/dist/pageobjects/ide/CheCodeLocatorLoader.js +26 -12
- package/dist/pageobjects/ide/CheCodeLocatorLoader.js.map +1 -1
- package/dist/pageobjects/login/interfaces/ICheLoginPage.js +2 -2
- package/dist/pageobjects/login/interfaces/IOcpLoginPage.js +2 -2
- package/dist/pageobjects/login/kubernetes/DexLoginPage.js +14 -14
- package/dist/pageobjects/login/kubernetes/DexLoginPage.js.map +1 -1
- package/dist/pageobjects/login/kubernetes/KubernetesLoginPage.js +7 -7
- package/dist/pageobjects/login/kubernetes/KubernetesLoginPage.js.map +1 -1
- package/dist/pageobjects/login/openshift/OcpLoginPage.js +24 -28
- package/dist/pageobjects/login/openshift/OcpLoginPage.js.map +1 -1
- package/dist/pageobjects/login/openshift/OcpRedHatLoginPage.js +13 -16
- package/dist/pageobjects/login/openshift/OcpRedHatLoginPage.js.map +1 -1
- package/dist/pageobjects/login/openshift/OcpUserLoginPage.js +9 -9
- package/dist/pageobjects/login/openshift/OcpUserLoginPage.js.map +1 -1
- package/dist/pageobjects/login/openshift/RedHatLoginPage.js +19 -23
- package/dist/pageobjects/login/openshift/RedHatLoginPage.js.map +1 -1
- package/dist/pageobjects/login/openshift/RegularUserOcpCheLoginPage.js +20 -19
- package/dist/pageobjects/login/openshift/RegularUserOcpCheLoginPage.js.map +1 -1
- package/dist/pageobjects/openshift/OcpApplicationPage.js +11 -11
- package/dist/pageobjects/openshift/OcpApplicationPage.js.map +1 -1
- package/dist/pageobjects/openshift/OcpImportFromGitPage.js +24 -24
- package/dist/pageobjects/openshift/OcpImportFromGitPage.js.map +1 -1
- package/dist/pageobjects/openshift/OcpMainPage.js +30 -30
- package/dist/pageobjects/openshift/OcpMainPage.js.map +1 -1
- package/dist/specs/MochaHooks.js +33 -27
- package/dist/specs/MochaHooks.js.map +1 -1
- package/dist/specs/SmokeTest.spec.js +17 -17
- package/dist/specs/SmokeTest.spec.js.map +1 -1
- package/dist/specs/api/ContainerOverridesAPI.spec.js +8 -6
- package/dist/specs/api/ContainerOverridesAPI.spec.js.map +1 -1
- package/dist/specs/api/DevfileAcceptanceTestAPI.spec.js +27 -24
- package/dist/specs/api/DevfileAcceptanceTestAPI.spec.js.map +1 -1
- package/dist/specs/api/EmptyWorkspaceAPI.spec.js +17 -17
- package/dist/specs/api/EmptyWorkspaceAPI.spec.js.map +1 -1
- package/dist/specs/api/PodOverridesAPI.spec.js +10 -8
- package/dist/specs/api/PodOverridesAPI.spec.js.map +1 -1
- package/dist/specs/dashboard-samples/EmptyWorkspace.spec.js +10 -10
- package/dist/specs/dashboard-samples/EmptyWorkspace.spec.js.map +1 -1
- package/dist/specs/dashboard-samples/Quarkus.spec.js +13 -13
- package/dist/specs/dashboard-samples/Quarkus.spec.js.map +1 -1
- package/dist/specs/dashboard-samples/RecommendedExtensions.spec.js +52 -52
- package/dist/specs/dashboard-samples/RecommendedExtensions.spec.js.map +1 -1
- package/dist/specs/devconsole-intergration/DevConsoleIntegration.spec.js +23 -19
- package/dist/specs/devconsole-intergration/DevConsoleIntegration.spec.js.map +1 -1
- package/dist/specs/factory/Factory.spec.js +38 -41
- package/dist/specs/factory/Factory.spec.js.map +1 -1
- package/dist/specs/factory/NoSetupRepoFactory.spec.js +52 -50
- package/dist/specs/factory/NoSetupRepoFactory.spec.js.map +1 -1
- package/dist/specs/factory/RefusedOAuthFactory.spec.js +49 -51
- package/dist/specs/factory/RefusedOAuthFactory.spec.js.map +1 -1
- package/dist/specs/miscellaneous/PredefinedNamespace.spec.js +45 -42
- package/dist/specs/miscellaneous/PredefinedNamespace.spec.js.map +1 -1
- package/dist/tests-library/LoginTests.js +13 -13
- package/dist/tests-library/LoginTests.js.map +1 -1
- package/dist/tests-library/ProjectAndFileTests.js +9 -7
- package/dist/tests-library/ProjectAndFileTests.js.map +1 -1
- package/dist/tests-library/WorkspaceHandlingTests.js +22 -19
- package/dist/tests-library/WorkspaceHandlingTests.js.map +1 -1
- package/dist/utils/BrowserTabsUtil.js +21 -21
- package/dist/utils/BrowserTabsUtil.js.map +1 -1
- package/dist/utils/CheReporter.js +91 -65
- package/dist/utils/CheReporter.js.map +1 -1
- package/dist/utils/DevWorkspaceConfigurationHelper.js +34 -15
- package/dist/utils/DevWorkspaceConfigurationHelper.js.map +1 -1
- package/dist/utils/DevfilesRegistryHelper.js +34 -18
- package/dist/utils/DevfilesRegistryHelper.js.map +1 -1
- package/dist/utils/DriverHelper.js +73 -68
- package/dist/utils/DriverHelper.js.map +1 -1
- package/dist/utils/IContextParams.js +12 -0
- package/dist/utils/IContextParams.js.map +1 -0
- package/dist/utils/IKubernetesCommandLineToolsExecutor.js +3 -0
- package/dist/utils/IKubernetesCommandLineToolsExecutor.js.map +1 -0
- package/dist/utils/KubernetesCommandLineToolsExecutor.js +146 -107
- package/dist/utils/KubernetesCommandLineToolsExecutor.js.map +1 -1
- package/dist/utils/Logger.js +18 -19
- package/dist/utils/Logger.js.map +1 -1
- package/dist/utils/ScreenCatcher.js +26 -16
- package/dist/utils/ScreenCatcher.js.map +1 -1
- package/dist/utils/ShellExecutor.js +29 -9
- package/dist/utils/ShellExecutor.js.map +1 -1
- package/dist/utils/StringUtil.js +19 -9
- package/dist/utils/StringUtil.js.map +1 -1
- package/dist/utils/request-handlers/CheApiRequestHandler.js +29 -29
- package/dist/utils/request-handlers/CheApiRequestHandler.js.map +1 -1
- package/dist/utils/request-handlers/headers/CheMultiuserAuthorizationHeaderHandler.js +12 -8
- package/dist/utils/request-handlers/headers/CheMultiuserAuthorizationHeaderHandler.js.map +1 -1
- package/dist/utils/request-handlers/headers/IAuthorizationHeaderHandler.js +2 -2
- package/dist/utils/workspace/ApiUrlResolver.js +5 -5
- package/dist/utils/workspace/ApiUrlResolver.js.map +1 -1
- package/dist/utils/workspace/ITestWorkspaceUtil.js +2 -2
- package/dist/utils/workspace/TestWorkspaceUtil.js +25 -23
- package/dist/utils/workspace/TestWorkspaceUtil.js.map +1 -1
- package/dist/utils/workspace/WorkspaceStatus.js +2 -2
- package/dist/utils/workspace/WorkspaceStatus.js.map +1 -1
- package/driver/ChromeDriver.ts +45 -58
- package/driver/IDriver.ts +3 -3
- package/index.ts +11 -9
- package/package.json +59 -49
- package/pageobjects/dashboard/CreateWorkspace.ts +65 -55
- package/pageobjects/dashboard/Dashboard.ts +100 -100
- package/pageobjects/dashboard/Workspaces.ts +210 -186
- package/pageobjects/dashboard/workspace-details/WorkspaceDetails.ts +153 -131
- package/pageobjects/git-providers/OauthPage.ts +177 -166
- package/pageobjects/ide/CheCodeLocatorLoader.ts +51 -46
- package/pageobjects/login/interfaces/ICheLoginPage.ts +3 -3
- package/pageobjects/login/interfaces/IOcpLoginPage.ts +3 -3
- package/pageobjects/login/kubernetes/DexLoginPage.ts +31 -30
- package/pageobjects/login/kubernetes/KubernetesLoginPage.ts +15 -14
- package/pageobjects/login/openshift/OcpLoginPage.ts +51 -56
- package/pageobjects/login/openshift/OcpRedHatLoginPage.ts +27 -27
- package/pageobjects/login/openshift/OcpUserLoginPage.ts +15 -18
- package/pageobjects/login/openshift/RedHatLoginPage.ts +49 -46
- package/pageobjects/login/openshift/RegularUserOcpCheLoginPage.ts +43 -34
- package/pageobjects/openshift/OcpApplicationPage.ts +21 -19
- package/pageobjects/openshift/OcpImportFromGitPage.ts +68 -68
- package/pageobjects/openshift/OcpMainPage.ts +69 -69
- package/specs/MochaHooks.ts +59 -52
- package/specs/SmokeTest.spec.ts +47 -45
- package/specs/api/ContainerOverridesAPI.spec.ts +39 -26
- package/specs/api/DevfileAcceptanceTestAPI.spec.ts +110 -97
- package/specs/api/EmptyWorkspaceAPI.spec.ts +67 -58
- package/specs/api/PodOverridesAPI.spec.ts +48 -34
- package/specs/dashboard-samples/EmptyWorkspace.spec.ts +36 -36
- package/specs/dashboard-samples/Quarkus.spec.ts +41 -40
- package/specs/dashboard-samples/RecommendedExtensions.spec.ts +202 -183
- package/specs/devconsole-intergration/DevConsoleIntegration.spec.ts +85 -75
- package/specs/factory/Factory.spec.ts +184 -178
- package/specs/factory/NoSetupRepoFactory.spec.ts +233 -219
- package/specs/factory/RefusedOAuthFactory.spec.ts +223 -211
- package/specs/miscellaneous/PredefinedNamespace.spec.ts +70 -64
- package/tests-library/LoginTests.ts +34 -32
- package/tests-library/ProjectAndFileTests.ts +21 -18
- package/tests-library/WorkspaceHandlingTests.ts +98 -89
- package/tsconfig.json +15 -15
- package/utils/BrowserTabsUtil.ts +78 -74
- package/utils/CheReporter.ts +159 -157
- package/utils/DevWorkspaceConfigurationHelper.ts +63 -69
- package/utils/DevfilesRegistryHelper.ts +71 -57
- package/utils/DriverHelper.ts +728 -700
- package/utils/IContextParams.ts +26 -0
- package/utils/IKubernetesCommandLineToolsExecutor.ts +42 -0
- package/utils/KubernetesCommandLineToolsExecutor.ts +231 -183
- package/utils/Logger.ts +102 -125
- package/utils/ScreenCatcher.ts +57 -46
- package/utils/ShellExecutor.ts +23 -12
- package/utils/StringUtil.ts +49 -36
- package/utils/request-handlers/CheApiRequestHandler.ts +91 -88
- package/utils/request-handlers/headers/CheMultiuserAuthorizationHeaderHandler.ts +32 -21
- package/utils/request-handlers/headers/IAuthorizationHeaderHandler.ts +3 -3
- package/utils/workspace/ApiUrlResolver.ts +31 -26
- package/utils/workspace/ITestWorkspaceUtil.ts +31 -31
- package/utils/workspace/TestWorkspaceUtil.ts +152 -145
- package/utils/workspace/WorkspaceStatus.ts +5 -5
- package/constants/APITestConstants.ts +0 -57
- package/constants/BaseTestConstants.ts +0 -68
- package/constants/ChromeDriverConstants.ts +0 -46
- package/constants/FactoryTestConstants.ts +0 -51
- package/constants/MonacoConstants.ts +0 -22
- package/constants/OAuthConstants.ts +0 -57
- package/constants/PluginsTestConstants.ts +0 -15
- package/constants/ReporterConstants.ts +0 -45
- package/constants/TimeoutConstants.ts +0 -113
- package/dist/constants/APITestConstants.js.map +0 -1
- package/dist/constants/BaseTestConstants.js.map +0 -1
- package/dist/constants/ChromeDriverConstants.js +0 -44
- package/dist/constants/ChromeDriverConstants.js.map +0 -1
- package/dist/constants/FactoryTestConstants.js.map +0 -1
- package/dist/constants/MonacoConstants.js.map +0 -1
- package/dist/constants/OAuthConstants.js.map +0 -1
- package/dist/constants/PluginsTestConstants.js.map +0 -1
- package/dist/constants/ReporterConstants.js.map +0 -1
- package/dist/constants/TimeoutConstants.js.map +0 -1
- package/tslint.json +0 -126
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
|
|
2
|
-
*
|
|
1
|
+
/** *******************************************************************
|
|
2
|
+
* copyright (c) 2019-2023 Red Hat, Inc.
|
|
3
3
|
*
|
|
4
4
|
* This program and the accompanying materials are made
|
|
5
5
|
* available under the terms of the Eclipse Public License 2.0
|
|
@@ -9,36 +9,50 @@
|
|
|
9
9
|
**********************************************************************/
|
|
10
10
|
|
|
11
11
|
const TYPES: any = {
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
12
|
+
Driver: Symbol.for('Driver'),
|
|
13
|
+
CheLogin: Symbol.for('CheLogin'),
|
|
14
|
+
OcpLogin: Symbol.for('OcpLogin'),
|
|
15
|
+
WorkspaceUtil: Symbol.for('WorkspaceUtil'),
|
|
16
|
+
IAuthorizationHeaderHandler: Symbol.for('IAuthorizationHeaderHandler'),
|
|
17
|
+
ITokenHandler: Symbol.for('ITokenHandler'),
|
|
18
|
+
IKubernetesCommandLineToolsExecutor: Symbol.for('IKubernetesCommandLineToolsExecutor'),
|
|
19
|
+
IContextParams: Symbol.for('IContextParams')
|
|
18
20
|
};
|
|
19
21
|
|
|
20
22
|
const CLASSES: any = {
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
23
|
+
DriverHelper: 'DriverHelper',
|
|
24
|
+
Dashboard: 'Dashboard',
|
|
25
|
+
Workspaces: 'Workspaces',
|
|
26
|
+
WorkspaceDetails: 'WorkspaceDetails',
|
|
27
|
+
ScreenCatcher: 'ScreenCatcher',
|
|
28
|
+
OcpLoginPage: 'OcpLoginPage',
|
|
29
|
+
CheApiRequestHandler: 'CheApiRequestHandler',
|
|
30
|
+
CreateWorkspace: 'CreateWorkspace',
|
|
31
|
+
BrowserTabsUtil: 'BrowserTabsUtil',
|
|
32
|
+
ProjectAndFileTests: 'ProjectAndFileTests',
|
|
33
|
+
StringUtil: 'StringUtil',
|
|
34
|
+
ApiUrlResolver: 'ApiUrlResolver',
|
|
35
|
+
LoginTests: 'LoginTests',
|
|
36
|
+
WorkspaceHandlingTests: 'WorkspaceHandlingTests',
|
|
37
|
+
RedHatLoginPage: 'RedHatLoginPage',
|
|
38
|
+
KubernetesLoginPage: 'KubernetesLoginPage',
|
|
39
|
+
DexLoginPage: 'DexLoginPage',
|
|
40
|
+
OcpRedHatLoginPage: 'OcpRedHatLoginPage',
|
|
41
|
+
OcpApplicationPage: 'OcpApplicationPage',
|
|
42
|
+
OcpMainPage: 'OcpMainPage',
|
|
43
|
+
OcpImportFromGitPage: 'OcpImportFromGitPage',
|
|
44
|
+
CheCodeLocatorLoader: 'CheCodeLocatorLoader',
|
|
45
|
+
LocatorLoader: 'LocatorLoader',
|
|
46
|
+
OauthPage: 'OauthPage',
|
|
47
|
+
DevfilesRegistryHelper: 'DevfilesRegistryHelper',
|
|
48
|
+
KubernetesCommandLineToolsExecutor: 'KubernetesCommandLineToolsExecutor',
|
|
49
|
+
ShellExecutor: 'ShellExecutor',
|
|
50
|
+
ContainerTerminal: 'ContainerTerminal'
|
|
42
51
|
};
|
|
43
52
|
|
|
44
|
-
|
|
53
|
+
const EXTERNAL_CLASSES: any = {
|
|
54
|
+
Generator: 'Generator',
|
|
55
|
+
LocatorLoader: 'LocatorLoader'
|
|
56
|
+
};
|
|
57
|
+
|
|
58
|
+
export { TYPES, CLASSES, EXTERNAL_CLASSES };
|
package/configs/mocharc.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
|
|
2
|
-
*
|
|
1
|
+
/** *******************************************************************
|
|
2
|
+
* copyright (c) 2020-2023 Red Hat, Inc.
|
|
3
3
|
*
|
|
4
4
|
* This program and the accompanying materials are made
|
|
5
5
|
* available under the terms of the Eclipse Public License 2.0
|
|
@@ -10,28 +10,25 @@
|
|
|
10
10
|
|
|
11
11
|
'use strict';
|
|
12
12
|
|
|
13
|
-
import {
|
|
13
|
+
import { TIMEOUT_CONSTANTS } from '../constants/TIMEOUT_CONSTANTS';
|
|
14
14
|
|
|
15
15
|
module.exports = {
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
[`dist/specs/**/${process.env.USERSTORY}.spec.js`, `dist/specs/${process.env.USERSTORY}.spec.js`]
|
|
35
|
-
: [`dist/specs/**/**.spec.js`, `dist/specs/**.spec.js`],
|
|
36
|
-
retries: TimeoutConstants.TS_SELENIUM_DEFAULT_ATTEMPTS
|
|
16
|
+
timeout: 1200000,
|
|
17
|
+
reporter: 'dist/utils/CheReporter.js',
|
|
18
|
+
ui: 'tdd',
|
|
19
|
+
require: ['dist/specs/MochaHooks.js', 'ts-node/register'],
|
|
20
|
+
bail: true,
|
|
21
|
+
'full-trace': true,
|
|
22
|
+
spec:
|
|
23
|
+
// variable MOCHA_DIRECTORY uses in command "test-all-devfiles" and sets up automatically.
|
|
24
|
+
// you can set it up to run files from specific directory with export environmental variable.
|
|
25
|
+
process.env.MOCHA_DIRECTORY
|
|
26
|
+
? // to run one file (name without extension). uses in "test", "test-all-devfiles".
|
|
27
|
+
process.env.USERSTORY
|
|
28
|
+
? `dist/specs/${process.env.MOCHA_DIRECTORY}/${process.env.USERSTORY}.spec.js`
|
|
29
|
+
: `dist/specs/${process.env.MOCHA_DIRECTORY}/**.spec.js`
|
|
30
|
+
: process.env.USERSTORY
|
|
31
|
+
? [`dist/specs/**/${process.env.USERSTORY}.spec.js`, `dist/specs/${process.env.USERSTORY}.spec.js`]
|
|
32
|
+
: ['dist/specs/**/**.spec.js', 'dist/specs/**.spec.js'],
|
|
33
|
+
retries: TIMEOUT_CONSTANTS.TS_SELENIUM_DEFAULT_ATTEMPTS
|
|
37
34
|
};
|
|
@@ -0,0 +1,67 @@
|
|
|
1
|
+
/** *******************************************************************
|
|
2
|
+
* copyright (c) 2020-2023 Red Hat, Inc.
|
|
3
|
+
*
|
|
4
|
+
* This program and the accompanying materials are made
|
|
5
|
+
* available under the terms of the Eclipse Public License 2.0
|
|
6
|
+
* which is available at https://www.eclipse.org/legal/epl-2.0/
|
|
7
|
+
*
|
|
8
|
+
* SPDX-License-Identifier: EPL-2.0
|
|
9
|
+
**********************************************************************/
|
|
10
|
+
|
|
11
|
+
import { BASE_TEST_CONSTANTS } from './BASE_TEST_CONSTANTS';
|
|
12
|
+
|
|
13
|
+
export enum KubernetesCommandLineTool {
|
|
14
|
+
OC = 'oc',
|
|
15
|
+
KUBECTL = 'kubectl'
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
export const SUPPORTED_DEVFILE_REGISTRIES: {
|
|
19
|
+
INBUILT_APPLICATION_DEVFILE_REGISTRY_URL: () => string;
|
|
20
|
+
GIT_HUB_CHE_DEVFILE_REGISTRY_URL: string;
|
|
21
|
+
} = {
|
|
22
|
+
INBUILT_APPLICATION_DEVFILE_REGISTRY_URL: (): string => `${BASE_TEST_CONSTANTS.TS_SELENIUM_BASE_URL}/devfile-registry/devfiles/`,
|
|
23
|
+
GIT_HUB_CHE_DEVFILE_REGISTRY_URL: 'https://api.github.com/repos/eclipse-che/che-devfile-registry/contents/devfiles/'
|
|
24
|
+
};
|
|
25
|
+
export const API_TEST_CONSTANTS: {
|
|
26
|
+
TS_API_TEST_KUBERNETES_COMMAND_LINE_TOOL: string;
|
|
27
|
+
TS_API_TEST_PLUGIN_REGISTRY_URL: string | undefined;
|
|
28
|
+
TS_API_TEST_CHE_CODE_EDITOR_DEVFILE_URI: string | undefined;
|
|
29
|
+
TS_API_TEST_UDI_IMAGE: string | undefined;
|
|
30
|
+
TS_API_TEST_NAMESPACE: string | undefined;
|
|
31
|
+
TS_API_ACCEPTANCE_TEST_REGISTRY_URL(): string;
|
|
32
|
+
} = {
|
|
33
|
+
/**
|
|
34
|
+
* possible values "oc" or "kubectl"
|
|
35
|
+
*/
|
|
36
|
+
TS_API_TEST_KUBERNETES_COMMAND_LINE_TOOL: process.env.TS_API_TEST_KUBERNETES_COMMAND_LINE_TOOL || KubernetesCommandLineTool.OC,
|
|
37
|
+
|
|
38
|
+
/**
|
|
39
|
+
* 'quay.io/devfile/universal-developer-image:latest'
|
|
40
|
+
* is default assigned by DevWorkspaceConfigurationHelper.generateDevfileContext() using @eclipse-che/che-devworkspace-generator
|
|
41
|
+
*/
|
|
42
|
+
TS_API_TEST_UDI_IMAGE: process.env.TS_API_TEST_UDI_IMAGE || undefined,
|
|
43
|
+
|
|
44
|
+
/**
|
|
45
|
+
* https://eclipse-che.github.io/che-plugin-registry/main/v3/plugins/che-incubator/che-code/latest/devfile.yaml
|
|
46
|
+
* is default assigned by DevWorkspaceConfigurationHelper.generateDevfileContext() using @eclipse-che/che-devworkspace-generator
|
|
47
|
+
*/
|
|
48
|
+
TS_API_TEST_CHE_CODE_EDITOR_DEVFILE_URI: process.env.TS_API_TEST_CHE_CODE_EDITOR_DEVFILE_URI || undefined,
|
|
49
|
+
|
|
50
|
+
/**
|
|
51
|
+
* https://eclipse-che.github.io/che-plugin-registry/main/v3
|
|
52
|
+
* is default assigned by DevWorkspaceConfigurationHelper.generateDevfileContext() using @eclipse-che/che-devworkspace-generator
|
|
53
|
+
*/
|
|
54
|
+
TS_API_TEST_PLUGIN_REGISTRY_URL: process.env.TS_API_TEST_PLUGIN_REGISTRY_URL || undefined,
|
|
55
|
+
|
|
56
|
+
/**
|
|
57
|
+
* namespace on openshift platform
|
|
58
|
+
*/
|
|
59
|
+
TS_API_TEST_NAMESPACE: process.env.TS_API_TEST_NAMESPACE || undefined,
|
|
60
|
+
|
|
61
|
+
/**
|
|
62
|
+
* to run all devfile from registry. used in DevfileAcceptanceTestAPI.suite.ts
|
|
63
|
+
*/
|
|
64
|
+
TS_API_ACCEPTANCE_TEST_REGISTRY_URL(): string {
|
|
65
|
+
return process.env.TS_API_ACCEPTANCE_TEST_REGISTRY_URL || SUPPORTED_DEVFILE_REGISTRIES.INBUILT_APPLICATION_DEVFILE_REGISTRY_URL();
|
|
66
|
+
}
|
|
67
|
+
};
|
|
@@ -0,0 +1,80 @@
|
|
|
1
|
+
/** *******************************************************************
|
|
2
|
+
* copyright (c) 2020-2023 Red Hat, Inc.
|
|
3
|
+
*
|
|
4
|
+
* This program and the accompanying materials are made
|
|
5
|
+
* available under the terms of the Eclipse Public License 2.0
|
|
6
|
+
* which is available at https://www.eclipse.org/legal/epl-2.0/
|
|
7
|
+
*
|
|
8
|
+
* SPDX-License-Identifier: EPL-2.0
|
|
9
|
+
**********************************************************************/
|
|
10
|
+
export enum Platform {
|
|
11
|
+
OPENSHIFT = 'openshift',
|
|
12
|
+
KUBERNETES = 'kubernetes'
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
export const BASE_TEST_CONSTANTS: {
|
|
16
|
+
TS_DEBUG_MODE: boolean;
|
|
17
|
+
TS_PLATFORM: string;
|
|
18
|
+
TS_SELENIUM_RESPONSE_INTERCEPTOR: boolean;
|
|
19
|
+
TS_SELENIUM_BASE_URL: string;
|
|
20
|
+
DELETE_WORKSPACE_ON_FAILED_TEST: boolean;
|
|
21
|
+
TS_SELENIUM_EDITOR: string;
|
|
22
|
+
TS_LOAD_TESTS: string;
|
|
23
|
+
TS_SELENIUM_REQUEST_INTERCEPTOR: boolean;
|
|
24
|
+
TS_SELENIUM_PROJECT_ROOT_FILE_NAME: string;
|
|
25
|
+
TS_SELENIUM_HAPPY_PATH_WORKSPACE_NAME: string;
|
|
26
|
+
IS_CLUSTER_DISCONNECTED: () => boolean;
|
|
27
|
+
} = {
|
|
28
|
+
/**
|
|
29
|
+
* base URL of the application which should be checked
|
|
30
|
+
*/
|
|
31
|
+
TS_SELENIUM_BASE_URL: !process.env.TS_SELENIUM_BASE_URL ? 'http://sample-url' : process.env.TS_SELENIUM_BASE_URL.replace(/\/$/, ''),
|
|
32
|
+
|
|
33
|
+
IS_CLUSTER_DISCONNECTED: (): boolean => BASE_TEST_CONSTANTS.TS_SELENIUM_BASE_URL.includes('airgap'),
|
|
34
|
+
|
|
35
|
+
/**
|
|
36
|
+
* choose the platform where "che" application deployed, "openshift" by default.
|
|
37
|
+
*/
|
|
38
|
+
TS_PLATFORM: process.env.TS_PLATFORM || Platform.OPENSHIFT,
|
|
39
|
+
|
|
40
|
+
/**
|
|
41
|
+
* editor the tests are running against, "code" by default.
|
|
42
|
+
* Possible values: "che-code"
|
|
43
|
+
*/
|
|
44
|
+
TS_SELENIUM_EDITOR: process.env.TS_SELENIUM_EDITOR || 'che-code',
|
|
45
|
+
|
|
46
|
+
/**
|
|
47
|
+
* file name to check if project was imported
|
|
48
|
+
*/
|
|
49
|
+
TS_SELENIUM_PROJECT_ROOT_FILE_NAME: process.env.TS_SELENIUM_PROJECT_ROOT_FILE_NAME || 'devfile.yaml',
|
|
50
|
+
|
|
51
|
+
/**
|
|
52
|
+
* name of workspace created for 'Happy Path' scenario validation.
|
|
53
|
+
*/
|
|
54
|
+
TS_SELENIUM_HAPPY_PATH_WORKSPACE_NAME: process.env.TS_SELENIUM_HAPPY_PATH_WORKSPACE_NAME || 'EmptyWorkspace',
|
|
55
|
+
|
|
56
|
+
/**
|
|
57
|
+
* this variable specifies that run test is used for load testing and that all artifacts will be sent to ftp client.
|
|
58
|
+
*/
|
|
59
|
+
TS_LOAD_TESTS: process.env.TS_LOAD_TESTS || 'false',
|
|
60
|
+
|
|
61
|
+
/**
|
|
62
|
+
* enable Axios request interceptor, false by default
|
|
63
|
+
*/
|
|
64
|
+
TS_SELENIUM_REQUEST_INTERCEPTOR: process.env.TS_SELENIUM_REQUEST_INTERCEPTOR === 'true',
|
|
65
|
+
|
|
66
|
+
/**
|
|
67
|
+
* enable Axios response interceptor, false by default
|
|
68
|
+
*/
|
|
69
|
+
TS_SELENIUM_RESPONSE_INTERCEPTOR: process.env.TS_SELENIUM_RESPONSE_INTERCEPTOR === 'true',
|
|
70
|
+
|
|
71
|
+
/**
|
|
72
|
+
* stop and remove workspace if a test fails.
|
|
73
|
+
*/
|
|
74
|
+
DELETE_WORKSPACE_ON_FAILED_TEST: process.env.DELETE_WORKSPACE_ON_FAILED_TEST === 'true',
|
|
75
|
+
|
|
76
|
+
/**
|
|
77
|
+
* constant, which prolong timeout constants for local debug.
|
|
78
|
+
*/
|
|
79
|
+
TS_DEBUG_MODE: process.env.TS_DEBUG_MODE === 'true'
|
|
80
|
+
};
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
/** *******************************************************************
|
|
2
|
+
* copyright (c) 2020-2023 Red Hat, Inc.
|
|
3
|
+
*
|
|
4
|
+
* This program and the accompanying materials are made
|
|
5
|
+
* available under the terms of the Eclipse Public License 2.0
|
|
6
|
+
* which is available at https://www.eclipse.org/legal/epl-2.0/
|
|
7
|
+
*
|
|
8
|
+
* SPDX-License-Identifier: EPL-2.0
|
|
9
|
+
**********************************************************************/
|
|
10
|
+
export const CHROME_DRIVER_CONSTANTS: {
|
|
11
|
+
TS_SELENIUM_W3C_CHROME_OPTION: boolean;
|
|
12
|
+
TS_SELENIUM_HEADLESS: boolean;
|
|
13
|
+
TS_USE_WEB_DRIVER_FOR_TEST: boolean;
|
|
14
|
+
TS_SELENIUM_LAUNCH_FULLSCREEN: boolean;
|
|
15
|
+
TS_SELENIUM_REMOTE_DRIVER_URL: string;
|
|
16
|
+
} = {
|
|
17
|
+
/**
|
|
18
|
+
* remote driver URL.
|
|
19
|
+
*/
|
|
20
|
+
TS_SELENIUM_REMOTE_DRIVER_URL: process.env.TS_SELENIUM_REMOTE_DRIVER_URL || '',
|
|
21
|
+
|
|
22
|
+
/**
|
|
23
|
+
* run browser in "Headless" (hidden) mode, "false" by default.
|
|
24
|
+
*/
|
|
25
|
+
TS_SELENIUM_HEADLESS: process.env.TS_SELENIUM_HEADLESS === 'true',
|
|
26
|
+
|
|
27
|
+
/**
|
|
28
|
+
* create instance of chromedriver, "true" by default. Should be "false" to run only API tests.
|
|
29
|
+
*/
|
|
30
|
+
TS_USE_WEB_DRIVER_FOR_TEST: process.env.TS_USE_WEB_DRIVER_FOR_TEST !== 'false',
|
|
31
|
+
|
|
32
|
+
/**
|
|
33
|
+
* run browser in "Fullscreen" (kiosk) mode.
|
|
34
|
+
* Default to true if undefined
|
|
35
|
+
*/
|
|
36
|
+
TS_SELENIUM_LAUNCH_FULLSCREEN: process.env.TS_SELENIUM_LAUNCH_FULLSCREEN !== 'false',
|
|
37
|
+
|
|
38
|
+
/**
|
|
39
|
+
* run browser with an enabled or disabled W3C protocol (on Chrome 76 and upper, it is enabled by default), "true" by default.
|
|
40
|
+
*/
|
|
41
|
+
TS_SELENIUM_W3C_CHROME_OPTION: process.env.TS_SELENIUM_W3C_CHROME_OPTION !== 'false'
|
|
42
|
+
};
|
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
/** *******************************************************************
|
|
2
|
+
* copyright (c) 2020-2023 Red Hat, Inc.
|
|
3
|
+
*
|
|
4
|
+
* This program and the accompanying materials are made
|
|
5
|
+
* available under the terms of the Eclipse Public License 2.0
|
|
6
|
+
* which is available at https://www.eclipse.org/legal/epl-2.0/
|
|
7
|
+
*
|
|
8
|
+
* SPDX-License-Identifier: EPL-2.0
|
|
9
|
+
**********************************************************************/
|
|
10
|
+
import { BASE_TEST_CONSTANTS } from './BASE_TEST_CONSTANTS';
|
|
11
|
+
|
|
12
|
+
export enum GitProviderType {
|
|
13
|
+
GITHUB = 'github',
|
|
14
|
+
GITLAB = 'gitlab',
|
|
15
|
+
BITBUCKET = 'bitbucket',
|
|
16
|
+
AZURE_DEVOPS = 'azure-devops'
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
export const FACTORY_TEST_CONSTANTS: {
|
|
20
|
+
TS_SELENIUM_FACTORY_GIT_REPO_URL: string;
|
|
21
|
+
TS_SELENIUM_PROJECT_NAME: string;
|
|
22
|
+
TS_SELENIUM_IS_PRIVATE_FACTORY_GIT_REPO: boolean;
|
|
23
|
+
TS_SELENIUM_FACTORY_GIT_PROVIDER: string;
|
|
24
|
+
TS_SELENIUM_FACTORY_GIT_REPO_BRANCH: string;
|
|
25
|
+
TS_SELENIUM_FACTORY_URL(): string;
|
|
26
|
+
} = {
|
|
27
|
+
/**
|
|
28
|
+
* git provider to check in factory tests
|
|
29
|
+
*/
|
|
30
|
+
TS_SELENIUM_FACTORY_GIT_PROVIDER: process.env.TS_SELENIUM_FACTORY_GIT_PROVIDER || GitProviderType.GITHUB,
|
|
31
|
+
|
|
32
|
+
/**
|
|
33
|
+
* url to create factory
|
|
34
|
+
*/
|
|
35
|
+
TS_SELENIUM_FACTORY_GIT_REPO_URL: process.env.TS_SELENIUM_FACTORY_GIT_REPO_URL || '',
|
|
36
|
+
|
|
37
|
+
/**
|
|
38
|
+
* git repository name
|
|
39
|
+
*/
|
|
40
|
+
TS_SELENIUM_PROJECT_NAME: process.env.TS_SELENIUM_PROJECT_NAME || '',
|
|
41
|
+
|
|
42
|
+
/**
|
|
43
|
+
* is factory repository URL private or no
|
|
44
|
+
*/
|
|
45
|
+
TS_SELENIUM_IS_PRIVATE_FACTORY_GIT_REPO: process.env.TS_SELENIUM_IS_PRIVATE_FACTORY_GIT_REPO === 'true',
|
|
46
|
+
|
|
47
|
+
/**
|
|
48
|
+
* git repository main branch name (main or master)
|
|
49
|
+
*/
|
|
50
|
+
TS_SELENIUM_FACTORY_GIT_REPO_BRANCH: process.env.TS_SELENIUM_FACTORY_GIT_REPO_BRANCH || 'master',
|
|
51
|
+
|
|
52
|
+
/**
|
|
53
|
+
* full factory URL
|
|
54
|
+
*/
|
|
55
|
+
TS_SELENIUM_FACTORY_URL(): string {
|
|
56
|
+
return (
|
|
57
|
+
process.env.TS_SELENIUM_FACTORY_URL ||
|
|
58
|
+
BASE_TEST_CONSTANTS.TS_SELENIUM_BASE_URL + '/dashboard/#/' + this.TS_SELENIUM_FACTORY_GIT_REPO_URL
|
|
59
|
+
);
|
|
60
|
+
}
|
|
61
|
+
};
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
/** *******************************************************************
|
|
2
|
+
* copyright (c) 2020-2023 Red Hat, Inc.
|
|
3
|
+
*
|
|
4
|
+
* This program and the accompanying materials are made
|
|
5
|
+
* available under the terms of the Eclipse Public License 2.0
|
|
6
|
+
* which is available at https://www.eclipse.org/legal/epl-2.0/
|
|
7
|
+
*
|
|
8
|
+
* SPDX-License-Identifier: EPL-2.0
|
|
9
|
+
**********************************************************************/
|
|
10
|
+
export const MONACO_CONSTANTS: {
|
|
11
|
+
TS_SELENIUM_MONACO_PAGE_OBJECTS_USE_VERSION: string;
|
|
12
|
+
TS_SELENIUM_MONACO_PAGE_OBJECTS_BASE_VERSION: string;
|
|
13
|
+
} = {
|
|
14
|
+
/**
|
|
15
|
+
* base version of VSCode editor for monaco-page-objects, "1.37.0" by default.
|
|
16
|
+
*/
|
|
17
|
+
TS_SELENIUM_MONACO_PAGE_OBJECTS_BASE_VERSION: process.env.TS_SELENIUM_MONACO_PAGE_OBJECTS_BASE_VERSION || '1.37.0',
|
|
18
|
+
|
|
19
|
+
/**
|
|
20
|
+
* latest compatible version to be used, based on versions available in
|
|
21
|
+
* https://github.com/redhat-developer/vscode-extension-tester/tree/master/locators/lib ,
|
|
22
|
+
* "1.73.0" by default.
|
|
23
|
+
*/
|
|
24
|
+
TS_SELENIUM_MONACO_PAGE_OBJECTS_USE_VERSION: process.env.TS_SELENIUM_MONACO_PAGE_OBJECTS_USE_VERSION || '1.73.0'
|
|
25
|
+
};
|
|
@@ -0,0 +1,67 @@
|
|
|
1
|
+
/** *******************************************************************
|
|
2
|
+
* copyright (c) 2020-2023 Red Hat, Inc.
|
|
3
|
+
*
|
|
4
|
+
* This program and the accompanying materials are made
|
|
5
|
+
* available under the terms of the Eclipse Public License 2.0
|
|
6
|
+
* which is available at https://www.eclipse.org/legal/epl-2.0/
|
|
7
|
+
*
|
|
8
|
+
* SPDX-License-Identifier: EPL-2.0
|
|
9
|
+
**********************************************************************/
|
|
10
|
+
export const OAUTH_CONSTANTS: {
|
|
11
|
+
TS_SELENIUM_K8S_PASSWORD: string;
|
|
12
|
+
TS_SELENIUM_GIT_PROVIDER_PASSWORD: string;
|
|
13
|
+
TS_OCP_LOGIN_PAGE_PROVIDER_TITLE: string;
|
|
14
|
+
TS_SELENIUM_K8S_USERNAME: string;
|
|
15
|
+
TS_SELENIUM_GIT_PROVIDER_OAUTH: boolean;
|
|
16
|
+
TS_SELENIUM_OCP_USERNAME: string;
|
|
17
|
+
TS_SELENIUM_OCP_PASSWORD: string;
|
|
18
|
+
TS_SELENIUM_VALUE_OPENSHIFT_OAUTH: boolean;
|
|
19
|
+
TS_SELENIUM_GIT_PROVIDER_USERNAME: string;
|
|
20
|
+
} = {
|
|
21
|
+
/**
|
|
22
|
+
* value of OpenShift oAuth property determines how to login in installed application,
|
|
23
|
+
* if 'false' as an user of application, if 'true' as a regular user of OCP.
|
|
24
|
+
*/
|
|
25
|
+
TS_SELENIUM_VALUE_OPENSHIFT_OAUTH: process.env.TS_SELENIUM_VALUE_OPENSHIFT_OAUTH === 'true',
|
|
26
|
+
|
|
27
|
+
/**
|
|
28
|
+
* log into OCP by using appropriate provider title.
|
|
29
|
+
*/
|
|
30
|
+
TS_OCP_LOGIN_PAGE_PROVIDER_TITLE: process.env.TS_OCP_LOGIN_PAGE_PROVIDER_TITLE || '',
|
|
31
|
+
|
|
32
|
+
/**
|
|
33
|
+
* regular username used to login in OCP.
|
|
34
|
+
*/
|
|
35
|
+
TS_SELENIUM_OCP_USERNAME: process.env.TS_SELENIUM_OCP_USERNAME || '',
|
|
36
|
+
|
|
37
|
+
/**
|
|
38
|
+
* password regular user used to login in OCP.
|
|
39
|
+
*/
|
|
40
|
+
TS_SELENIUM_OCP_PASSWORD: process.env.TS_SELENIUM_OCP_PASSWORD || '',
|
|
41
|
+
|
|
42
|
+
/**
|
|
43
|
+
* regular username used to login in Kubernetes.
|
|
44
|
+
*/
|
|
45
|
+
TS_SELENIUM_K8S_USERNAME: process.env.TS_SELENIUM_K8S_USERNAME || '',
|
|
46
|
+
|
|
47
|
+
/**
|
|
48
|
+
* password regular user used to login in Kubernetes.
|
|
49
|
+
*/
|
|
50
|
+
TS_SELENIUM_K8S_PASSWORD: process.env.TS_SELENIUM_K8S_PASSWORD || '',
|
|
51
|
+
|
|
52
|
+
/**
|
|
53
|
+
* for login via github for example on https://che-dogfooding.apps.che-dev.x6e0.p1.openshiftapps.com
|
|
54
|
+
* For factory tests
|
|
55
|
+
*/
|
|
56
|
+
TS_SELENIUM_GIT_PROVIDER_OAUTH: process.env.TS_SELENIUM_GIT_PROVIDER_OAUTH === 'true',
|
|
57
|
+
|
|
58
|
+
/**
|
|
59
|
+
* git repository username
|
|
60
|
+
*/
|
|
61
|
+
TS_SELENIUM_GIT_PROVIDER_USERNAME: process.env.TS_SELENIUM_GIT_PROVIDER_USERNAME || '',
|
|
62
|
+
|
|
63
|
+
/**
|
|
64
|
+
* git repository password
|
|
65
|
+
*/
|
|
66
|
+
TS_SELENIUM_GIT_PROVIDER_PASSWORD: process.env.TS_SELENIUM_GIT_PROVIDER_PASSWORD || ''
|
|
67
|
+
};
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
/** *******************************************************************
|
|
2
|
+
* copyright (c) 2020-2023 Red Hat, Inc.
|
|
3
|
+
*
|
|
4
|
+
* This program and the accompanying materials are made
|
|
5
|
+
* available under the terms of the Eclipse Public License 2.0
|
|
6
|
+
* which is available at https://www.eclipse.org/legal/epl-2.0/
|
|
7
|
+
*
|
|
8
|
+
* SPDX-License-Identifier: EPL-2.0
|
|
9
|
+
**********************************************************************/
|
|
10
|
+
export const PLUGIN_TEST_CONSTANTS: { TS_SAMPLE_LIST: string } = {
|
|
11
|
+
/**
|
|
12
|
+
* dashboard samples to check in RecommendedExtensions.spec.ts
|
|
13
|
+
*/
|
|
14
|
+
TS_SAMPLE_LIST: process.env.TS_SAMPLE_LIST || 'Node.js MongoDB,Node.js Express'
|
|
15
|
+
};
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
/** *******************************************************************
|
|
2
|
+
* copyright (c) 2020-2023 Red Hat, Inc.
|
|
3
|
+
*
|
|
4
|
+
* This program and the accompanying materials are made
|
|
5
|
+
* available under the terms of the Eclipse Public License 2.0
|
|
6
|
+
* which is available at https://www.eclipse.org/legal/epl-2.0/
|
|
7
|
+
*
|
|
8
|
+
* SPDX-License-Identifier: EPL-2.0
|
|
9
|
+
**********************************************************************/
|
|
10
|
+
export const REPORTER_CONSTANTS: {
|
|
11
|
+
TS_SELENIUM_DELAY_BETWEEN_SCREENSHOTS: number;
|
|
12
|
+
TS_SELENIUM_REPORT_FOLDER: string;
|
|
13
|
+
TS_SELENIUM_EXECUTION_SCREENCAST: boolean;
|
|
14
|
+
TS_SELENIUM_PRINT_TIMEOUT_VARIABLES: string | boolean;
|
|
15
|
+
TS_SELENIUM_LOAD_TEST_REPORT_FOLDER: string;
|
|
16
|
+
TS_SELENIUM_LOG_LEVEL: string;
|
|
17
|
+
DELETE_SCREENCAST_IF_TEST_PASS: boolean;
|
|
18
|
+
} = {
|
|
19
|
+
/**
|
|
20
|
+
* path to folder with load tests execution report.
|
|
21
|
+
*/
|
|
22
|
+
TS_SELENIUM_LOAD_TEST_REPORT_FOLDER: process.env.TS_SELENIUM_LOAD_TEST_REPORT_FOLDER || './load-test-folder',
|
|
23
|
+
|
|
24
|
+
/**
|
|
25
|
+
* delay between screenshots catching in the milliseconds for the execution screencast.
|
|
26
|
+
*/
|
|
27
|
+
TS_SELENIUM_DELAY_BETWEEN_SCREENSHOTS: Number(process.env.TS_SELENIUM_DELAY_BETWEEN_SCREENSHOTS) || 1000,
|
|
28
|
+
|
|
29
|
+
/**
|
|
30
|
+
* path to folder with tests execution report.
|
|
31
|
+
*/
|
|
32
|
+
TS_SELENIUM_REPORT_FOLDER: process.env.TS_SELENIUM_REPORT_FOLDER || './report',
|
|
33
|
+
|
|
34
|
+
/**
|
|
35
|
+
* enable or disable storing of execution screencast, "false" by default.
|
|
36
|
+
*/
|
|
37
|
+
TS_SELENIUM_EXECUTION_SCREENCAST: process.env.TS_SELENIUM_EXECUTION_SCREENCAST === 'true',
|
|
38
|
+
|
|
39
|
+
/**
|
|
40
|
+
* delete screencast after execution if all tests passed, "true" by default.
|
|
41
|
+
*/
|
|
42
|
+
DELETE_SCREENCAST_IF_TEST_PASS: process.env.DELETE_SCREENCAST_IF_TEST_PASS !== 'false',
|
|
43
|
+
|
|
44
|
+
/**
|
|
45
|
+
* log level settings, possible variants: 'INFO' (by default), 'DEBUG', 'TRACE'.
|
|
46
|
+
*/
|
|
47
|
+
TS_SELENIUM_LOG_LEVEL: process.env.TS_SELENIUM_LOG_LEVEL || 'INFO',
|
|
48
|
+
|
|
49
|
+
/**
|
|
50
|
+
* print all timeout variables when tests launch, default to false
|
|
51
|
+
*/
|
|
52
|
+
TS_SELENIUM_PRINT_TIMEOUT_VARIABLES: process.env.TS_SELENIUM_PRINT_TIMEOUT_VARIABLES || false
|
|
53
|
+
};
|