Skip to content

Commit

Permalink
dependencies cache v4
Browse files Browse the repository at this point in the history
  • Loading branch information
datguychen committed Nov 9, 2023
1 parent 845d60f commit a9eb7d9
Show file tree
Hide file tree
Showing 2 changed files with 75 additions and 75 deletions.
58 changes: 29 additions & 29 deletions .github/workflows/PushWorkflow-UpdateCache.yml
Original file line number Diff line number Diff line change
@@ -1,36 +1,36 @@
name: E2E / Sanity / Push / Update Cache
# name: E2E / Sanity / Push / Update Cache

on:
push:
branches:
- main
# on:
# push:
# branches:
# - main


jobs:
Portfolio_E2E_Push_Update_Cache:
timeout-minutes: 30
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
ref: main
- uses: actions/setup-node@v3
with:
node-version: 18
# jobs:
# Portfolio_E2E_Push_Update_Cache:
# timeout-minutes: 30
# runs-on: ubuntu-latest
# steps:
# - uses: actions/checkout@v3
# with:
# ref: main
# - uses: actions/setup-node@v3
# with:
# node-version: 18

- name: Get node version
id: node
run: |
echo "version=$(node -v)" >> $GITHUB_OUTPUT
# - name: Get node version
# id: node
# run: |
# echo "version=$(node -v)" >> $GITHUB_OUTPUT

- name: Get node_modules cache
uses: actions/[email protected]
id: node_modules
with:
path: |
**/node_modules
key: basekey-test
# - name: Get node_modules cache
# uses: actions/[email protected]
# id: node_modules
# with:
# path: |
# **/node_modules
# key: basekey-test

- name: Run vercel tests
run: npx playwright test --grep "@vercel" --project="Chrome_With_Media"
# - name: Run vercel tests
# run: npx playwright test --grep "@vercel" --project="Chrome_With_Media"

92 changes: 46 additions & 46 deletions .github/workflows/PushWorkflow.yml
Original file line number Diff line number Diff line change
@@ -1,54 +1,54 @@
# name: E2E / Sanity / Push
name: E2E / Sanity / Push

# env:
# VERCEL_ORG_ID: ${{ secrets.VERCEL_ORG_ID }}
# VERCEL_PROJECT_ID: ${{ secrets.VERCEL_PROJECT_ID }}
env:
VERCEL_ORG_ID: ${{ secrets.VERCEL_ORG_ID }}
VERCEL_PROJECT_ID: ${{ secrets.VERCEL_PROJECT_ID }}

# on:
# push:
# branches:
# - main
on:
push:
branches:
- main

# jobs:
# Portfolio_E2E_Push_Main:
# timeout-minutes: 30
# runs-on: ubuntu-latest
# steps:
# - uses: actions/checkout@v3
# - uses: actions/setup-node@v3
# with:
# node-version: 18
jobs:
Portfolio_E2E_Push_Main:
timeout-minutes: 30
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: 18

# - name: Get node version
# id: node
# run: |
# echo "version=$(node -v)" >> $GITHUB_OUTPUT
- name: Get node version
id: node
run: |
echo "version=$(node -v)" >> $GITHUB_OUTPUT
# - name: Get node_modules cache
# uses: actions/[email protected]
# id: node_modules
# with:
# path: |
# **/node_modules
# key: basekey-test
- name: Get node_modules cache
uses: actions/[email protected]
id: node_modules
with:
path: |
**/node_modules
key: basekey-test

# - name: Run vercel tests
# run: npx playwright test --grep "@vercel" --project="Chrome_With_Media"
- name: Run vercel tests
run: npx playwright test --grep "@vercel" --project="Chrome_With_Media"

# - name: Upload test results
# if: always()
# uses: actions/upload-artifact@v3
# with:
# name: playwright-report
# path: playwright-report
# retention-days: 5
# - name: Pull Vercel Environment Information
# if: success()
# run: vercel pull --yes --environment=production --token=${{ secrets.VERCEL_TOKEN }}
# - name: Build Project Artifacts
# if: success()
# run: vercel build --prod --token=${{ secrets.VERCEL_TOKEN }}
# - name: Deploy Project Artifacts to Vercel
# if: success()
# run: vercel deploy --prebuilt --prod --token=${{ secrets.VERCEL_TOKEN }}
- name: Upload test results
if: always()
uses: actions/upload-artifact@v3
with:
name: playwright-report
path: playwright-report
retention-days: 5
- name: Pull Vercel Environment Information
if: success()
run: vercel pull --yes --environment=production --token=${{ secrets.VERCEL_TOKEN }}
- name: Build Project Artifacts
if: success()
run: vercel build --prod --token=${{ secrets.VERCEL_TOKEN }}
- name: Deploy Project Artifacts to Vercel
if: success()
run: vercel deploy --prebuilt --prod --token=${{ secrets.VERCEL_TOKEN }}

0 comments on commit a9eb7d9

Please sign in to comment.