-
Notifications
You must be signed in to change notification settings - Fork 1.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Selenium] Add DevWorkspaceHappyPath e2e typescript test #19152
Changes from 1 commit
5b24e0b
b9a50f7
1dd3ee7
2794690
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
--timeout 2200000 | ||
--reporter 'dist/driver/CheReporter.js' | ||
-u tdd | ||
--bail | ||
--full-trace | ||
--spec dist/tests/e2e_happy_path/DevWorkspaceHappyPath.spec.js | ||
--require source-map-support/register |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
// /********************************************************************* | ||
// * Copyright (c) 2021 Red Hat, Inc. | ||
// * | ||
// * This program and the accompanying materials are made | ||
// * available under the terms of the Eclipse Public License 2.0 | ||
// * which is available at https://www.eclipse.org/legal/epl-2.0/ | ||
// * | ||
// * SPDX-License-Identifier: EPL-2.0 | ||
// **********************************************************************/ | ||
|
||
import { e2eContainer } from '../../inversify.config'; | ||
import { CLASSES } from '../../inversify.types'; | ||
import { DriverHelper } from '../../utils/DriverHelper'; | ||
import * as projectAndFileTests from '../../testsLibrary/ProjectAndFileTests'; | ||
import { TestConstants } from '../..'; | ||
|
||
const driverHelper: DriverHelper = e2eContainer.get(CLASSES.DriverHelper); | ||
|
||
suite('Workspace creation via factory url', async () => { | ||
|
||
let factoryUrl : string = `${TestConstants.TS_SELENIUM_DEVWORKSPACE_URL}`; | ||
const workspaceSampleName: string = 'web-nodejs-sample'; | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Workspace name What if we name test workspace as There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. For now this test will check workspace created from flattened_theia-next.yaml yaml. And it uses web-nodejs-sample. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. IF there is only one type of supported workspaces, I might make sense to express it in the test code, e.g.:
|
||
const workspaceRootFolderName: string = 'app'; | ||
|
||
suite('Open factory URL', async () => { | ||
test(`Navigating to factory URL`, async () => { | ||
await driverHelper.navigateToUrl(factoryUrl); | ||
}); | ||
}); | ||
|
||
suite('Wait workspace readyness', async () => { | ||
SkorikSergey marked this conversation as resolved.
Show resolved
Hide resolved
|
||
projectAndFileTests.waitWorkspaceReadiness(workspaceSampleName, workspaceRootFolderName); | ||
}); | ||
|
||
}); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is it actually existed workspace URL or URL to it's devfile ?
If it's URL to devfile which is used to create devworkspace,
TS_SELENIUM_DEVWORKSPACE_DEVFILE_URL
name is more relevant to value.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It is url of existed workspace.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I see. We can keep it as proof of conception, but in future there should be factory URL with link to raw devfile, as far as I know.