-
Notifications
You must be signed in to change notification settings - Fork 2.8k
[ZEPPELIN-6358] Seperate environment config and shared utilities from #5101 #5128
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
base: master
Are you sure you want to change the base?
Conversation
d0e0380 to
fc44d9c
Compare
83424ae to
1f45f33
Compare
.github/workflows/frontend.yml
Outdated
| - name: Setup Zeppelin Configuration (Disable Git) | ||
| run: | | ||
| echo "Setting ZEPPELIN_NOTEBOOK_STORAGE environment variable" | ||
| echo "ZEPPELIN_NOTEBOOK_STORAGE=org.apache.zeppelin.notebook.repo.VFSNotebookRepo" >> $GITHUB_ENV |
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.
Why set ZEPPELIN_NOTEBOOK_STORAGE in a separate step instead of in the job's env section?
run-playwright-e2e-tests:
env:
ZEPPELIN_NOTEBOOK_STORAGE: org.apache.zeppelin.notebook.repo.VFSNotebookRepoIs there a specific reason for the current approach?
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.
a07052f
Thanks for the suggestion. I’ve updated it to include it in the env step, which seemed like the better approach.
| // Find the test folder | ||
| const testFolders = data.body.filter( | ||
| (item: { path: string }) => | ||
| item.path && item.path.split(E2E_TEST_FOLDER)[0] === '/' && !item.path.includes(`~Trash`) |
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.
This might be subjective, but item.path.split('/')[1] === E2E_TEST_FOLDER felt a bit easier for me to understand at a glance.
Using split('/') makes it clearer that we’re checking the first segment of the path.
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.
e6033e8
I’ve updated it according to the conditions you mentioned.
What is this PR for?
In #5101, the amount of changes became too large, and a committer suggested splitting it into smaller parts. Since the updates related to the common test environment and shared utility functions have already proven to be stable, I separated those pieces into this dedicated PR.
This PR includes only the safe, standalone changes that improve the shared E2E environment and utilities.
[Summary of Changes]
Refined and separated E2E test environment setup
Improved global setup/teardown
ZEPPELIN_E2E_TEST_NOTEBOOK_DIRlocally, the server has to be restarted at least once, which feels a bit odd to enforce during E2E test execution. To make things less messy from a UI perspective, I reorganized the structure so that all tests are collected underE2E_TEST_FOLDERinstead.Added folder/notebook initialization and cleanup logic
npm run e2e:cleanup(automatically run this once the tests are finished)Extracted shared utilities and constants
E2E_TEST_FOLDER)Updated GitHub Actions (
frontend.yml)Playwright reportfrom 30 days to 3 daysUpdated Playwright / ESLint configurations
What type of PR is it?
Improvement
Refactoring
Todos
What is the Jira issue?
ZEPPELIN-6358
How should this be tested?
cd zeppelin-web-angular nvm use npm run start npm run e2e npm run e2e:cleanupScreenshots (if appropriate)
Questions: