Skip to content

Commit

Permalink
ci: Update Workflows (#788)
Browse files Browse the repository at this point in the history
  • Loading branch information
evansims authored Nov 2, 2023
2 parents 388d2f0 + d4b2624 commit 11af8bb
Show file tree
Hide file tree
Showing 2 changed files with 31 additions and 28 deletions.
55 changes: 28 additions & 27 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
@@ -1,41 +1,42 @@
name: CI

on:
pull_request:
types:
- opened
- synchronize
pull_request:
types:
- opened
- synchronize

permissions: {}

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: ${{ github.ref != 'refs/heads/master' }}

jobs:
test:
name: Run JS tests
runs-on: ubuntu-latest
test:
name: Run JS tests
runs-on: ubuntu-latest

env:
node: 'lts/*'
env:
node: 'lts/*'

steps:
- name: Checkout
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11
steps:
- name: Checkout
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11

- name: Setup Node.js
uses: actions/setup-node@8f152de45cc393bb48ce5d89d36b731f54556e65
with:
node-version: ${{ env.node }}
cache: 'yarn'
- name: Setup Node.js
uses: actions/setup-node@8f152de45cc393bb48ce5d89d36b731f54556e65
with:
node-version: ${{ env.node }}
cache: 'yarn'

- name: Install dependencies
run: yarn install --frozen-lockfile
- name: Install dependencies
run: yarn install --frozen-lockfile

- name: Run tests
run: yarn run test:ci
- name: Run tests
run: yarn run test:ci

- name: Upload coverage report
uses: codecov/codecov-action@eaaf4bedf32dbdc6b720b63067d99c4d77d6047d
with:
directory: coverage
- name: Upload coverage report
uses: codecov/codecov-action@eaaf4bedf32dbdc6b720b63067d99c4d77d6047d
with:
directory: coverage
4 changes: 3 additions & 1 deletion .github/workflows/snyk.yml
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,8 @@ jobs:
with:
ref: ${{ github.event.pull_request.head.sha || github.ref }}

- uses: snyk/actions/php@b98d498629f1c368650224d6d212bf7dfa89e4bf # [email protected]
- run: npm install -g snyk

- run: snyk test
env:
SNYK_TOKEN: ${{ secrets.SNYK_TOKEN }}

0 comments on commit 11af8bb

Please sign in to comment.