Skip to content

Commit

Permalink
[#54] Add workflow for next.js v13
Browse files Browse the repository at this point in the history
  • Loading branch information
tednguyendev committed May 24, 2023
1 parent a96f0e3 commit 87486fb
Show file tree
Hide file tree
Showing 3 changed files with 4,422 additions and 4,405 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/nextjs_12_test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ on:

jobs:
test:
name: Run linters and tests
name: Run linters and tests Next.js 12
runs-on: ubuntu-latest
steps:
- name: Cancel Previous Runs
Expand Down
38 changes: 38 additions & 0 deletions .github/workflows/nextjs_13_test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
name: Test

on:
pull_request:
paths:
- nextjs-13/**

jobs:
test:
name: Run linters and tests Next.js 13
runs-on: ubuntu-latest
defaults:
run:
working-directory: ./nextjs-13
steps:
- name: Cancel Previous Runs
uses: styfle/cancel-workflow-action@0.11.0
with:
access_token: ${{ github.token }}

- name: Checkout
uses: actions/checkout@v3

- name: Setup node and restore cached dependencies
uses: actions/setup-node@v3
with:
node-version: '16'
cache: 'npm'
cache-dependency-path: 'nextjs-13/package-lock.json'

- name: Install dependencies
run: 'cd nextjs-13 && npm ci'

- name: Run linter
run: 'cd nextjs-13 && npm run lint'

- name: Run unit tests
run: 'cd nextjs-13 && npm run test:coverage'
Loading

0 comments on commit 87486fb

Please sign in to comment.