Skip to content

Update README.md

Update README.md #323

name: Github Actions
# Define an event (or events) that triggers this workflow.
on:
push:
branches:
- testing
pull_request:
branches:
- master
- development
jobs:
test:
name: Server Unit Tests
runs-on: ubuntu-latest
timeout-minutes: 5
strategy:
matrix:
node-version: [12.x]
# Define the steps in this workflow.
steps:
- uses: actions/checkout@v1
# 1. Specify the node version and environment the tests will be run on.
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v1
with:
node-version: ${{ matrix.node-version }}
# 2. Run npm install.
- name: Install
run: npm install
# 3. Run tests.
- name: Test
# You can import environment varialbes by saving them to repository secrets.
env:
DB_HOST: ${{ secrets.DB_HOST }}
DB_USER: ${{ secrets.DB_USER }}
DB_PASS: ${{ secrets.DB_PASS }}
DB_NAME: ${{ secrets.DB_NAME }}
DB_PORT: ${{ secrets.DB_PORT }}
NODE_ENV: ${{ secrets.NODE_ENV }}
KNEX_CLIENT: ${{ secrets.KNEX_CLIENT }}
run: npm test