-
Notifications
You must be signed in to change notification settings - Fork 323
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
Integration Tests #11186
Integration Tests #11186
Conversation
.slice(1) | ||
.filter( | ||
option => | ||
option !== '--no-sandbox' && |
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.
optional: consider using a regex instead
await expect(page.getByRole('textbox', { name: 'password' })).toBeVisible() | ||
if (process.env.ENSO_TEST_USER == null || process.env.ENSO_TEST_USER_PASSWORD == null) { | ||
throw Error( | ||
'Cannot log in; ENSO_TEST_USER and ENSO_TEST_USER_PASSWORD env variables are not provided', |
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.
nit: personal preference but i like it when code (ENSO_TEST_USER
) is surrounded by backticks
await page.keyboard.press('Enter') | ||
|
||
// Accept terms screen | ||
await expect(page.getByText('I agree')).toHaveCount(2) |
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 suppose this is sufficient for now. but we will probably want to extract dashboard and/or GUI actions to a shared package
@@ -0,0 +1,13 @@ | |||
/** @file A test for basic flow of the application: open project and see if nodes appear. */ |
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.
nit re: file name - for test files named after actions, i name them like methods - so present (present simple) tense instead of continuous tense (createNewProject
)
args | ||
.slice(1) | ||
// Omitting $ in --inspect and --remote-debugging-port is intentional. | ||
.filter(option => !/^--no-sandbox$|^--inspect|^--remote-debugging-port/.test(option)) |
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.
nit: consider inspect\b
and port\b
. not perfect but might as well
I am at 96fa2ee and I tried:
I guess either the |
maybe you're missing |
No, The issue is very strange, could you run it with |
With 73abe90 I can: enso$ export DEBUG="pw:browser log:"
enso$ ./run ide build
...
INFO main_internal: enso_build_cli: close
INFO enso_build_cli: Successfully ending. and then |
Pull Request Description
A stub for integration tests to be run locally; part of #8487
To run tests, you need to:
./run ide build
corepack pnpm -r --filter enso exec playwright test
The tests are run with a separate projects directory set up in tmpdir, so any local workspace dir is not affected.
The only test so far just checks if it's possible to log in and create a new project.
Important Notes
Checklist
Please ensure that the following checklist has been satisfied before submitting the PR:
[ ] Screenshots/screencasts have been attached, if there are any visual changes. For interactive or animated visual changes, a screencast is preferred.Scala,
Java,
TypeScript,
and
Rust
style guides. In case you are using a language not listed above, follow the Rust style guide.
[ ] Unit tests have been written where possible.