Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
43 changes: 29 additions & 14 deletions .github/workflows/unit-test.yml
Original file line number Diff line number Diff line change
@@ -1,11 +1,8 @@
# This workflow will do a clean install of node dependencies, build the source code and run tests across different versions of node
# For more information see: https://help.github.com/actions/language-and-framework-guides/using-nodejs-with-github-actions

name: App SDK CI - Unit Testing

on:
push:
branches: [master]
branches: [main]

pull_request:
types: [opened, synchronize, reopened]
Expand All @@ -14,23 +11,41 @@ jobs:
build:
runs-on: ubuntu-latest

strategy:
matrix:
node-version: [18.x]

steps:
- name: Checkout repository
uses: actions/checkout@v2
uses: actions/checkout@v4

- name: Use Node.js
uses: actions/setup-node@v4
with:
node-version: '18.x'
node-version-file: .nvmrc
cache: npm

- name: Install deps
run: npm ci

- name: Build
run: npm run build

- name: Run unit tests with coverage
run: npm run test:coverage

lint:
runs-on: ubuntu-latest

steps:
- name: Checkout repository
uses: actions/checkout@v4

- name: Use Node.js
uses: actions/setup-node@v2
uses: actions/setup-node@v4
with:
node-version: '18.x'
node-version-file: .nvmrc
cache: npm

- name: Install deps
run: npm ci

- name: Run unit test
run: npm run test
# No --fix. Fails until MKT-22133: 3 warnings sit on exported types.
- name: Lint
run: npm run lint
1 change: 1 addition & 0 deletions .nvmrc
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
24
Loading
Loading