@eclipse-che/che-e2e 7.46.1-dev-5e33fd3 → 7.46.1-dev-8a64d75
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.
|
@@ -13,34 +13,29 @@ const selenium_webdriver_1 = require("selenium-webdriver");
|
|
|
13
13
|
const inversify_config_1 = require("../../inversify.config");
|
|
14
14
|
const inversify_types_1 = require("../../inversify.types");
|
|
15
15
|
const TestConstants_1 = require("../../TestConstants");
|
|
16
|
-
const TimeoutConstants_1 = require("../../TimeoutConstants");
|
|
17
|
-
const WorkspaceHandlingTests_1 = require("../../testsLibrary/WorkspaceHandlingTests");
|
|
18
16
|
const Logger_1 = require("../../utils/Logger");
|
|
19
|
-
const
|
|
17
|
+
const projectAndFileTests = inversify_config_1.e2eContainer.get(inversify_types_1.CLASSES.ProjectAndFileTests);
|
|
20
18
|
const projectTree = inversify_config_1.e2eContainer.get(inversify_types_1.CLASSES.ProjectTree);
|
|
21
19
|
const editor = inversify_config_1.e2eContainer.get(inversify_types_1.CLASSES.Editor);
|
|
22
20
|
const browserTabsUtil = inversify_config_1.e2eContainer.get(inversify_types_1.CLASSES.BrowserTabsUtil);
|
|
23
21
|
const workspaceHandlingTests = inversify_config_1.e2eContainer.get(inversify_types_1.CLASSES.WorkspaceHandlingTests);
|
|
24
|
-
const
|
|
22
|
+
const preferencesHandler = inversify_config_1.e2eContainer.get(inversify_types_1.CLASSES.PreferencesHandler);
|
|
23
|
+
const devfileUrl = 'https://github.com/che-samples/web-nodejs-sample/tree/xml-plugin';
|
|
25
24
|
const factoryUrl = `${TestConstants_1.TestConstants.TS_SELENIUM_BASE_URL}/f?url=${devfileUrl}`;
|
|
26
|
-
const projectName = 'nodejs-
|
|
25
|
+
const projectName = 'web-nodejs-sample';
|
|
27
26
|
const pathToFile = `${projectName}`;
|
|
28
27
|
const xmlFileName = 'hello.xml';
|
|
28
|
+
const subRootFolder = 'app';
|
|
29
|
+
let workspaceName = 'xml-plugin';
|
|
29
30
|
suite('The "VscodeXmlPlugin" userstory', async () => {
|
|
30
31
|
suite('Create workspace', async () => {
|
|
31
32
|
test('Create workspace using factory', async () => {
|
|
32
33
|
await browserTabsUtil.navigateTo(factoryUrl);
|
|
33
34
|
});
|
|
34
35
|
workspaceHandlingTests.obtainWorkspaceNameFromStartingPage();
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
await
|
|
38
|
-
});
|
|
39
|
-
});
|
|
40
|
-
suite('Check workspace readiness to work', async () => {
|
|
41
|
-
test('Wait until project is imported', async () => {
|
|
42
|
-
await projectTree.openProjectTreeContainer();
|
|
43
|
-
await projectTree.waitProjectImported(projectName, 'app');
|
|
36
|
+
projectAndFileTests.waitWorkspaceReadiness(projectName, subRootFolder);
|
|
37
|
+
test('Set confirmExit preference to never', async () => {
|
|
38
|
+
await preferencesHandler.setPreferenceUsingUI('application.confirmExit', 'never');
|
|
44
39
|
});
|
|
45
40
|
});
|
|
46
41
|
suite('Check the "vscode-xml" plugin', async () => {
|
|
@@ -81,7 +76,7 @@ suite('The "VscodeXmlPlugin" userstory', async () => {
|
|
|
81
76
|
suite('Delete workspace', async () => {
|
|
82
77
|
test('Stop and remove workspace', async () => {
|
|
83
78
|
if (TestConstants_1.TestConstants.TS_DELETE_PLUGINS_TEST_WORKSPACE === 'true') {
|
|
84
|
-
await workspaceHandlingTests.stopAndRemoveWorkspace(
|
|
79
|
+
await workspaceHandlingTests.stopAndRemoveWorkspace(workspaceName);
|
|
85
80
|
return;
|
|
86
81
|
}
|
|
87
82
|
Logger_1.Logger.info(`As far as the "TS_DELETE_PLUGINS_TEST_WORKSPACE" value is "false the workspace deletion is skipped"`);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"VscodeXmlPlugin.spec.js","sourceRoot":"","sources":["../../../tests/plugins/VscodeXmlPlugin.spec.ts"],"names":[],"mappings":";AAAA;;;;;;;;wEAQwE;;AAExE,2DAAyC;AACzC,6DAAsD;
|
|
1
|
+
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AK,CAAC,CAAC;QAClF,CAAC,CAAC,CAAC;QAEH,IAAI,CAAC,8BAA8B,EAAE,KAAK,IAAI,EAAE;YAC5C,MAAM,0BAA0B,GAAW,0BAA0B,CAAC;YAEtE,MAAM,MAAM,CAAC,IAAI,CAAC,WAAW,EAAE,wBAAG,CAAC,KAAK,CAAC,wBAAG,CAAC,OAAO,EAAE,wBAAG,CAAC,KAAK,EAAE,GAAG,CAAC,EAAE,EAAE,CAAC,CAAC;YAC3E,MAAM,MAAM,CAAC,QAAQ,CAAC,WAAW,EAAE,0BAA0B,EAAE,KAAK,EAAE,KAAK,CAAC,CAAC;QACjF,CAAC,CAAC,CAAC;IAEP,CAAC,CAAC,CAAC;IAEH,KAAK,CAAC,kBAAkB,EAAE,KAAK,IAAI,EAAE;QACjC,IAAI,CAAC,2BAA2B,EAAE,KAAK,IAAI,EAAE;YACzC,IAAI,6BAAa,CAAC,gCAAgC,KAAK,MAAM,EAAE;gBAC3D,MAAM,sBAAsB,CAAC,sBAAsB,CAAC,aAAa,CAAC,CAAC;gBACnE,OAAO;aACV;YAED,eAAM,CAAC,IAAI,CAAC,qGAAqG,CAAC,CAAC;QACvH,CAAC,CAAC,CAAC;IACP,CAAC,CAAC,CAAC;AACP,CAAC,CAAC,CAAC"}
|
package/package.json
CHANGED
|
@@ -10,27 +10,31 @@
|
|
|
10
10
|
|
|
11
11
|
import { Key } from 'selenium-webdriver';
|
|
12
12
|
import { e2eContainer } from '../../inversify.config';
|
|
13
|
-
import { Ide } from '../../pageobjects/ide/Ide';
|
|
14
13
|
import { CLASSES } from '../../inversify.types';
|
|
15
14
|
import { ProjectTree } from '../../pageobjects/ide/ProjectTree';
|
|
16
15
|
import { Editor } from '../../pageobjects/ide/Editor';
|
|
17
16
|
import { TestConstants } from '../../TestConstants';
|
|
18
|
-
import { TimeoutConstants } from '../../TimeoutConstants';
|
|
19
|
-
import { WorkspaceHandlingTests } from '../../testsLibrary/WorkspaceHandlingTests';
|
|
20
17
|
import { Logger } from '../../utils/Logger';
|
|
18
|
+
import { WorkspaceHandlingTests } from '../../testsLibrary/WorkspaceHandlingTests';
|
|
19
|
+
|
|
21
20
|
import { BrowserTabsUtil } from '../../utils/BrowserTabsUtil';
|
|
21
|
+
import { PreferencesHandler } from '../../utils/PreferencesHandler';
|
|
22
|
+
import { ProjectAndFileTests } from '../../testsLibrary/ProjectAndFileTests';
|
|
22
23
|
|
|
23
|
-
const
|
|
24
|
+
const projectAndFileTests: ProjectAndFileTests = e2eContainer.get(CLASSES.ProjectAndFileTests);
|
|
24
25
|
const projectTree: ProjectTree = e2eContainer.get(CLASSES.ProjectTree);
|
|
25
26
|
const editor: Editor = e2eContainer.get(CLASSES.Editor);
|
|
26
27
|
const browserTabsUtil: BrowserTabsUtil = e2eContainer.get(CLASSES.BrowserTabsUtil);
|
|
27
28
|
const workspaceHandlingTests: WorkspaceHandlingTests = e2eContainer.get(CLASSES.WorkspaceHandlingTests);
|
|
29
|
+
const preferencesHandler: PreferencesHandler = e2eContainer.get(CLASSES.PreferencesHandler);
|
|
28
30
|
|
|
29
|
-
const devfileUrl: string = 'https://
|
|
31
|
+
const devfileUrl: string = 'https://github.com/che-samples/web-nodejs-sample/tree/xml-plugin';
|
|
30
32
|
const factoryUrl: string = `${TestConstants.TS_SELENIUM_BASE_URL}/f?url=${devfileUrl}`;
|
|
31
|
-
const projectName: string = 'nodejs-
|
|
33
|
+
const projectName: string = 'web-nodejs-sample';
|
|
32
34
|
const pathToFile: string = `${projectName}`;
|
|
33
35
|
const xmlFileName: string = 'hello.xml';
|
|
36
|
+
const subRootFolder: string = 'app';
|
|
37
|
+
let workspaceName: string = 'xml-plugin';
|
|
34
38
|
|
|
35
39
|
suite('The "VscodeXmlPlugin" userstory', async () => {
|
|
36
40
|
suite('Create workspace', async () => {
|
|
@@ -40,16 +44,10 @@ suite('The "VscodeXmlPlugin" userstory', async () => {
|
|
|
40
44
|
|
|
41
45
|
workspaceHandlingTests.obtainWorkspaceNameFromStartingPage();
|
|
42
46
|
|
|
43
|
-
|
|
44
|
-
await ide.waitIde(TimeoutConstants.TS_SELENIUM_START_WORKSPACE_TIMEOUT);
|
|
45
|
-
await ide.waitNotificationAndClickOnButton('Do you trust the authors of', 'Yes, I trust', 60_000);
|
|
46
|
-
});
|
|
47
|
-
});
|
|
47
|
+
projectAndFileTests.waitWorkspaceReadiness(projectName, subRootFolder);
|
|
48
48
|
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
await projectTree.openProjectTreeContainer();
|
|
52
|
-
await projectTree.waitProjectImported(projectName, 'app');
|
|
49
|
+
test('Set confirmExit preference to never', async () => {
|
|
50
|
+
await preferencesHandler.setPreferenceUsingUI('application.confirmExit', 'never');
|
|
53
51
|
});
|
|
54
52
|
});
|
|
55
53
|
|
|
@@ -103,12 +101,11 @@ suite('The "VscodeXmlPlugin" userstory', async () => {
|
|
|
103
101
|
suite('Delete workspace', async () => {
|
|
104
102
|
test('Stop and remove workspace', async () => {
|
|
105
103
|
if (TestConstants.TS_DELETE_PLUGINS_TEST_WORKSPACE === 'true') {
|
|
106
|
-
await workspaceHandlingTests.stopAndRemoveWorkspace(
|
|
104
|
+
await workspaceHandlingTests.stopAndRemoveWorkspace(workspaceName);
|
|
107
105
|
return;
|
|
108
106
|
}
|
|
109
107
|
|
|
110
108
|
Logger.info(`As far as the "TS_DELETE_PLUGINS_TEST_WORKSPACE" value is "false the workspace deletion is skipped"`);
|
|
111
109
|
});
|
|
112
110
|
});
|
|
113
|
-
|
|
114
111
|
});
|