Skip to content

Commit

Permalink
closes #21 Add CI for tests and elm-review
Browse files Browse the repository at this point in the history
  • Loading branch information
decioferreira committed Sep 17, 2024
1 parent bd5354d commit 29f763a
Show file tree
Hide file tree
Showing 3 changed files with 31 additions and 4 deletions.
26 changes: 26 additions & 0 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
# This workflow will do a clean installation of node dependencies, cache/restore them, build the source code and run tests for the configured nvm version of node
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-nodejs

name: CI

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

jobs:
build:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version-file: ".nvmrc"
cache: "npm"
- run: npm ci
- run: npm run build
- run: npm test
- run: npm run elm-test
- run: npm run elm-review
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ npm install
Generate guida:

```
npm start
npm run build
```

Link the project to run `guida` command:
Expand Down Expand Up @@ -80,7 +80,7 @@ You can then `open index.html`.
To clear all cache and re-generate `./bin/guida.js` run the following:

```
rm -rf ~/.guida guida-stuff; npm start
rm -rf ~/.guida guida-stuff; npm run build
```

# Run tests
Expand Down
5 changes: 3 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,10 @@
"guida": "./bin/index.js"
},
"scripts": {
"start": "./lib/guida.js",
"build": "./lib/guida.js",
"test": "jest",
"elm-test": "elm-test"
"elm-test": "elm-test",
"elm-review": "elm-review"
},
"dependencies": {
"adm-zip": "^0.5.15",
Expand Down

0 comments on commit 29f763a

Please sign in to comment.