Skip to content

Commit

Permalink
Merge pull request #179 from ActivityWatch/github-actions
Browse files Browse the repository at this point in the history
Switched to GitHub actions
  • Loading branch information
ErikBjare committed Mar 27, 2020
2 parents f3fcb20 + 4421d89 commit ed6bed6
Show file tree
Hide file tree
Showing 10 changed files with 509 additions and 33 deletions.
46 changes: 46 additions & 0 deletions .github/workflows/nodejs.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
# 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: Node

on:
push:
branches: [ master ]
pull_request:
branches: [ master ]

jobs:
build:
runs-on: ubuntu-latest

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

steps:
- uses: actions/checkout@v2
with:
submodules: 'recursive'
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v1
with:
node-version: ${{ matrix.node-version }}
- name: Install
run: npm ci
- name: Build
run: npm run build
- name: Run tests
run: npm test
- name: Serve webui
run: npm run serve &
- name: Run e2e tests with testcafe
uses: DevExpress/testcafe-action@latest
with:
args: "chrome test/e2e/"
- name: Upload screenshots
uses: actions/upload-artifact@v2-preview
with:
name: screenshots
path: screenshots/*


1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -7,3 +7,4 @@ test/unit/coverage
test/e2e/reports
*.swp
__pycache__
screenshots
19 changes: 0 additions & 19 deletions .travis.yml

This file was deleted.

12 changes: 6 additions & 6 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
.PHONY: install build dev test clean aw-client-js
.PHONY: install build dev test clean

.FORCE: ;

build: install
npm run build

install: aw-client-js
npm install
install:
npm ci

uninstall:
rm -r node_modules/
Expand All @@ -17,6 +17,9 @@ dev:
test:
npm test

test-e2e:
testcafe firefox test/e2e/

clean:
rm -rf node_modules dist

Expand All @@ -25,6 +28,3 @@ lint:

lint-fix:
npx eslint --ext=js,ts,vue --fix src/

aw-client-js:
make --directory=aw-client-js build
Loading

0 comments on commit ed6bed6

Please sign in to comment.