Skip to content
Merged
Changes from 1 commit
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
Prev Previous commit
Next Next commit
Refacto CI process
  • Loading branch information
fabidick22 committed Mar 21, 2020
commit 82ef25cb915758396700ab7afc914c7708fe75f8
44 changes: 34 additions & 10 deletions .github/workflows/CI-time-tracker-ui.yml
Original file line number Diff line number Diff line change
@@ -1,26 +1,50 @@
name: Node.js CI
name: CI process for time-tracker app

on:
# Trigger the workflow on push or pull request
push:
branches:
- '*'
- '*/*'
- '!master'

pull_request:
branches: [ master ]
types: [opened, edited, reopened, synchronize]
branches:
- master

jobs:
build:

security-audit:
name: Running npm audit
runs-on: ubuntu-latest
timeout-minutes: 60
steps:
- name: Clone and checkout branch
uses: actions/checkout@master

- name: Set up Node.js version
uses: actions/setup-node@v1
with:
node-version: '12.x'

- name: Security Audit
run: npm audit

ci-test:
name: Running unit tests
runs-on: ubuntu-latest
timeout-minutes: 90
steps:
- name: Clone and checkout branch
uses: actions/checkout@v2
uses: actions/checkout@master

- name: Set up Node.js version
uses: actions/setup-node@v1
with:
node-version: '12.x'

- name: Install dependencies
run: npm install
- run: npm run build --if-present

- name: Run the test
run: npm test
- run: npm audit
env:
CI: true
run: npm run ci-test --if-present