Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Some changes #111

Closed
wants to merge 2 commits into from
Closed
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
68 changes: 27 additions & 41 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -1,56 +1,42 @@
name: Continuous Integration Workflow
name: Continuous integration workflow

# This workflow is triggered whenever a new PR is created on the main branch
on:
pull_request:
branches:
- main
paths:
- 'web/**'
push:
branches:
- main
paths:
- 'web/**'

defaults:
run:
shell: bash
working-directory: ./web

jobs:

# Run unit tests to make sure everything is 👍
test:
name: 'Run unit tests'
defaults:
run:
shell: bash
# Define the working directory for all run steps in the workflow
working-directory: ./web
# Specify the OS we want the workflow to run on
name: Run unit tests
runs-on: ubuntu-latest
# Define the steps for this job
steps:
- uses: actions/checkout@v2
name: 'Checkout repository'

- name: 'Install Dependencies'
run: npm install

- name: 'Run Tests'
run: npm run test
- name: Checkout repository
uses: actions/checkout@v2

- name: Install dependencies
run: npm install

- name: Run tests
run: npm run test

# Run the linter to check for code style issues
lint:
name: 'Run linter'
defaults:
run:
shell: bash
# Define the working directory for all run steps in the workflow
working-directory: ./web
name: Run linter
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
name: 'Checkout repository'

- name: 'Install Dependencies'
run: npm install

- name: 'Run Linter'
run: npx standard -v
steps:

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

- name: Install dependencies
run: npm install

- name: Run linter
run: npx standard -v

2 changes: 1 addition & 1 deletion web/routes/users.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ const express = require('express')
const router = express.Router()

/* GET users listing. */
router.get('/users', function (req, res, next) {
router.get('/usrs', function (req, res, next) {
res.send('respond with a resource')
})

Expand Down