-
-
Notifications
You must be signed in to change notification settings - Fork 237
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
8 changed files
with
95 additions
and
283 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,54 @@ | ||
name: E2E Test for ModernJS SSR Data Loader | ||
|
||
on: | ||
workflow_call: | ||
|
||
jobs: | ||
e2e-modern: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout Repository | ||
uses: actions/checkout@v3 | ||
with: | ||
fetch-depth: 0 | ||
|
||
- name: Install Pnpm | ||
run: corepack enable | ||
|
||
- name: Setup Node.js 18 | ||
uses: actions/setup-node@v3 | ||
with: | ||
node-version: '18' | ||
cache: 'pnpm' | ||
|
||
- name: Set Nx SHA | ||
uses: nrwl/nx-set-shas@v3 | ||
|
||
- name: Set SKIP_DEVTOOLS_POSTINSTALL environment variable | ||
run: echo "SKIP_DEVTOOLS_POSTINSTALL=true" >> $GITHUB_ENV | ||
|
||
- name: Install Dependencies | ||
run: pnpm install | ||
|
||
- name: Install Cypress | ||
run: npx cypress install | ||
|
||
- name: Run Build for All | ||
run: npx nx run-many --targets=build --projects=tag:type:pkg | ||
|
||
- name: Run condition check script | ||
id: check-ci | ||
run: node tools/scripts/ci-is-affected.mjs --appName=modernjs | ||
|
||
- name: E2E Test for Modern.js SSR Data Loader | ||
if: steps.check-ci.outcome == 'success' | ||
run: | | ||
lsof -ti tcp:3062,3061,3063,3064| xargs -r kill && | ||
pnpm run app:modern:dev & | ||
sleep 1 && | ||
npx wait-on http://127.0.0.1:3062/ && | ||
npx wait-on http://127.0.0.1:3061/ && | ||
npx wait-on http://127.0.0.1:3063/ && | ||
npx wait-on http://127.0.0.1:3064/ && | ||
npx nx run modernjs-ssr-data-loader-host:e2e && | ||
lsof -ti tcp:3062,3061,3063,3064 | xargs kill |
Oops, something went wrong.