@eclipse-che/che-e2e
Advanced tools
Comparing version 7.97.0-next-dfc2d2b to 7.97.0
@@ -36,4 +36,4 @@ # Coding Standards and Conventions | ||
- [.eslintrc](.eslintrc.js) | ||
- [.prettierrc](.prettierrc.json) | ||
- [.eslintrc](.eslintrc.js) | ||
- [.prettierrc](.prettierrc.json) | ||
@@ -40,0 +40,0 @@ ### Preferable code style |
@@ -32,3 +32,3 @@ "use strict"; | ||
let devfileContent = ''; | ||
let dwtName = ''; | ||
let devfileName = ''; | ||
const workDirPath = 'c-plus-plus/strings'; | ||
@@ -45,5 +45,5 @@ const fileName = 'knuth_morris_pratt.cpp'; | ||
const editorDevfileContent = devfilesRegistryHelper.obtainCheDevFileEditorFromCheConfigMap('editors-definitions'); | ||
dwtName = yaml_1.default.parse(devfileContent).metadata.name; | ||
const uniqName = yaml_1.default.parse(devfileContent).metadata.name + randomPref; | ||
kubernetesCommandLineToolsExecutor.workspaceName = uniqName; | ||
devfileName = yaml_1.default.parse(devfileContent).metadata.name; | ||
const uniqueName = yaml_1.default.parse(devfileContent).metadata.name + randomPref; | ||
kubernetesCommandLineToolsExecutor.workspaceName = uniqueName; | ||
devWorkspaceConfigurationHelper = new DevWorkspaceConfigurationHelper_1.DevWorkspaceConfigurationHelper({ | ||
@@ -55,3 +55,3 @@ editorContent: editorDevfileContent, | ||
if (devfileContext.devWorkspace.metadata) { | ||
devfileContext.devWorkspace.metadata.name = uniqName; | ||
devfileContext.devWorkspace.metadata.name = uniqueName; | ||
} | ||
@@ -87,5 +87,5 @@ const devWorkspaceConfigurationYamlString = devWorkspaceConfigurationHelper.getDevWorkspaceConfigurationYamlAsString(devfileContext); | ||
suiteTeardown('Delete workspace', function () { | ||
kubernetesCommandLineToolsExecutor.deleteDevWorkspace(dwtName); | ||
kubernetesCommandLineToolsExecutor.deleteDevWorkspace(devfileName); | ||
}); | ||
}); | ||
//# sourceMappingURL=CppDevFileAPI.spec.js.map |
@@ -32,3 +32,3 @@ "use strict"; | ||
let devfileContent = ''; | ||
let dwtName = ''; | ||
let devfileName = ''; | ||
suiteSetup(`Prepare login ${BASE_TEST_CONSTANTS_1.BASE_TEST_CONSTANTS.TEST_ENVIRONMENT}`, function () { | ||
@@ -42,5 +42,5 @@ kubernetesCommandLineToolsExecutor.loginToOcp(); | ||
const editorDevfileContent = devfilesRegistryHelper.obtainCheDevFileEditorFromCheConfigMap('editors-definitions'); | ||
dwtName = yaml_1.default.parse(devfileContent).metadata.name; | ||
const uniqName = yaml_1.default.parse(devfileContent).metadata.name + randomPref; | ||
kubernetesCommandLineToolsExecutor.workspaceName = uniqName; | ||
devfileName = yaml_1.default.parse(devfileContent).metadata.name; | ||
const uniqueName = yaml_1.default.parse(devfileContent).metadata.name + randomPref; | ||
kubernetesCommandLineToolsExecutor.workspaceName = uniqueName; | ||
devWorkspaceConfigurationHelper = new DevWorkspaceConfigurationHelper_1.DevWorkspaceConfigurationHelper({ | ||
@@ -52,3 +52,3 @@ editorContent: editorDevfileContent, | ||
if (devfileContext.devWorkspace.metadata) { | ||
devfileContext.devWorkspace.metadata.name = uniqName; | ||
devfileContext.devWorkspace.metadata.name = uniqueName; | ||
} | ||
@@ -89,5 +89,5 @@ const devWorkspaceConfigurationYamlString = devWorkspaceConfigurationHelper.getDevWorkspaceConfigurationYamlAsString(devfileContext); | ||
suiteTeardown('Delete DevWorkspace', function () { | ||
kubernetesCommandLineToolsExecutor.deleteDevWorkspace(dwtName); | ||
kubernetesCommandLineToolsExecutor.deleteDevWorkspace(devfileName); | ||
}); | ||
}); | ||
//# sourceMappingURL=DotnetDevFileAPI.spec.js.map |
@@ -32,7 +32,7 @@ "use strict"; | ||
let devfileContent = ''; | ||
let dwtName = ''; | ||
let devfileName = ''; | ||
suiteSetup(`Prepare login ${BASE_TEST_CONSTANTS_1.BASE_TEST_CONSTANTS.TEST_ENVIRONMENT}`, function () { | ||
kubernetesCommandLineToolsExecutor.loginToOcp(); | ||
}); | ||
test(`Create ${devfileID} workspace`, async function () { | ||
test(`Create ${devfileID} workspace`, async function () { | ||
const randomPref = crypto_1.default.randomBytes(4).toString('hex'); | ||
@@ -42,5 +42,5 @@ kubernetesCommandLineToolsExecutor.namespace = API_TEST_CONSTANTS_1.API_TEST_CONSTANTS.TS_API_TEST_NAMESPACE || 'admin-devspaces'; | ||
const editorDevfileContent = devfilesRegistryHelper.obtainCheDevFileEditorFromCheConfigMap('editors-definitions'); | ||
dwtName = yaml_1.default.parse(devfileContent).metadata.name; | ||
const uniqName = yaml_1.default.parse(devfileContent).metadata.name + randomPref; | ||
kubernetesCommandLineToolsExecutor.workspaceName = uniqName; | ||
devfileName = yaml_1.default.parse(devfileContent).metadata.name; | ||
const uniqueName = yaml_1.default.parse(devfileContent).metadata.name + randomPref; | ||
kubernetesCommandLineToolsExecutor.workspaceName = uniqueName; | ||
devWorkspaceConfigurationHelper = new DevWorkspaceConfigurationHelper_1.DevWorkspaceConfigurationHelper({ | ||
@@ -52,3 +52,3 @@ editorContent: editorDevfileContent, | ||
if (devfileContext.devWorkspace.metadata) { | ||
devfileContext.devWorkspace.metadata.name = uniqName; | ||
devfileContext.devWorkspace.metadata.name = uniqueName; | ||
} | ||
@@ -82,5 +82,5 @@ const devWorkspaceConfigurationYamlString = devWorkspaceConfigurationHelper.getDevWorkspaceConfigurationYamlAsString(devfileContext); | ||
suiteTeardown('Delete DevWorkspace', function () { | ||
kubernetesCommandLineToolsExecutor.deleteDevWorkspace(dwtName); | ||
kubernetesCommandLineToolsExecutor.deleteDevWorkspace(devfileName); | ||
}); | ||
}); | ||
//# sourceMappingURL=GoDevFileAPI.spec.js.map |
@@ -32,7 +32,7 @@ "use strict"; | ||
let devfileContent = ''; | ||
let dwtName = ''; | ||
let devfileName = ''; | ||
suiteSetup(`Prepare login ${BASE_TEST_CONSTANTS_1.BASE_TEST_CONSTANTS.TEST_ENVIRONMENT}`, function () { | ||
kubernetesCommandLineToolsExecutor.loginToOcp(); | ||
}); | ||
test(`Create ${devfileID} workspace`, async function () { | ||
test(`Create ${devfileID} workspace`, async function () { | ||
const randomPref = crypto_1.default.randomBytes(4).toString('hex'); | ||
@@ -42,5 +42,5 @@ kubernetesCommandLineToolsExecutor.namespace = API_TEST_CONSTANTS_1.API_TEST_CONSTANTS.TS_API_TEST_NAMESPACE || 'admin-devspaces'; | ||
const editorDevfileContent = devfilesRegistryHelper.obtainCheDevFileEditorFromCheConfigMap('editors-definitions'); | ||
dwtName = yaml_1.default.parse(devfileContent).metadata.name; | ||
const uniqName = yaml_1.default.parse(devfileContent).metadata.name + randomPref; | ||
kubernetesCommandLineToolsExecutor.workspaceName = uniqName; | ||
devfileName = yaml_1.default.parse(devfileContent).metadata.name; | ||
const uniqueName = yaml_1.default.parse(devfileContent).metadata.name + randomPref; | ||
kubernetesCommandLineToolsExecutor.workspaceName = uniqueName; | ||
devWorkspaceConfigurationHelper = new DevWorkspaceConfigurationHelper_1.DevWorkspaceConfigurationHelper({ | ||
@@ -52,3 +52,3 @@ editorContent: editorDevfileContent, | ||
if (devfileContext.devWorkspace.metadata) { | ||
devfileContext.devWorkspace.metadata.name = uniqName; | ||
devfileContext.devWorkspace.metadata.name = uniqueName; | ||
} | ||
@@ -71,5 +71,5 @@ const devWorkspaceConfigurationYamlString = devWorkspaceConfigurationHelper.getDevWorkspaceConfigurationYamlAsString(devfileContext); | ||
suiteTeardown('Delete DevWorkspace', function () { | ||
kubernetesCommandLineToolsExecutor.deleteDevWorkspace(dwtName); | ||
kubernetesCommandLineToolsExecutor.deleteDevWorkspace(devfileName); | ||
}); | ||
}); | ||
//# sourceMappingURL=PhpDevFileAPI.spec.js.map |
@@ -32,7 +32,7 @@ "use strict"; | ||
let devfileContent = ''; | ||
let dwtName = ''; | ||
let devfileName = ''; | ||
suiteSetup(`Prepare login ${BASE_TEST_CONSTANTS_1.BASE_TEST_CONSTANTS.TEST_ENVIRONMENT}`, function () { | ||
kubernetesCommandLineToolsExecutor.loginToOcp(); | ||
}); | ||
test(`Create ${devfileID} workspace`, async function () { | ||
test(`Create ${devfileID} workspace`, async function () { | ||
const randomPref = crypto_1.default.randomBytes(4).toString('hex'); | ||
@@ -42,5 +42,5 @@ kubernetesCommandLineToolsExecutor.namespace = API_TEST_CONSTANTS_1.API_TEST_CONSTANTS.TS_API_TEST_NAMESPACE || 'admin-devspaces'; | ||
const editorDevfileContent = devfilesRegistryHelper.obtainCheDevFileEditorFromCheConfigMap('editors-definitions'); | ||
dwtName = yaml_1.default.parse(devfileContent).metadata.name; | ||
const uniqName = yaml_1.default.parse(devfileContent).metadata.name + randomPref; | ||
kubernetesCommandLineToolsExecutor.workspaceName = uniqName; | ||
devfileName = yaml_1.default.parse(devfileContent).metadata.name; | ||
const uniqueName = yaml_1.default.parse(devfileContent).metadata.name + randomPref; | ||
kubernetesCommandLineToolsExecutor.workspaceName = uniqueName; | ||
devWorkspaceConfigurationHelper = new DevWorkspaceConfigurationHelper_1.DevWorkspaceConfigurationHelper({ | ||
@@ -52,3 +52,3 @@ editorContent: editorDevfileContent, | ||
if (devfileContext.devWorkspace.metadata) { | ||
devfileContext.devWorkspace.metadata.name = uniqName; | ||
devfileContext.devWorkspace.metadata.name = uniqueName; | ||
} | ||
@@ -71,5 +71,5 @@ const devWorkspaceConfigurationYamlString = devWorkspaceConfigurationHelper.getDevWorkspaceConfigurationYamlAsString(devfileContext); | ||
suiteTeardown('Delete DevWorkspace', function () { | ||
kubernetesCommandLineToolsExecutor.deleteDevWorkspace(dwtName); | ||
kubernetesCommandLineToolsExecutor.deleteDevWorkspace(devfileName); | ||
}); | ||
}); | ||
//# sourceMappingURL=PythonDevFileAPI.spec.js.map |
@@ -40,3 +40,3 @@ "use strict"; | ||
try { | ||
({ docs, links, productVersion } = JSON.parse(shellExecutor.curl(`https://raw.githubusercontent.com/redhat-developer/devspaces-images/devspaces-${majorMinorVersion}-rhel-8/devspaces-dashboard/packages/dashboard-frontend/assets/branding/product.json`))); | ||
({ docs, links, productVersion } = JSON.parse(shellExecutor.curl(`https://raw.githubusercontent.com/redhat-developer/devspaces-images/devspaces-${majorMinorVersion}-rhel-9/devspaces-dashboard/packages/dashboard-frontend/assets/branding/product.json`))); | ||
} | ||
@@ -43,0 +43,0 @@ catch (e) { |
@@ -115,14 +115,15 @@ "use strict"; | ||
} | ||
deleteDevWorkspace(dwTemplateName) { | ||
deleteDevWorkspace(devfileName) { | ||
Logger_1.Logger.debug(`${this.kubernetesCommandLineTool} - delete '${this.workspaceName}' devWorkspace`); | ||
this.shellExecutor.executeCommand(`${this.kubernetesCommandLineTool} patch dw ${this.workspaceName} -n ${this.namespace} -p '{ "metadata": { "finalizers": null }}' --type merge || true`); | ||
this.shellExecutor.executeCommand(`${this.kubernetesCommandLineTool} delete dw ${this.workspaceName} -n ${this.namespace} || true`); | ||
if (dwTemplateName === undefined) { | ||
Logger_1.Logger.debug(`${this.kubernetesCommandLineTool} - delete '${this.workspaceName}' devWorkspaceTemplate`); | ||
this.shellExecutor.executeCommand(`${this.kubernetesCommandLineTool} delete dwt ${BASE_TEST_CONSTANTS_1.BASE_TEST_CONSTANTS.TS_SELENIUM_EDITOR}-${this.workspaceName} -n ${this.namespace} || true`); | ||
let dwtName; | ||
if (devfileName === undefined) { | ||
dwtName = `${BASE_TEST_CONSTANTS_1.BASE_TEST_CONSTANTS.TS_SELENIUM_EDITOR}-${this.workspaceName}`; | ||
} | ||
else { | ||
Logger_1.Logger.debug(`${this.kubernetesCommandLineTool} - delete '${dwTemplateName}' devWorkspaceTemplate`); | ||
this.shellExecutor.executeCommand(`${this.kubernetesCommandLineTool} delete dwt ${BASE_TEST_CONSTANTS_1.BASE_TEST_CONSTANTS.TS_SELENIUM_EDITOR}-${dwTemplateName} -n ${this.namespace} || true`); | ||
dwtName = `${BASE_TEST_CONSTANTS_1.BASE_TEST_CONSTANTS.TS_SELENIUM_EDITOR}-${devfileName}`; | ||
} | ||
Logger_1.Logger.debug(`${this.kubernetesCommandLineTool} - delete '${dwtName}' devWorkspaceTemplate`); | ||
this.shellExecutor.executeCommand(`${this.kubernetesCommandLineTool} delete dwt ${dwtName} -n ${this.namespace} || true`); | ||
} | ||
@@ -129,0 +130,0 @@ applyAndWaitDevWorkspace(yamlConfiguration) { |
{ | ||
"name": "@eclipse-che/che-e2e", | ||
"version": "7.97.0-next-dfc2d2b", | ||
"version": "7.97.0", | ||
"description": "", | ||
@@ -69,3 +69,4 @@ "main": "dist/index.js", | ||
"inversify": "6.0.1", | ||
"reflect-metadata": "0.1.13" | ||
"reflect-metadata": "0.1.13", | ||
"@eclipse-che/che-devworkspace-generator": "7.97.0" | ||
}, | ||
@@ -72,0 +73,0 @@ "resolutions": { |
@@ -5,5 +5,5 @@ # Module for launch E2E tests related to Che 7 | ||
- node 16.x | ||
- "Chrome" browser 114.x or later | ||
- deployed Che 7 with accessible URL | ||
- node 16.x | ||
- "Chrome" browser 114.x or later | ||
- deployed Che 7 with accessible URL | ||
@@ -14,4 +14,4 @@ ## Before launch | ||
- `export TS_SELENIUM_BASE_URL=<Che7 URL>` | ||
- `npm ci` | ||
- `export TS_SELENIUM_BASE_URL=<Che7 URL>` | ||
- `npm ci` | ||
@@ -22,14 +22,14 @@ Note: If there is any modifications in package.json, manually execute the `npm install` to update the package-lock.json. So that errors can be avoided while executing npm ci | ||
- Provide connection credentials: | ||
- `export TS_SELENIUM_OCP_USERNAME=<username>` | ||
- `export TS_SELENIUM_OCP_PASSWORD=<password>` | ||
- `npm run test` | ||
- Provide connection credentials: | ||
- `export TS_SELENIUM_OCP_USERNAME=<username>` | ||
- `export TS_SELENIUM_OCP_PASSWORD=<password>` | ||
- `npm run test` | ||
## Custom launch | ||
- Use environment variables which described in the "constants" folder | ||
- Use environment variables for setting timeouts if needed. You can see the list in **`'TimeoutConstants.ts'`**. You can see the list of those variables and their value if you set the `'TS_SELENIUM_PRINT_TIMEOUT_VARIABLES = true'` | ||
- To test one specification export file name as `export USERSTORY=<spec-file-name-without-extension> && npm run test` (example: `-e USERSTORY=Quarkus`) | ||
- To run test without Selenium WebDriver (API tests etc.) use `export USERSTORY=<spec-file-name-without-extension> && npm run driver-less-test` (example: `-e USERSTORY=CloneGitRepoAPI`) | ||
- This project support application testing deployed on Kubernetes or Openshift platform. Openshift is default value. To switch into Kubernetes, please, use `TS_PLATFORM=kubernetes` environmental variable and `TS_SELENIUM_K8S_PASSWORD`, `TS_SELENIUM_K8S_USERNAME` to provide credentials. The sample of test command in this case: | ||
- Use environment variables which described in the "constants" folder | ||
- Use environment variables for setting timeouts if needed. You can see the list in **`'TimeoutConstants.ts'`**. You can see the list of those variables and their value if you set the `'TS_SELENIUM_PRINT_TIMEOUT_VARIABLES = true'` | ||
- To test one specification export file name as `export USERSTORY=<spec-file-name-without-extension> && npm run test` (example: `-e USERSTORY=Quarkus`) | ||
- To run test without Selenium WebDriver (API tests etc.) use `export USERSTORY=<spec-file-name-without-extension> && npm run driver-less-test` (example: `-e USERSTORY=CloneGitRepoAPI`) | ||
- This project support application testing deployed on Kubernetes or Openshift platform. Openshift is default value. To switch into Kubernetes, please, use `TS_PLATFORM=kubernetes` environmental variable and `TS_SELENIUM_K8S_PASSWORD`, `TS_SELENIUM_K8S_USERNAME` to provide credentials. The sample of test command in this case: | ||
``` | ||
@@ -43,9 +43,9 @@ export TS_PLATFORM=kubernetes && \ | ||
Also, environmental variables can be set in files in "constants" folder. | ||
- Local test results can be represented with Allure reporter `npm run open-allure-dasboard` | ||
- Local test results can be represented with Allure reporter `npm run open-allure-dasboard` | ||
## Docker launch | ||
- open terminal and go to the "e2e" directory | ||
- export the `"TS_SELENIUM_BASE_URL"` variable with "Che" url | ||
- run command `"npm run test-docker"` | ||
- open terminal and go to the "e2e" directory | ||
- export the `"TS_SELENIUM_BASE_URL"` variable with "Che" url | ||
- run command `"npm run test-docker"` | ||
@@ -56,5 +56,5 @@ ## Docker launch with changed tests | ||
- open terminal and go to the "e2e" directory | ||
- export the `"TS_SELENIUM_BASE_URL"` variable with "Che" url | ||
- run command `"npm run test-docker-mount-e2e"` | ||
- open terminal and go to the "e2e" directory | ||
- export the `"TS_SELENIUM_BASE_URL"` variable with "Che" url | ||
- run command `"npm run test-docker-mount-e2e"` | ||
@@ -70,10 +70,10 @@ ## Debug docker launch | ||
- Deploy Che on Kubernetes infrastructure by using 'Minikube' and 'Chectl' <https://github.com/eclipse-che/che-server/blob/HEAD/deploy/kubernetes/README.md> | ||
- Create workspace by using 'Chectl' and devfile | ||
- link to 'Chectl' manual <https://github.com/che-incubator/chectl#chectl-workspacestart> | ||
- link to devfile ( **`For successfull test passing, exactly provided devfile should be used`** ) | ||
<https://gist.githubusercontent.com/Ohrimenko1988/93f5426f4ebc1705c55feb8ff0396a49/raw/cbea89ad145ba33ed34a151a12c50f045f9f3b78/yaml-ls-bug.yaml> | ||
- Provide the **`'TS_SELENIUM_BASE_URL'`** environment variable as described above | ||
- export TS_SELENIUM_HAPPY_PATH_WORKSPACE_NAME=EmptyWorkspace (default value, see BASE_TEST_CONSTANTS.ts) | ||
- perform command **`export USERSTORY=$TS_SELENIUM_HAPPY_PATH_WORKSPACE_NAME && npm run test-all-devfiles`** | ||
- Deploy Che on Kubernetes infrastructure by using 'Minikube' and 'Chectl' <https://github.com/eclipse-che/che-server/blob/HEAD/deploy/kubernetes/README.md> | ||
- Create workspace by using 'Chectl' and devfile | ||
- link to 'Chectl' manual <https://github.com/che-incubator/chectl#chectl-workspacestart> | ||
- link to devfile ( **`For successfull test passing, exactly provided devfile should be used`** ) | ||
<https://gist.githubusercontent.com/Ohrimenko1988/93f5426f4ebc1705c55feb8ff0396a49/raw/cbea89ad145ba33ed34a151a12c50f045f9f3b78/yaml-ls-bug.yaml> | ||
- Provide the **`'TS_SELENIUM_BASE_URL'`** environment variable as described above | ||
- export TS_SELENIUM_HAPPY_PATH_WORKSPACE_NAME=EmptyWorkspace (default value, see BASE_TEST_CONSTANTS.ts) | ||
- perform command **`export USERSTORY=$TS_SELENIUM_HAPPY_PATH_WORKSPACE_NAME && npm run test-all-devfiles`** | ||
@@ -84,12 +84,12 @@ ## Launching the DevWorkspaceHappyPath spec file using Che with oauth authentication | ||
- export TS_SELENIUM_BASE_URL=\<Che-URL\> | ||
- export TS_SELENIUM_OCP_USERNAME=\<cluster-username\> | ||
- export TS_SELENIUM_OCP_PASSWORD=\<cluster-password\> | ||
- export TS_SELENIUM_VALUE_OPENSHIFT_OAUTH="true" | ||
- export TS_OCP_LOGIN_PAGE_PROVIDER_TITLE=\<login-provide-title\> | ||
- export TS_SELENIUM_DEVWORKSPACE_URL=\<devworkspace-url\> | ||
- export TS_SELENIUM_HAPPY_PATH_WORKSPACE_NAME=EmptyWorkspace (default value, see BASE_TEST_CONSTANTS.ts) | ||
- export TS_SELENIUM_BASE_URL=\<Che-URL\> | ||
- export TS_SELENIUM_OCP_USERNAME=\<cluster-username\> | ||
- export TS_SELENIUM_OCP_PASSWORD=\<cluster-password\> | ||
- export TS_SELENIUM_VALUE_OPENSHIFT_OAUTH="true" | ||
- export TS_OCP_LOGIN_PAGE_PROVIDER_TITLE=\<login-provide-title\> | ||
- export TS_SELENIUM_DEVWORKSPACE_URL=\<devworkspace-url\> | ||
- export TS_SELENIUM_HAPPY_PATH_WORKSPACE_NAME=EmptyWorkspace (default value, see BASE_TEST_CONSTANTS.ts) | ||
**Execute the npm command:** | ||
- perform command `export USERSTORY=$TS_SELENIUM_HAPPY_PATH_WORKSPACE_NAME && npm run test-all-devfiles` | ||
- perform command `export USERSTORY=$TS_SELENIUM_HAPPY_PATH_WORKSPACE_NAME && npm run test-all-devfiles` |
@@ -35,3 +35,3 @@ /** ******************************************************************* | ||
let devfileContent: string = ''; | ||
let dwtName: string = ''; | ||
let devfileName: string = ''; | ||
const workDirPath: string = 'c-plus-plus/strings'; | ||
@@ -50,5 +50,5 @@ const fileName: string = 'knuth_morris_pratt.cpp'; | ||
const editorDevfileContent: string = devfilesRegistryHelper.obtainCheDevFileEditorFromCheConfigMap('editors-definitions'); | ||
dwtName = YAML.parse(devfileContent).metadata.name; | ||
const uniqName: string = YAML.parse(devfileContent).metadata.name + randomPref; | ||
kubernetesCommandLineToolsExecutor.workspaceName = uniqName; | ||
devfileName = YAML.parse(devfileContent).metadata.name; | ||
const uniqueName: string = YAML.parse(devfileContent).metadata.name + randomPref; | ||
kubernetesCommandLineToolsExecutor.workspaceName = uniqueName; | ||
@@ -61,3 +61,3 @@ devWorkspaceConfigurationHelper = new DevWorkspaceConfigurationHelper({ | ||
if (devfileContext.devWorkspace.metadata) { | ||
devfileContext.devWorkspace.metadata.name = uniqName; | ||
devfileContext.devWorkspace.metadata.name = uniqueName; | ||
} | ||
@@ -98,4 +98,4 @@ const devWorkspaceConfigurationYamlString: string = | ||
suiteTeardown('Delete workspace', function (): void { | ||
kubernetesCommandLineToolsExecutor.deleteDevWorkspace(dwtName); | ||
kubernetesCommandLineToolsExecutor.deleteDevWorkspace(devfileName); | ||
}); | ||
}); |
@@ -34,3 +34,3 @@ /** ******************************************************************* | ||
let devfileContent: string = ''; | ||
let dwtName: string = ''; | ||
let devfileName: string = ''; | ||
@@ -46,5 +46,5 @@ suiteSetup(`Prepare login ${BASE_TEST_CONSTANTS.TEST_ENVIRONMENT}`, function (): void { | ||
const editorDevfileContent: string = devfilesRegistryHelper.obtainCheDevFileEditorFromCheConfigMap('editors-definitions'); | ||
dwtName = YAML.parse(devfileContent).metadata.name; | ||
const uniqName: string = YAML.parse(devfileContent).metadata.name + randomPref; | ||
kubernetesCommandLineToolsExecutor.workspaceName = uniqName; | ||
devfileName = YAML.parse(devfileContent).metadata.name; | ||
const uniqueName: string = YAML.parse(devfileContent).metadata.name + randomPref; | ||
kubernetesCommandLineToolsExecutor.workspaceName = uniqueName; | ||
@@ -57,3 +57,3 @@ devWorkspaceConfigurationHelper = new DevWorkspaceConfigurationHelper({ | ||
if (devfileContext.devWorkspace.metadata) { | ||
devfileContext.devWorkspace.metadata.name = uniqName; | ||
devfileContext.devWorkspace.metadata.name = uniqueName; | ||
} | ||
@@ -100,4 +100,4 @@ const devWorkspaceConfigurationYamlString: string = | ||
suiteTeardown('Delete DevWorkspace', function (): void { | ||
kubernetesCommandLineToolsExecutor.deleteDevWorkspace(dwtName); | ||
kubernetesCommandLineToolsExecutor.deleteDevWorkspace(devfileName); | ||
}); | ||
}); |
@@ -35,3 +35,3 @@ /** ******************************************************************* | ||
let devfileContent: string = ''; | ||
let dwtName: string = ''; | ||
let devfileName: string = ''; | ||
@@ -42,3 +42,3 @@ suiteSetup(`Prepare login ${BASE_TEST_CONSTANTS.TEST_ENVIRONMENT}`, function (): void { | ||
test(`Create ${devfileID} workspace`, async function (): Promise<void> { | ||
test(`Create ${devfileID} workspace`, async function (): Promise<void> { | ||
const randomPref: string = crypto.randomBytes(4).toString('hex'); | ||
@@ -48,5 +48,5 @@ kubernetesCommandLineToolsExecutor.namespace = API_TEST_CONSTANTS.TS_API_TEST_NAMESPACE || 'admin-devspaces'; | ||
const editorDevfileContent: string = devfilesRegistryHelper.obtainCheDevFileEditorFromCheConfigMap('editors-definitions'); | ||
dwtName = YAML.parse(devfileContent).metadata.name; | ||
const uniqName: string = YAML.parse(devfileContent).metadata.name + randomPref; | ||
kubernetesCommandLineToolsExecutor.workspaceName = uniqName; | ||
devfileName = YAML.parse(devfileContent).metadata.name; | ||
const uniqueName: string = YAML.parse(devfileContent).metadata.name + randomPref; | ||
kubernetesCommandLineToolsExecutor.workspaceName = uniqueName; | ||
@@ -59,3 +59,3 @@ devWorkspaceConfigurationHelper = new DevWorkspaceConfigurationHelper({ | ||
if (devfileContext.devWorkspace.metadata) { | ||
devfileContext.devWorkspace.metadata.name = uniqName; | ||
devfileContext.devWorkspace.metadata.name = uniqueName; | ||
} | ||
@@ -94,4 +94,4 @@ const devWorkspaceConfigurationYamlString: string = | ||
suiteTeardown('Delete DevWorkspace', function (): void { | ||
kubernetesCommandLineToolsExecutor.deleteDevWorkspace(dwtName); | ||
kubernetesCommandLineToolsExecutor.deleteDevWorkspace(devfileName); | ||
}); | ||
}); |
@@ -34,3 +34,3 @@ /** ******************************************************************* | ||
let devfileContent: string = ''; | ||
let dwtName: string = ''; | ||
let devfileName: string = ''; | ||
@@ -41,3 +41,3 @@ suiteSetup(`Prepare login ${BASE_TEST_CONSTANTS.TEST_ENVIRONMENT}`, function (): void { | ||
test(`Create ${devfileID} workspace`, async function (): Promise<void> { | ||
test(`Create ${devfileID} workspace`, async function (): Promise<void> { | ||
const randomPref: string = crypto.randomBytes(4).toString('hex'); | ||
@@ -47,5 +47,5 @@ kubernetesCommandLineToolsExecutor.namespace = API_TEST_CONSTANTS.TS_API_TEST_NAMESPACE || 'admin-devspaces'; | ||
const editorDevfileContent: string = devfilesRegistryHelper.obtainCheDevFileEditorFromCheConfigMap('editors-definitions'); | ||
dwtName = YAML.parse(devfileContent).metadata.name; | ||
const uniqName: string = YAML.parse(devfileContent).metadata.name + randomPref; | ||
kubernetesCommandLineToolsExecutor.workspaceName = uniqName; | ||
devfileName = YAML.parse(devfileContent).metadata.name; | ||
const uniqueName: string = YAML.parse(devfileContent).metadata.name + randomPref; | ||
kubernetesCommandLineToolsExecutor.workspaceName = uniqueName; | ||
@@ -58,3 +58,3 @@ devWorkspaceConfigurationHelper = new DevWorkspaceConfigurationHelper({ | ||
if (devfileContext.devWorkspace.metadata) { | ||
devfileContext.devWorkspace.metadata.name = uniqName; | ||
devfileContext.devWorkspace.metadata.name = uniqueName; | ||
} | ||
@@ -80,4 +80,4 @@ const devWorkspaceConfigurationYamlString: string = | ||
suiteTeardown('Delete DevWorkspace', function (): void { | ||
kubernetesCommandLineToolsExecutor.deleteDevWorkspace(dwtName); | ||
kubernetesCommandLineToolsExecutor.deleteDevWorkspace(devfileName); | ||
}); | ||
}); |
@@ -35,3 +35,3 @@ /** ******************************************************************* | ||
let devfileContent: string = ''; | ||
let dwtName: string = ''; | ||
let devfileName: string = ''; | ||
@@ -42,3 +42,3 @@ suiteSetup(`Prepare login ${BASE_TEST_CONSTANTS.TEST_ENVIRONMENT}`, function (): void { | ||
test(`Create ${devfileID} workspace`, async function (): Promise<void> { | ||
test(`Create ${devfileID} workspace`, async function (): Promise<void> { | ||
const randomPref: string = crypto.randomBytes(4).toString('hex'); | ||
@@ -48,5 +48,5 @@ kubernetesCommandLineToolsExecutor.namespace = API_TEST_CONSTANTS.TS_API_TEST_NAMESPACE || 'admin-devspaces'; | ||
const editorDevfileContent: string = devfilesRegistryHelper.obtainCheDevFileEditorFromCheConfigMap('editors-definitions'); | ||
dwtName = YAML.parse(devfileContent).metadata.name; | ||
const uniqName: string = YAML.parse(devfileContent).metadata.name + randomPref; | ||
kubernetesCommandLineToolsExecutor.workspaceName = uniqName; | ||
devfileName = YAML.parse(devfileContent).metadata.name; | ||
const uniqueName: string = YAML.parse(devfileContent).metadata.name + randomPref; | ||
kubernetesCommandLineToolsExecutor.workspaceName = uniqueName; | ||
@@ -59,3 +59,3 @@ devWorkspaceConfigurationHelper = new DevWorkspaceConfigurationHelper({ | ||
if (devfileContext.devWorkspace.metadata) { | ||
devfileContext.devWorkspace.metadata.name = uniqName; | ||
devfileContext.devWorkspace.metadata.name = uniqueName; | ||
} | ||
@@ -81,4 +81,4 @@ const devWorkspaceConfigurationYamlString: string = | ||
suiteTeardown('Delete DevWorkspace', function (): void { | ||
kubernetesCommandLineToolsExecutor.deleteDevWorkspace(dwtName); | ||
kubernetesCommandLineToolsExecutor.deleteDevWorkspace(devfileName); | ||
}); | ||
}); |
@@ -58,3 +58,3 @@ /** ******************************************************************* | ||
shellExecutor.curl( | ||
`https://raw.githubusercontent.com/redhat-developer/devspaces-images/devspaces-${majorMinorVersion}-rhel-8/devspaces-dashboard/packages/dashboard-frontend/assets/branding/product.json` | ||
`https://raw.githubusercontent.com/redhat-developer/devspaces-images/devspaces-${majorMinorVersion}-rhel-9/devspaces-dashboard/packages/dashboard-frontend/assets/branding/product.json` | ||
) | ||
@@ -61,0 +61,0 @@ )); |
@@ -97,9 +97,3 @@ /** ******************************************************************* | ||
// used to delete when devWorkspace and devWorkspaceTemplate have the same names | ||
deleteDevWorkspace(): void; | ||
// used to delete when devWorkspace and devWorkspaceTemplate have different names | ||
deleteDevWorkspace(dwTemplateName: string): void; | ||
deleteDevWorkspace(dwTemplateName?: string): void { | ||
deleteDevWorkspace(devfileName?: string): void { | ||
Logger.debug(`${this.kubernetesCommandLineTool} - delete '${this.workspaceName}' devWorkspace`); | ||
@@ -112,15 +106,12 @@ | ||
if (dwTemplateName === undefined) { | ||
Logger.debug(`${this.kubernetesCommandLineTool} - delete '${this.workspaceName}' devWorkspaceTemplate`); | ||
this.shellExecutor.executeCommand( | ||
`${this.kubernetesCommandLineTool} delete dwt ${BASE_TEST_CONSTANTS.TS_SELENIUM_EDITOR}-${this.workspaceName} -n ${this.namespace} || true` | ||
); | ||
let dwtName: string; | ||
if (devfileName === undefined) { | ||
dwtName = `${BASE_TEST_CONSTANTS.TS_SELENIUM_EDITOR}-${this.workspaceName}`; | ||
} else { | ||
Logger.debug(`${this.kubernetesCommandLineTool} - delete '${dwTemplateName}' devWorkspaceTemplate`); | ||
dwtName = `${BASE_TEST_CONSTANTS.TS_SELENIUM_EDITOR}-${devfileName}`; | ||
} | ||
this.shellExecutor.executeCommand( | ||
`${this.kubernetesCommandLineTool} delete dwt ${BASE_TEST_CONSTANTS.TS_SELENIUM_EDITOR}-${dwTemplateName} -n ${this.namespace} || true` | ||
); | ||
} | ||
Logger.debug(`${this.kubernetesCommandLineTool} - delete '${dwtName}' devWorkspaceTemplate`); | ||
this.shellExecutor.executeCommand(`${this.kubernetesCommandLineTool} delete dwt ${dwtName} -n ${this.namespace} || true`); | ||
} | ||
@@ -127,0 +118,0 @@ |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Unidentified License
License(Experimental) Something that seems like a license was found, but its contents could not be matched with a known license.
Found 2 instances in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
No v1
QualityPackage is not semver >=1. This means it is not stable and does not support ^ ranges.
Found 1 instance in 1 package
Unidentified License
License(Experimental) Something that seems like a license was found, but its contents could not be matched with a known license.
Found 2 instances in 1 package
1307685
328
18703
1
4
+ Added@devfile/api@2.3.0-1733171449(transitive)
+ Added@eclipse-che/che-devworkspace-generator@7.97.0(transitive)
+ Added@inversifyjs/common@1.4.0(transitive)
+ Added@inversifyjs/core@1.3.5(transitive)
+ Added@inversifyjs/reflect-metadata-utils@0.2.4(transitive)
+ Added@types/node@22.10.5(transitive)
+ Added@types/node-fetch@2.6.12(transitive)
+ Addedargparse@2.0.1(transitive)
+ Addedasynckit@0.4.0(transitive)
+ Addedaxios@1.7.9(transitive)
+ Addedcombined-stream@1.0.8(transitive)
+ Addeddelayed-stream@1.0.0(transitive)
+ Addedes6-promise@4.2.8(transitive)
+ Addedfollow-redirects@1.15.9(transitive)
+ Addedform-data@2.5.24.0.1(transitive)
+ Addedfs-extra@11.2.0(transitive)
+ Addedgraceful-fs@4.2.11(transitive)
+ Addedinversify@6.2.1(transitive)
+ Addedjs-yaml@4.1.0(transitive)
+ Addedjsonc-parser@3.3.1(transitive)
+ Addedjsonfile@6.1.0(transitive)
+ Addedjsonschema@1.5.0(transitive)
+ Addedmime-db@1.52.0(transitive)
+ Addedmime-types@2.1.35(transitive)
+ Addednode-fetch@2.7.0(transitive)
+ Addedproxy-from-env@1.1.0(transitive)
+ Addedquerystringify@2.2.0(transitive)
+ Addedreflect-metadata@0.2.2(transitive)
+ Addedrequires-port@1.0.0(transitive)
+ Addedsafe-buffer@5.2.1(transitive)
+ Addedtr46@0.0.3(transitive)
+ Addedundici-types@6.20.0(transitive)
+ Addeduniversalify@2.0.1(transitive)
+ Addedurl-parse@1.5.10(transitive)
+ Addedwebidl-conversions@3.0.1(transitive)
+ Addedwhatwg-url@5.0.0(transitive)