@eclipse-che/che-e2e 7.46.1-dev-cc22326 → 7.46.1-dev-957e450
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/dist/driver/CheReporter.js +2 -5
- package/dist/driver/CheReporter.js.map +1 -1
- package/dist/pageobjects/ide/Editor.js +1 -1
- package/dist/pageobjects/ide/Editor.js.map +1 -1
- package/dist/pageobjects/ide/PreviewWidget.js +3 -0
- package/dist/pageobjects/ide/PreviewWidget.js.map +1 -1
- package/dist/pageobjects/ide/ProjectTree.js +12 -6
- package/dist/pageobjects/ide/ProjectTree.js.map +1 -1
- package/dist/tests/devfiles/CSlashCPlusPlus.spec.js +2 -10
- package/dist/tests/devfiles/CSlashCPlusPlus.spec.js.map +1 -1
- package/dist/tests/devfiles/DevfileSmoke.spec.js +2 -10
- package/dist/tests/devfiles/DevfileSmoke.spec.js.map +1 -1
- package/dist/tests/devfiles/DotNetCore.spec.js +2 -10
- package/dist/tests/devfiles/DotNetCore.spec.js.map +1 -1
- package/dist/tests/devfiles/Go.spec.js +2 -10
- package/dist/tests/devfiles/Go.spec.js.map +1 -1
- package/dist/tests/devfiles/JavaMaven.spec.js +2 -10
- package/dist/tests/devfiles/JavaMaven.spec.js.map +1 -1
- package/dist/tests/devfiles/JavaSpringBoot.spec.js +2 -10
- package/dist/tests/devfiles/JavaSpringBoot.spec.js.map +1 -1
- package/dist/tests/devfiles/JavaVertx.spec.js +2 -10
- package/dist/tests/devfiles/JavaVertx.spec.js.map +1 -1
- package/dist/tests/devfiles/NodeJS.spec.js +2 -10
- package/dist/tests/devfiles/NodeJS.spec.js.map +1 -1
- package/dist/tests/devfiles/PHPSimple.spec.js +2 -10
- package/dist/tests/devfiles/PHPSimple.spec.js.map +1 -1
- package/dist/tests/devfiles/Python.spec.js +2 -10
- package/dist/tests/devfiles/Python.spec.js.map +1 -1
- package/dist/tests/devfiles/PythonDjango.spec.js +2 -10
- package/dist/tests/devfiles/PythonDjango.spec.js.map +1 -1
- package/dist/tests/devfiles/Quarkus.spec.js +2 -10
- package/dist/tests/devfiles/Quarkus.spec.js.map +1 -1
- package/dist/tests/devfiles/Scala.spec.js +2 -10
- package/dist/tests/devfiles/Scala.spec.js.map +1 -1
- package/dist/tests/e2e/FactoryUrl.spec.js +4 -9
- package/dist/tests/e2e/FactoryUrl.spec.js.map +1 -1
- package/dist/tests/e2e/GitPublishBranch.spec.js +2 -5
- package/dist/tests/e2e/GitPublishBranch.spec.js.map +1 -1
- package/dist/tests/e2e/GitSelfSignCert.spec.js +2 -0
- package/dist/tests/e2e/GitSelfSignCert.spec.js.map +1 -1
- package/dist/tests/e2e/GitSsh.spec.js +3 -6
- package/dist/tests/e2e/GitSsh.spec.js.map +1 -1
- package/dist/tests/e2e/OpenshiftConnector.spec.js +2 -5
- package/dist/tests/e2e/OpenshiftConnector.spec.js.map +1 -1
- package/dist/tests/e2e/factories/DirectUrlFactoryWithKeepDirectoryTest.spec.js +3 -7
- package/dist/tests/e2e/factories/DirectUrlFactoryWithKeepDirectoryTest.spec.js.map +1 -1
- package/dist/tests/e2e/factories/DirectUrlFactoryWithRootFolderTest.spec.js +3 -7
- package/dist/tests/e2e/factories/DirectUrlFactoryWithRootFolderTest.spec.js.map +1 -1
- package/dist/tests/e2e/factories/DirectUrlFactoryWithSpecificBranchTest.spec.js +3 -7
- package/dist/tests/e2e/factories/DirectUrlFactoryWithSpecificBranchTest.spec.js.map +1 -1
- package/dist/tests/e2e_happy_path/DevWorkspaceHappyPath.spec.js +2 -2
- package/dist/tests/e2e_happy_path/DevWorkspaceHappyPath.spec.js.map +1 -1
- package/dist/tests/e2e_happy_path/HappyPath.spec.js +13 -13
- package/dist/tests/e2e_happy_path/HappyPath.spec.js.map +1 -1
- package/dist/tests/intelij/IntelijOpenWorkspace.spec.js +2 -6
- package/dist/tests/intelij/IntelijOpenWorkspace.spec.js.map +1 -1
- package/dist/tests/load_test/LoadTest.spec.js +2 -5
- package/dist/tests/load_test/LoadTest.spec.js.map +1 -1
- package/dist/tests/login/LinkCheAndOcpUsers.spec.js +2 -2
- package/dist/tests/login/LinkCheAndOcpUsers.spec.js.map +1 -1
- package/dist/tests/plugins/GitHubPullRequestPlugin.spec.js +4 -9
- package/dist/tests/plugins/GitHubPullRequestPlugin.spec.js.map +1 -1
- package/dist/tests/plugins/InstallPluginUsingUI.spec.js +4 -10
- package/dist/tests/plugins/InstallPluginUsingUI.spec.js.map +1 -1
- package/dist/tests/plugins/JavaPlugin.spec.js +4 -8
- package/dist/tests/plugins/JavaPlugin.spec.js.map +1 -1
- package/dist/tests/plugins/PhpPlugin.spec.js +12 -10
- package/dist/tests/plugins/PhpPlugin.spec.js.map +1 -1
- package/dist/tests/plugins/PythonPlugin.spec.js +4 -8
- package/dist/tests/plugins/PythonPlugin.spec.js.map +1 -1
- package/dist/tests/plugins/TypescriptPlugin.spec.js +4 -8
- package/dist/tests/plugins/TypescriptPlugin.spec.js.map +1 -1
- package/dist/tests/plugins/VscodeKubernetesPlugin.spec.js +3 -10
- package/dist/tests/plugins/VscodeKubernetesPlugin.spec.js.map +1 -1
- package/dist/tests/plugins/VscodeShellcheckPlugin.spec.js +3 -10
- package/dist/tests/plugins/VscodeShellcheckPlugin.spec.js.map +1 -1
- package/dist/tests/plugins/VscodeValePlugin.spec.js +3 -10
- package/dist/tests/plugins/VscodeValePlugin.spec.js.map +1 -1
- package/dist/tests/plugins/VscodeXmlPlugin.spec.js +10 -22
- package/dist/tests/plugins/VscodeXmlPlugin.spec.js.map +1 -1
- package/dist/tests/plugins/VscodeYamlPlugin.spec.js +4 -8
- package/dist/tests/plugins/VscodeYamlPlugin.spec.js.map +1 -1
- package/dist/testsLibrary/CodeExecutionTests.js +52 -29
- package/dist/testsLibrary/CodeExecutionTests.js.map +1 -1
- package/dist/testsLibrary/WorkspaceHandlingTests.js +68 -11
- package/dist/testsLibrary/WorkspaceHandlingTests.js.map +1 -1
- package/driver/CheReporter.ts +2 -8
- package/package.json +1 -1
- package/pageobjects/ide/Editor.ts +1 -1
- package/pageobjects/ide/PreviewWidget.ts +3 -0
- package/pageobjects/ide/ProjectTree.ts +13 -8
- package/tests/devfiles/CSlashCPlusPlus.spec.ts +2 -9
- package/tests/devfiles/DevfileSmoke.spec.ts +2 -9
- package/tests/devfiles/DotNetCore.spec.ts +2 -9
- package/tests/devfiles/Go.spec.ts +2 -7
- package/tests/devfiles/JavaMaven.spec.ts +2 -9
- package/tests/devfiles/JavaSpringBoot.spec.ts +2 -9
- package/tests/devfiles/JavaVertx.spec.ts +2 -9
- package/tests/devfiles/NodeJS.spec.ts +2 -9
- package/tests/devfiles/PHPSimple.spec.ts +2 -9
- package/tests/devfiles/Python.spec.ts +2 -9
- package/tests/devfiles/PythonDjango.spec.ts +2 -9
- package/tests/devfiles/Quarkus.spec.ts +2 -9
- package/tests/devfiles/Scala.spec.ts +2 -10
- package/tests/e2e/FactoryUrl.spec.ts +4 -8
- package/tests/e2e/GitPublishBranch.spec.ts +2 -2
- package/tests/e2e/GitSelfSignCert.spec.ts +66 -65
- package/tests/e2e/GitSsh.spec.ts +3 -3
- package/tests/e2e/OpenshiftConnector.spec.ts +2 -2
- package/tests/e2e/factories/DirectUrlFactoryWithKeepDirectoryTest.spec.ts +2 -5
- package/tests/e2e/factories/DirectUrlFactoryWithRootFolderTest.spec.ts +2 -5
- package/tests/e2e/factories/DirectUrlFactoryWithSpecificBranchTest.spec.ts +2 -5
- package/tests/e2e_happy_path/DevWorkspaceHappyPath.spec.ts +2 -2
- package/tests/e2e_happy_path/HappyPath.spec.ts +13 -10
- package/tests/intelij/IntelijOpenWorkspace.spec.ts +2 -4
- package/tests/load_test/LoadTest.spec.ts +2 -2
- package/tests/login/LinkCheAndOcpUsers.spec.ts +4 -3
- package/tests/plugins/GitHubPullRequestPlugin.spec.ts +4 -7
- package/tests/plugins/InstallPluginUsingUI.spec.ts +4 -9
- package/tests/plugins/JavaPlugin.spec.ts +4 -6
- package/tests/plugins/PhpPlugin.spec.ts +3 -9
- package/tests/plugins/PythonPlugin.spec.ts +4 -6
- package/tests/plugins/TypescriptPlugin.spec.ts +4 -6
- package/tests/plugins/VscodeKubernetesPlugin.spec.ts +3 -9
- package/tests/plugins/VscodeShellcheckPlugin.spec.ts +3 -9
- package/tests/plugins/VscodeValePlugin.spec.ts +3 -9
- package/tests/plugins/VscodeXmlPlugin.spec.ts +14 -23
- package/tests/plugins/VscodeYamlPlugin.spec.ts +4 -7
- package/testsLibrary/CodeExecutionTests.ts +43 -22
- package/testsLibrary/WorkspaceHandlingTests.ts +66 -9
|
@@ -8,68 +8,69 @@
|
|
|
8
8
|
* SPDX-License-Identifier: EPL-2.0
|
|
9
9
|
**********************************************************************/
|
|
10
10
|
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
11
|
+
import { e2eContainer } from '../../inversify.config';
|
|
12
|
+
import { CLASSES, TYPES } from '../../inversify.types';
|
|
13
|
+
import { GitPlugin } from '../../pageobjects/ide/plugins/GitPlugin';
|
|
14
|
+
import { Ide } from '../../pageobjects/ide/Ide';
|
|
15
|
+
import { ProjectTree } from '../../pageobjects/ide/ProjectTree';
|
|
16
|
+
import { QuickOpenContainer } from '../../pageobjects/ide/QuickOpenContainer';
|
|
17
|
+
import { ICheLoginPage } from '../../pageobjects/login/ICheLoginPage';
|
|
18
|
+
import { TestConstants } from '../../TestConstants';
|
|
19
|
+
import { DriverHelper } from '../../utils/DriverHelper';
|
|
20
|
+
import { TestWorkspaceUtil } from '../../utils/workspace/TestWorkspaceUtil';
|
|
21
|
+
import { TopMenu } from '../../pageobjects/ide/TopMenu';
|
|
22
|
+
import { TimeoutConstants } from '../../TimeoutConstants';
|
|
23
|
+
import { Dashboard } from '../../pageobjects/dashboard/Dashboard';
|
|
24
|
+
import { BrowserTabsUtil } from '../../utils/BrowserTabsUtil';
|
|
25
|
+
import { WorkspaceHandlingTests } from '../../testsLibrary/WorkspaceHandlingTests';
|
|
26
|
+
import { Editor } from '../../pageobjects/ide/Editor';
|
|
27
27
|
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
28
|
+
const workspaceHandlingTests: WorkspaceHandlingTests = e2eContainer.get(CLASSES.WorkspaceHandlingTests);
|
|
29
|
+
const ide: Ide = e2eContainer.get(CLASSES.Ide);
|
|
30
|
+
const driverHelper: DriverHelper = e2eContainer.get(CLASSES.DriverHelper);
|
|
31
|
+
const quickOpenContainer: QuickOpenContainer = e2eContainer.get(CLASSES.QuickOpenContainer);
|
|
32
|
+
const topMenu: TopMenu = e2eContainer.get(CLASSES.TopMenu);
|
|
33
|
+
const loginPage: ICheLoginPage = e2eContainer.get<ICheLoginPage>(TYPES.CheLogin);
|
|
34
|
+
const projectTree: ProjectTree = e2eContainer.get(CLASSES.ProjectTree);
|
|
35
|
+
const gitPlugin: GitPlugin = e2eContainer.get(CLASSES.GitPlugin);
|
|
36
|
+
const testWorkspaceUtils: TestWorkspaceUtil = e2eContainer.get<TestWorkspaceUtil>(TYPES.WorkspaceUtil);
|
|
37
|
+
const dashboard: Dashboard = e2eContainer.get(CLASSES.Dashboard);
|
|
38
|
+
const browserTabsUtil: BrowserTabsUtil = e2eContainer.get(CLASSES.BrowserTabsUtil);
|
|
39
|
+
const editor: Editor = e2eContainer.get(CLASSES.Editor);
|
|
40
40
|
|
|
41
|
-
|
|
41
|
+
const workspaceName = 'gitSelfSignCert';
|
|
42
42
|
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
43
|
+
suite('Checking git + self sign cert', async () => {
|
|
44
|
+
const workspacePrefixUrl: string = `${TestConstants.TS_SELENIUM_BASE_URL}/dashboard/#/ide/${TestConstants.TS_SELENIUM_USERNAME}/`;
|
|
45
|
+
const gitProjectUrl = `https://${TestConstants.TS_SELF_HOSTED_GIT_SERVER_URL}/maxura/gitService.git`;
|
|
46
|
+
const committedFile = 'README.md';
|
|
47
47
|
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
48
|
+
suiteSetup(async function () {
|
|
49
|
+
const wsConfig = await testWorkspaceUtils.getBaseDevfile();
|
|
50
|
+
wsConfig.metadata!.name = workspaceName;
|
|
51
|
+
WorkspaceHandlingTests.setWorkspaceName(workspaceName);
|
|
52
|
+
await browserTabsUtil.navigateTo(TestConstants.TS_SELENIUM_BASE_URL);
|
|
53
|
+
await loginPage.login();
|
|
54
|
+
await testWorkspaceUtils.createWsFromDevFile(wsConfig);
|
|
55
|
+
});
|
|
55
56
|
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
57
|
+
test('Wait until created workspace is started', async () => {
|
|
58
|
+
await dashboard.waitPage();
|
|
59
|
+
await browserTabsUtil.navigateTo(workspacePrefixUrl + workspaceName);
|
|
60
|
+
await ide.waitWorkspaceAndIde();
|
|
61
|
+
await projectTree.openProjectTreeContainer();
|
|
62
|
+
await driverHelper.wait(TimeoutConstants.TS_SELENIUM_LOAD_PAGE_TIMEOUT);
|
|
63
|
+
});
|
|
63
64
|
|
|
64
65
|
|
|
65
|
-
|
|
66
|
-
|
|
66
|
+
test('Clone project', async () => {
|
|
67
|
+
await cloneTestRepo(gitProjectUrl);
|
|
67
68
|
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
69
|
+
await projectTree.waitProjectImportedNoSubfolder('gitService');
|
|
70
|
+
await projectTree.waitItem('gitService/README.md');
|
|
71
|
+
});
|
|
71
72
|
|
|
72
|
-
|
|
73
|
+
test('Change commit and push', async function changeCommitAndPushFunc() {
|
|
73
74
|
const currentDate: string = Date.now().toString();
|
|
74
75
|
await projectTree.expandPathAndOpenFile('gitService', committedFile);
|
|
75
76
|
await editor.type(committedFile, currentDate + '\n', 1);
|
|
@@ -85,23 +86,23 @@
|
|
|
85
86
|
await gitPlugin.waitDataIsSynchronized();
|
|
86
87
|
});
|
|
87
88
|
|
|
88
|
-
|
|
89
|
+
});
|
|
89
90
|
|
|
90
|
-
|
|
91
|
+
suite('Stopping and deleting the workspace', async () => {
|
|
91
92
|
test(`Stop and remove workspace`, async () => {
|
|
92
93
|
await workspaceHandlingTests.stopAndRemoveWorkspace(workspaceName);
|
|
93
94
|
});
|
|
94
95
|
});
|
|
95
96
|
|
|
96
|
-
|
|
97
|
-
|
|
97
|
+
async function cloneTestRepo(linkToRepo: string) {
|
|
98
|
+
const confirmMessage = 'Clone from URL';
|
|
98
99
|
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
100
|
+
await topMenu.selectOption('View', 'Find Command...');
|
|
101
|
+
// workaround - reopen 'Find Command' container - https://github.com/eclipse/che/issues/19793
|
|
102
|
+
await topMenu.selectOption('View', 'Find Command...');
|
|
103
|
+
await quickOpenContainer.typeAndSelectSuggestion('clone', 'Git: Clone');
|
|
104
|
+
await quickOpenContainer.typeAndSelectSuggestion(linkToRepo, confirmMessage);
|
|
105
|
+
await gitPlugin.clickOnSelectRepositoryButton();
|
|
105
106
|
|
|
106
|
-
|
|
107
|
-
|
|
107
|
+
await ide.waitAndApplyTrustNotification();
|
|
108
|
+
}
|
package/tests/e2e/GitSsh.spec.ts
CHANGED
|
@@ -27,7 +27,7 @@ import { TopMenu } from '../../pageobjects/ide/TopMenu';
|
|
|
27
27
|
import { TimeoutConstants } from '../../TimeoutConstants';
|
|
28
28
|
import { BrowserTabsUtil } from '../../utils/BrowserTabsUtil';
|
|
29
29
|
import { Dashboard } from '../..';
|
|
30
|
-
import
|
|
30
|
+
import { WorkspaceHandlingTests } from '../../testsLibrary/WorkspaceHandlingTests';
|
|
31
31
|
|
|
32
32
|
const driverHelper: DriverHelper = e2eContainer.get(CLASSES.DriverHelper);
|
|
33
33
|
const ide: Ide = e2eContainer.get(CLASSES.Ide);
|
|
@@ -61,7 +61,7 @@ suite('Git with ssh workflow', async () => {
|
|
|
61
61
|
test('Login into workspace and open tree container', async () => {
|
|
62
62
|
await dashboard.openDashboard();
|
|
63
63
|
await browserTabsUtil.navigateTo(workspacePrefixUrl + wsNameCheckGeneratingKeys);
|
|
64
|
-
|
|
64
|
+
WorkspaceHandlingTests.setWorkspaceName(wsNameCheckGeneratingKeys);
|
|
65
65
|
await ide.waitWorkspaceAndIde();
|
|
66
66
|
await projectTree.openProjectTreeContainer();
|
|
67
67
|
await driverHelper.wait(TimeoutConstants.TS_PROJECT_TREE_TIMEOUT);
|
|
@@ -111,7 +111,7 @@ suite('Git with ssh workflow', async () => {
|
|
|
111
111
|
await testWorkspaceUtils.createWsFromDevFile(data);
|
|
112
112
|
await dashboard.openDashboard();
|
|
113
113
|
await browserTabsUtil.navigateTo(workspacePrefixUrl + wsNameCheckPropagatingKeys);
|
|
114
|
-
|
|
114
|
+
WorkspaceHandlingTests.setWorkspaceName(wsNameCheckPropagatingKeys);
|
|
115
115
|
await ide.waitWorkspaceAndIde();
|
|
116
116
|
await projectTree.openProjectTreeContainer();
|
|
117
117
|
await driverHelper.wait(TimeoutConstants.TS_PROJECT_TREE_TIMEOUT);
|
|
@@ -26,7 +26,7 @@ import { PreferencesHandler, TerminalRendererType } from '../../utils/Preference
|
|
|
26
26
|
import { TestWorkspaceUtil } from '../../utils/workspace/TestWorkspaceUtil';
|
|
27
27
|
import { TimeoutConstants } from '../../TimeoutConstants';
|
|
28
28
|
import { BrowserTabsUtil } from '../../utils/BrowserTabsUtil';
|
|
29
|
-
import
|
|
29
|
+
import { WorkspaceHandlingTests } from '../../testsLibrary/WorkspaceHandlingTests';
|
|
30
30
|
|
|
31
31
|
const driverHelper: DriverHelper = e2eContainer.get(CLASSES.DriverHelper);
|
|
32
32
|
const ide: Ide = e2eContainer.get(CLASSES.Ide);
|
|
@@ -77,7 +77,7 @@ suite('Openshift connector user story', async () => {
|
|
|
77
77
|
test('Login into workspace and open plugin', async () => {
|
|
78
78
|
await dashboard.openDashboard();
|
|
79
79
|
await browserTabsUtil.navigateTo(workspacePrefixUrl + wsName);
|
|
80
|
-
|
|
80
|
+
WorkspaceHandlingTests.setWorkspaceName(wsName);
|
|
81
81
|
await ide.waitWorkspaceAndIde();
|
|
82
82
|
await projectTree.openProjectTreeContainer();
|
|
83
83
|
await projectTree.waitProjectImported(projectName, 'index.js');
|
|
@@ -12,7 +12,6 @@ import { e2eContainer } from '../../../inversify.config';
|
|
|
12
12
|
import { CLASSES } from '../../../inversify.types';
|
|
13
13
|
import { TestConstants } from '../../../TestConstants';
|
|
14
14
|
import { ProjectAndFileTests } from '../../../testsLibrary/ProjectAndFileTests';
|
|
15
|
-
import CheReporter from '../../../driver/CheReporter';
|
|
16
15
|
import { BrowserTabsUtil } from '../../../utils/BrowserTabsUtil';
|
|
17
16
|
import { WorkspaceHandlingTests } from '../../../testsLibrary/WorkspaceHandlingTests';
|
|
18
17
|
import { PreferencesHandler } from '../../../utils/PreferencesHandler';
|
|
@@ -28,7 +27,6 @@ const workspaceRootFolderName: string = 'src';
|
|
|
28
27
|
const fileName: string = 'pom.xml';
|
|
29
28
|
const fileFolderPath: string = `${workspaceSampleName}/${workspaceRootFolderName}/main/java/org/eclipse/che/examples`;
|
|
30
29
|
const tabTitle: string = 'HelloWorld.java';
|
|
31
|
-
let workspaceName: string = 'console-java-simple';
|
|
32
30
|
|
|
33
31
|
suite('Workspace creation via factory url', async () => {
|
|
34
32
|
suite('Open factory URL', async () => {
|
|
@@ -38,11 +36,10 @@ suite('Workspace creation via factory url', async () => {
|
|
|
38
36
|
});
|
|
39
37
|
|
|
40
38
|
suite('Wait workspace readyness', async () => {
|
|
39
|
+
workspaceHandlingTests.obtainWorkspaceNameFromStartingPage();
|
|
41
40
|
projectAndFileTests.waitWorkspaceReadiness(workspaceSampleName, workspaceRootFolderName);
|
|
42
41
|
|
|
43
42
|
test('Set confirmExit preference to never', async () => {
|
|
44
|
-
CheReporter.registerRunningWorkspace(workspaceName);
|
|
45
|
-
|
|
46
43
|
await preferencesHandler.setPreferenceUsingUI('application.confirmExit', 'never');
|
|
47
44
|
});
|
|
48
45
|
});
|
|
@@ -56,7 +53,7 @@ suite('Workspace creation via factory url', async () => {
|
|
|
56
53
|
|
|
57
54
|
suite ('Stopping and deleting the workspace', async () => {
|
|
58
55
|
test('Stop and remove workspace', async () => {
|
|
59
|
-
await workspaceHandlingTests.stopAndRemoveWorkspace(
|
|
56
|
+
await workspaceHandlingTests.stopAndRemoveWorkspace(WorkspaceHandlingTests.getWorkspaceName());
|
|
60
57
|
});
|
|
61
58
|
});
|
|
62
59
|
|
|
@@ -12,7 +12,6 @@ import { e2eContainer } from '../../../inversify.config';
|
|
|
12
12
|
import { CLASSES } from '../../../inversify.types';
|
|
13
13
|
import { TestConstants } from '../../../TestConstants';
|
|
14
14
|
import { ProjectAndFileTests } from '../../../testsLibrary/ProjectAndFileTests';
|
|
15
|
-
import CheReporter from '../../../driver/CheReporter';
|
|
16
15
|
import { BrowserTabsUtil } from '../../../utils/BrowserTabsUtil';
|
|
17
16
|
import { WorkspaceHandlingTests } from '../../../testsLibrary/WorkspaceHandlingTests';
|
|
18
17
|
import { PreferencesHandler } from '../../../utils/PreferencesHandler';
|
|
@@ -27,7 +26,6 @@ const workspaceSampleName: string = 'console-java-simple';
|
|
|
27
26
|
const workspaceRootFolderName: string = 'src';
|
|
28
27
|
const fileFolderPath: string = `${workspaceSampleName}/${workspaceRootFolderName}/main/java/org/eclipse/che/examples`;
|
|
29
28
|
const tabTitle: string = 'HelloWorld.java';
|
|
30
|
-
let workspaceName: string = 'console-java-simple';
|
|
31
29
|
|
|
32
30
|
suite('Workspace creation via factory url', async () => {
|
|
33
31
|
suite('Open factory URL', async () => {
|
|
@@ -37,11 +35,10 @@ suite('Workspace creation via factory url', async () => {
|
|
|
37
35
|
});
|
|
38
36
|
|
|
39
37
|
suite('Wait workspace readyness', async () => {
|
|
38
|
+
workspaceHandlingTests.obtainWorkspaceNameFromStartingPage();
|
|
40
39
|
projectAndFileTests.waitWorkspaceReadiness(workspaceSampleName, workspaceRootFolderName);
|
|
41
40
|
|
|
42
41
|
test('Set confirmExit preference to never', async () => {
|
|
43
|
-
CheReporter.registerRunningWorkspace(workspaceName);
|
|
44
|
-
|
|
45
42
|
await preferencesHandler.setPreferenceUsingUI('application.confirmExit', 'never');
|
|
46
43
|
});
|
|
47
44
|
});
|
|
@@ -53,7 +50,7 @@ suite('Workspace creation via factory url', async () => {
|
|
|
53
50
|
|
|
54
51
|
suite ('Stopping and deleting the workspace', async () => {
|
|
55
52
|
test('Stop and remove workspace', async () => {
|
|
56
|
-
await workspaceHandlingTests.stopAndRemoveWorkspace(
|
|
53
|
+
await workspaceHandlingTests.stopAndRemoveWorkspace(WorkspaceHandlingTests.getWorkspaceName());
|
|
57
54
|
});
|
|
58
55
|
});
|
|
59
56
|
|
|
@@ -12,7 +12,6 @@ import { e2eContainer } from '../../../inversify.config';
|
|
|
12
12
|
import { CLASSES } from '../../../inversify.types';
|
|
13
13
|
import { TestConstants } from '../../../TestConstants';
|
|
14
14
|
import { ProjectAndFileTests } from '../../../testsLibrary/ProjectAndFileTests';
|
|
15
|
-
import CheReporter from '../../../driver/CheReporter';
|
|
16
15
|
import { BrowserTabsUtil } from '../../../utils/BrowserTabsUtil';
|
|
17
16
|
import { WorkspaceHandlingTests } from '../../../testsLibrary/WorkspaceHandlingTests';
|
|
18
17
|
import { PreferencesHandler } from '../../../utils/PreferencesHandler';
|
|
@@ -27,7 +26,6 @@ const workspaceSampleName: string = 'console-java-simple';
|
|
|
27
26
|
const workspaceRootFolderName: string = 'src';
|
|
28
27
|
const fileFolderPath: string = `${workspaceSampleName}/${workspaceRootFolderName}/main/java/org/eclipse/che/examples`;
|
|
29
28
|
const tabTitle: string = 'HelloWorld.java';
|
|
30
|
-
let workspaceName: string = 'console-java-simple';
|
|
31
29
|
|
|
32
30
|
suite('Workspace creation via factory url', async () => {
|
|
33
31
|
suite('Open factory URL', async () => {
|
|
@@ -37,11 +35,10 @@ suite('Workspace creation via factory url', async () => {
|
|
|
37
35
|
});
|
|
38
36
|
|
|
39
37
|
suite('Wait workspace readyness', async () => {
|
|
38
|
+
workspaceHandlingTests.obtainWorkspaceNameFromStartingPage();
|
|
40
39
|
projectAndFileTests.waitWorkspaceReadiness(workspaceSampleName, workspaceRootFolderName);
|
|
41
40
|
|
|
42
41
|
test('Set confirmExit preference to never', async () => {
|
|
43
|
-
CheReporter.registerRunningWorkspace(workspaceName);
|
|
44
|
-
|
|
45
42
|
await preferencesHandler.setPreferenceUsingUI('application.confirmExit', 'never');
|
|
46
43
|
});
|
|
47
44
|
});
|
|
@@ -53,7 +50,7 @@ suite('Workspace creation via factory url', async () => {
|
|
|
53
50
|
|
|
54
51
|
suite ('Stopping and deleting the workspace', async () => {
|
|
55
52
|
test('Stop and remove workspace', async () => {
|
|
56
|
-
await workspaceHandlingTests.stopAndRemoveWorkspace(
|
|
53
|
+
await workspaceHandlingTests.stopAndRemoveWorkspace(WorkspaceHandlingTests.getWorkspaceName());
|
|
57
54
|
});
|
|
58
55
|
});
|
|
59
56
|
|
|
@@ -24,7 +24,7 @@ import { TimeoutConstants } from '../../TimeoutConstants';
|
|
|
24
24
|
import { TopMenu } from '../../pageobjects/ide/TopMenu';
|
|
25
25
|
import * as fs from 'fs';
|
|
26
26
|
import axios from 'axios';
|
|
27
|
-
import
|
|
27
|
+
import { WorkspaceHandlingTests } from '../../testsLibrary/WorkspaceHandlingTests';
|
|
28
28
|
|
|
29
29
|
const ide: Ide = e2eContainer.get(CLASSES.Ide);
|
|
30
30
|
const projectTree: ProjectTree = e2eContainer.get(CLASSES.ProjectTree);
|
|
@@ -65,7 +65,7 @@ suite('Workspace creation via factory url', async () => {
|
|
|
65
65
|
});
|
|
66
66
|
|
|
67
67
|
test('Register running workspace', async () => {
|
|
68
|
-
|
|
68
|
+
WorkspaceHandlingTests.setWorkspaceName(projectName);
|
|
69
69
|
});
|
|
70
70
|
|
|
71
71
|
test('Register running workspace', async () => {
|
|
@@ -28,7 +28,7 @@ import { TimeoutConstants } from '../../TimeoutConstants';
|
|
|
28
28
|
import { Logger } from '../../utils/Logger';
|
|
29
29
|
import { RightToolBar } from '../../pageobjects/ide/RightToolBar';
|
|
30
30
|
import { BrowserTabsUtil } from '../../utils/BrowserTabsUtil';
|
|
31
|
-
import
|
|
31
|
+
import { WorkspaceHandlingTests } from '../../testsLibrary/WorkspaceHandlingTests';
|
|
32
32
|
|
|
33
33
|
const driverHelper: DriverHelper = e2eContainer.get(CLASSES.DriverHelper);
|
|
34
34
|
const ide: Ide = e2eContainer.get(CLASSES.Ide);
|
|
@@ -75,11 +75,11 @@ suite('Validation of workspace start', async () => {
|
|
|
75
75
|
});
|
|
76
76
|
|
|
77
77
|
test('Register running workspace', async () => {
|
|
78
|
-
|
|
78
|
+
WorkspaceHandlingTests.setWorkspaceName(workspaceName);
|
|
79
79
|
});
|
|
80
80
|
|
|
81
81
|
test('Wait for workspace readiness', async () => {
|
|
82
|
-
await ide.waitAndSwitchToIdeFrame();
|
|
82
|
+
// await ide.waitAndSwitchToIdeFrame(); test is outdated, should be deprecated.
|
|
83
83
|
await ide.waitIde(TimeoutConstants.TS_SELENIUM_START_WORKSPACE_TIMEOUT);
|
|
84
84
|
await projectTree.openProjectTreeContainer();
|
|
85
85
|
await ide.waitNotificationAndClickOnButton('Do you trust the authors of', 'Yes, I trust', 60_000);
|
|
@@ -126,7 +126,7 @@ suite('Language server validation', async () => {
|
|
|
126
126
|
} catch (err) {
|
|
127
127
|
Logger.debug('Workaround for the https://github.com/eclipse/che/issues/18974.');
|
|
128
128
|
await browserTabsUtil.refreshPage();
|
|
129
|
-
await ide.waitAndSwitchToIdeFrame();
|
|
129
|
+
// await ide.waitAndSwitchToIdeFrame(); test is outdated, should be deprecated.
|
|
130
130
|
await ide.waitIde();
|
|
131
131
|
await editor.waitErrorInLine(30, javaFileName, TimeoutConstants.TS_ERROR_HIGHLIGHTING_TIMEOUT * 2);
|
|
132
132
|
}
|
|
@@ -240,10 +240,11 @@ suite('Validation of debug functionality', async () => {
|
|
|
240
240
|
});
|
|
241
241
|
|
|
242
242
|
test('Check content of the launched application', async () => {
|
|
243
|
-
await previewWidget.waitAndSwitchToWidgetFrame();
|
|
243
|
+
await previewWidget.waitAndSwitchToWidgetFrame(); // test is outdated, should be deprecated.
|
|
244
244
|
await previewWidget.waitAndClick(SpringAppLocators.springHomeButtonLocator);
|
|
245
245
|
await driverHelper.getDriver().switchTo().defaultContent();
|
|
246
|
-
await ide.waitAndSwitchToIdeFrame();
|
|
246
|
+
// await ide.waitAndSwitchToIdeFrame(); test is outdated, should be deprecated.
|
|
247
|
+
await ide.waitIde();
|
|
247
248
|
});
|
|
248
249
|
|
|
249
250
|
test('Open debug view', async () => {
|
|
@@ -280,7 +281,7 @@ suite('Validation of debug functionality', async () => {
|
|
|
280
281
|
});
|
|
281
282
|
|
|
282
283
|
async function checkErrorMessageInApplicationController() {
|
|
283
|
-
await previewWidget.waitAndSwitchToWidgetFrame();
|
|
284
|
+
await previewWidget.waitAndSwitchToWidgetFrame(); // test is outdated, should be deprecated.
|
|
284
285
|
await previewWidget.waitAndClick(SpringAppLocators.springMenuButtonLocator);
|
|
285
286
|
await previewWidget.waitAndClick(SpringAppLocators.springErrorButtonLocator);
|
|
286
287
|
|
|
@@ -289,15 +290,17 @@ async function checkErrorMessageInApplicationController() {
|
|
|
289
290
|
} catch (err) {
|
|
290
291
|
|
|
291
292
|
await driverHelper.getDriver().switchTo().defaultContent();
|
|
292
|
-
await ide.waitAndSwitchToIdeFrame();
|
|
293
|
+
// await ide.waitAndSwitchToIdeFrame(); test is outdated, should be deprecated.
|
|
294
|
+
await ide.waitIde();
|
|
293
295
|
|
|
294
|
-
await previewWidget.waitAndSwitchToWidgetFrame();
|
|
296
|
+
await previewWidget.waitAndSwitchToWidgetFrame(); // test is outdated, should be deprecated.
|
|
295
297
|
await previewWidget.waitVisibility(SpringAppLocators.springErrorMessageLocator, 15_000);
|
|
296
298
|
}
|
|
297
299
|
|
|
298
300
|
|
|
299
301
|
await driverHelper.getDriver().switchTo().defaultContent();
|
|
300
|
-
await ide.waitAndSwitchToIdeFrame();
|
|
302
|
+
// await ide.waitAndSwitchToIdeFrame(); test is outdated, should be deprecated.
|
|
303
|
+
await ide.waitIde();
|
|
301
304
|
}
|
|
302
305
|
|
|
303
306
|
async function checkJavaPathCompletion() {
|
|
@@ -14,8 +14,6 @@ import { CLASSES } from '../../inversify.types';
|
|
|
14
14
|
import { Ide } from '../../pageobjects/ide/Ide';
|
|
15
15
|
import { DriverHelper } from '../../utils/DriverHelper';
|
|
16
16
|
import { TestConstants } from '../../TestConstants';
|
|
17
|
-
import { WorkspaceNameHandler } from '../../utils/WorkspaceNameHandler';
|
|
18
|
-
import CheReporter from '../../driver/CheReporter';
|
|
19
17
|
import { Dashboard } from '../../pageobjects/dashboard/Dashboard';
|
|
20
18
|
import { BrowserTabsUtil } from '../../utils/BrowserTabsUtil';
|
|
21
19
|
|
|
@@ -23,7 +21,6 @@ const ide: Ide = e2eContainer.get(CLASSES.Ide);
|
|
|
23
21
|
const driverHelper: DriverHelper = e2eContainer.get(CLASSES.DriverHelper);
|
|
24
22
|
const browserTabsUtil: BrowserTabsUtil = e2eContainer.get(CLASSES.BrowserTabsUtil);
|
|
25
23
|
const dashboard: Dashboard = e2eContainer.get(CLASSES.Dashboard);
|
|
26
|
-
const workspaceNameHandler: WorkspaceNameHandler = e2eContainer.get(CLASSES.WorkspaceNameHandler);
|
|
27
24
|
|
|
28
25
|
const dashboardUrl: string = `${TestConstants.TS_SELENIUM_BASE_URL}`;
|
|
29
26
|
|
|
@@ -35,7 +32,8 @@ suite('The "IntelijOpenWorkspace" userstory', async () => {
|
|
|
35
32
|
|
|
36
33
|
test('Wait workspace', async () => {
|
|
37
34
|
await dashboard.waitWorkspaceStartingPage();
|
|
38
|
-
|
|
35
|
+
// todo: Fix workspace register in IntelliJ devfile - https://issues.redhat.com/browse/CRW-2954
|
|
36
|
+
/* CheReporter.registerRunningWorkspace(await workspaceNameHandler.getNameFromUrl()); */
|
|
39
37
|
await ide.waitAndSwitchToIdeFrame();
|
|
40
38
|
await waitIntelijWorkspace();
|
|
41
39
|
});
|
|
@@ -15,8 +15,8 @@ import { ProjectTree } from '../../pageobjects/ide/ProjectTree';
|
|
|
15
15
|
import { ICheLoginPage } from '../../pageobjects/login/ICheLoginPage';
|
|
16
16
|
import { TestWorkspaceUtil } from '../../utils/workspace/TestWorkspaceUtil';
|
|
17
17
|
import { TestConstants, WorkspaceNameHandler } from '../..';
|
|
18
|
-
import CheReporter from '../../driver/CheReporter';
|
|
19
18
|
import { BrowserTabsUtil } from '../../utils/BrowserTabsUtil';
|
|
19
|
+
import { WorkspaceHandlingTests } from '../../testsLibrary/WorkspaceHandlingTests';
|
|
20
20
|
|
|
21
21
|
const browserTabsUtil: BrowserTabsUtil = e2eContainer.get(CLASSES.BrowserTabsUtil);
|
|
22
22
|
const ide: Ide = e2eContainer.get(CLASSES.Ide);
|
|
@@ -44,7 +44,7 @@ suite('Load test suite', async () => {
|
|
|
44
44
|
});
|
|
45
45
|
|
|
46
46
|
test('Wait loading workspace and get time', async () => {
|
|
47
|
-
|
|
47
|
+
WorkspaceHandlingTests.setWorkspaceName(workspaceName);
|
|
48
48
|
await ide.waitWorkspaceAndIde();
|
|
49
49
|
await projectTree.openProjectTreeContainer();
|
|
50
50
|
});
|
|
@@ -8,14 +8,15 @@
|
|
|
8
8
|
* SPDX-License-Identifier: EPL-2.0
|
|
9
9
|
**********************************************************************/
|
|
10
10
|
|
|
11
|
-
import { TestConstants,
|
|
11
|
+
import { TestConstants, CLASSES, TYPES } from '../..';
|
|
12
12
|
import { e2eContainer } from '../../inversify.config';
|
|
13
13
|
import { IOcpLoginPage } from '../../pageobjects/login/IOcpLoginPage';
|
|
14
14
|
import { UpdateAccountInformationPage } from '../../pageobjects/login/UpdateAccountInformationPage';
|
|
15
15
|
import { TimeoutConstants } from '../../TimeoutConstants';
|
|
16
16
|
import { Dashboard } from '../../pageobjects/dashboard/Dashboard';
|
|
17
|
+
import { BrowserTabsUtil } from '../../utils/BrowserTabsUtil';
|
|
17
18
|
|
|
18
|
-
const
|
|
19
|
+
const browserTabsUtil: BrowserTabsUtil = e2eContainer.get(CLASSES.BrowserTabsUtil);
|
|
19
20
|
const ocpLogin: IOcpLoginPage = e2eContainer.get<IOcpLoginPage>(TYPES.OcpLogin);
|
|
20
21
|
const updateAccountInformation: UpdateAccountInformationPage = e2eContainer.get(CLASSES.UpdateAccountInformationPage);
|
|
21
22
|
const dashboard: Dashboard = e2eContainer.get(CLASSES.Dashboard);
|
|
@@ -24,7 +25,7 @@ const commonTimeout: number = TimeoutConstants.TS_SELENIUM_LOAD_PAGE_TIMEOUT * 2
|
|
|
24
25
|
|
|
25
26
|
suite('Link users', async () => {
|
|
26
27
|
test('Login to OCP', async () => {
|
|
27
|
-
await
|
|
28
|
+
await browserTabsUtil.navigateTo(TestConstants.TS_SELENIUM_BASE_URL);
|
|
28
29
|
|
|
29
30
|
await ocpLogin.login();
|
|
30
31
|
await updateAccountInformation.clickToAllowSelectedPermissionsButton(commonTimeout);
|
|
@@ -24,7 +24,6 @@ import { GitPlugin } from '../../pageobjects/ide/plugins/GitPlugin';
|
|
|
24
24
|
import { TopMenu } from '../../pageobjects/ide/TopMenu';
|
|
25
25
|
import { QuickOpenContainer } from '../../pageobjects/ide/QuickOpenContainer';
|
|
26
26
|
import { Editor } from '../../pageobjects/ide/Editor';
|
|
27
|
-
import CheReporter from '../../driver/CheReporter';
|
|
28
27
|
import { BrowserTabsUtil } from '../../utils/BrowserTabsUtil';
|
|
29
28
|
import { Key } from 'selenium-webdriver';
|
|
30
29
|
|
|
@@ -40,6 +39,7 @@ const topMenu: TopMenu = e2eContainer.get(CLASSES.TopMenu);
|
|
|
40
39
|
const quickOpenContainer: QuickOpenContainer = e2eContainer.get(CLASSES.QuickOpenContainer);
|
|
41
40
|
const editor: Editor = e2eContainer.get(CLASSES.Editor);
|
|
42
41
|
const workspaceNameHandler: WorkspaceNameHandler = e2eContainer.get(CLASSES.WorkspaceNameHandler);
|
|
42
|
+
const workspaceHandlingTests: WorkspaceHandlingTests = e2eContainer.get(CLASSES.WorkspaceHandlingTests);
|
|
43
43
|
|
|
44
44
|
const devfileUrl: string = `https://raw.githubusercontent.com/eclipse/che/main/tests/e2e/files/devfiles/plugins/GitHubPullRequestPlugin.yaml`;
|
|
45
45
|
const factoryUrl: string = `${TestConstants.TS_SELENIUM_BASE_URL}/f?url=${devfileUrl}`;
|
|
@@ -50,7 +50,6 @@ const changedFile: string = 'README.md';
|
|
|
50
50
|
// added call back url, but needs to be re-verified
|
|
51
51
|
const identityCallbackUrl: string = `${TestConstants.TS_SELENIUM_BASE_URL}/api/oauth/callback`;
|
|
52
52
|
const currentDate: string = Date.now().toString();
|
|
53
|
-
let workspaceName: string;
|
|
54
53
|
|
|
55
54
|
suite(`The 'GitHubPullRequestPlugin' test`, async () => {
|
|
56
55
|
suite('Setup github', async () => {
|
|
@@ -77,11 +76,9 @@ suite(`The 'GitHubPullRequestPlugin' test`, async () => {
|
|
|
77
76
|
await browserTabsUtil.navigateTo(factoryUrl);
|
|
78
77
|
});
|
|
79
78
|
|
|
80
|
-
|
|
81
|
-
await ide.waitAndSwitchToIdeFrame();
|
|
82
|
-
workspaceName = await workspaceNameHandler.getNameFromUrl();
|
|
83
|
-
CheReporter.registerRunningWorkspace(workspaceName);
|
|
79
|
+
workspaceHandlingTests.obtainWorkspaceNameFromStartingPage();
|
|
84
80
|
|
|
81
|
+
test('Wait until created workspace is started', async () => {
|
|
85
82
|
await ide.waitIde(TimeoutConstants.TS_SELENIUM_START_WORKSPACE_TIMEOUT);
|
|
86
83
|
await ide.waitNotificationAndClickOnButton('Do you trust the authors of', 'Yes, I trust', 60_000);
|
|
87
84
|
|
|
@@ -140,7 +137,7 @@ suite(`The 'GitHubPullRequestPlugin' test`, async () => {
|
|
|
140
137
|
suite('Stopping and deleting the workspace', async () => {
|
|
141
138
|
test(`Stop and remove workspace`, async () => {
|
|
142
139
|
if (TestConstants.TS_DELETE_PLUGINS_TEST_WORKSPACE === 'true') {
|
|
143
|
-
await workspaceHandling.stopAndRemoveWorkspace(
|
|
140
|
+
await workspaceHandling.stopAndRemoveWorkspace(WorkspaceHandlingTests.getWorkspaceName());
|
|
144
141
|
return;
|
|
145
142
|
}
|
|
146
143
|
|
|
@@ -18,8 +18,6 @@ import { BrowserTabsUtil } from '../../utils/BrowserTabsUtil';
|
|
|
18
18
|
import { PluginsView } from '../../pageobjects/ide/plugins/PluginsView';
|
|
19
19
|
import { WorkspaceHandlingTests } from '../../testsLibrary/WorkspaceHandlingTests';
|
|
20
20
|
import { Logger } from '../../utils/Logger';
|
|
21
|
-
import { WorkspaceNameHandler } from '../../utils/WorkspaceNameHandler';
|
|
22
|
-
import CheReporter from '../../driver/CheReporter';
|
|
23
21
|
|
|
24
22
|
const ide: Ide = e2eContainer.get(CLASSES.Ide);
|
|
25
23
|
const projectTree: ProjectTree = e2eContainer.get(CLASSES.ProjectTree);
|
|
@@ -27,13 +25,12 @@ const pluginsView: PluginsView = e2eContainer.get(CLASSES.PluginsView);
|
|
|
27
25
|
|
|
28
26
|
const browserTabsUtil: BrowserTabsUtil = e2eContainer.get(CLASSES.BrowserTabsUtil);
|
|
29
27
|
const workspaceHandling: WorkspaceHandlingTests = e2eContainer.get(CLASSES.WorkspaceHandlingTests);
|
|
30
|
-
const
|
|
28
|
+
const workspaceHandlingTests: WorkspaceHandlingTests = e2eContainer.get(CLASSES.WorkspaceHandlingTests);
|
|
31
29
|
|
|
32
30
|
const devfileUrl: string = 'https://raw.githubusercontent.com/eclipse/che/main/tests/e2e/files/devfiles/plugins/InstallPluginUsingUI.yaml';
|
|
33
31
|
const factoryUrl: string = `${TestConstants.TS_SELENIUM_BASE_URL}/f?url=${devfileUrl}`;
|
|
34
32
|
|
|
35
33
|
const pluginTitle: string = 'java11';
|
|
36
|
-
let workspaceName: string;
|
|
37
34
|
|
|
38
35
|
suite(`The 'InstallPluginUsingUI' test`, async () => {
|
|
39
36
|
suite('Create workspace', async () => {
|
|
@@ -41,11 +38,9 @@ suite(`The 'InstallPluginUsingUI' test`, async () => {
|
|
|
41
38
|
await browserTabsUtil.navigateTo(factoryUrl);
|
|
42
39
|
});
|
|
43
40
|
|
|
44
|
-
|
|
45
|
-
await ide.waitAndSwitchToIdeFrame();
|
|
46
|
-
workspaceName = await workspaceNameHandler.getNameFromUrl();
|
|
47
|
-
CheReporter.registerRunningWorkspace(workspaceName);
|
|
41
|
+
workspaceHandlingTests.obtainWorkspaceNameFromStartingPage();
|
|
48
42
|
|
|
43
|
+
test('Wait until created workspace is started', async () => {
|
|
49
44
|
await ide.waitIde(TimeoutConstants.TS_SELENIUM_START_WORKSPACE_TIMEOUT);
|
|
50
45
|
|
|
51
46
|
await projectTree.openProjectTreeContainer();
|
|
@@ -72,7 +67,7 @@ suite(`The 'InstallPluginUsingUI' test`, async () => {
|
|
|
72
67
|
suite('Stopping and deleting the workspace', async () => {
|
|
73
68
|
test(`Stop and remove workspace`, async () => {
|
|
74
69
|
if (TestConstants.TS_DELETE_PLUGINS_TEST_WORKSPACE === 'true') {
|
|
75
|
-
await workspaceHandling.stopAndRemoveWorkspace(
|
|
70
|
+
await workspaceHandling.stopAndRemoveWorkspace(WorkspaceHandlingTests.getWorkspaceName());
|
|
76
71
|
return;
|
|
77
72
|
}
|
|
78
73
|
|
|
@@ -18,7 +18,6 @@ import { Editor } from '../../pageobjects/ide/Editor';
|
|
|
18
18
|
import { ProjectAndFileTests } from '../../testsLibrary/ProjectAndFileTests';
|
|
19
19
|
import { WorkspaceHandlingTests } from '../../testsLibrary/WorkspaceHandlingTests';
|
|
20
20
|
import { Logger } from '../../utils/Logger';
|
|
21
|
-
import CheReporter from '../../driver/CheReporter';
|
|
22
21
|
import { BrowserTabsUtil } from '../../utils/BrowserTabsUtil';
|
|
23
22
|
import { PreferencesHandler } from '../../utils/PreferencesHandler';
|
|
24
23
|
|
|
@@ -37,7 +36,6 @@ const subRootFolder: string = 'backend';
|
|
|
37
36
|
|
|
38
37
|
const fileFolderPath: string = `${projectName}/backend/src/main/java/cloudcode/guestbook/backend`;
|
|
39
38
|
const tabTitle: string = 'GuestBookEntry.java';
|
|
40
|
-
let workspaceName: string = 'java-guestbook';
|
|
41
39
|
|
|
42
40
|
suite(`The 'JavaPlugin' test`, async () => {
|
|
43
41
|
suite('Create workspace', async () => {
|
|
@@ -45,11 +43,11 @@ suite(`The 'JavaPlugin' test`, async () => {
|
|
|
45
43
|
await browserTabsUtil.navigateTo(factoryUrl);
|
|
46
44
|
});
|
|
47
45
|
|
|
48
|
-
|
|
46
|
+
workspaceHandlingTests.obtainWorkspaceNameFromStartingPage();
|
|
49
47
|
|
|
50
|
-
|
|
51
|
-
CheReporter.registerRunningWorkspace(workspaceName);
|
|
48
|
+
projectAndFileTests.waitWorkspaceReadiness(projectName, subRootFolder);
|
|
52
49
|
|
|
50
|
+
test('Set confirmExit preference to never', async () => {
|
|
53
51
|
await preferencesHandler.setPreferenceUsingUI('application.confirmExit', 'never');
|
|
54
52
|
});
|
|
55
53
|
});
|
|
@@ -91,7 +89,7 @@ suite(`The 'JavaPlugin' test`, async () => {
|
|
|
91
89
|
suite('Stopping and deleting the workspace', async () => {
|
|
92
90
|
test('Stop and remove workspace', async () => {
|
|
93
91
|
if (TestConstants.TS_DELETE_PLUGINS_TEST_WORKSPACE === 'true') {
|
|
94
|
-
await workspaceHandlingTests.stopAndRemoveWorkspace(
|
|
92
|
+
await workspaceHandlingTests.stopAndRemoveWorkspace(WorkspaceHandlingTests.getWorkspaceName());
|
|
95
93
|
return;
|
|
96
94
|
}
|
|
97
95
|
|