Skip to content

Commit

Permalink
Merge pull request #27 from davesnx/I-25_Test-coverage
Browse files Browse the repository at this point in the history
  • Loading branch information
davesnx authored Jan 14, 2021
2 parents c654f9e + 631f8bc commit f99f39f
Show file tree
Hide file tree
Showing 20 changed files with 263 additions and 230 deletions.
19 changes: 13 additions & 6 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -57,22 +57,24 @@ jobs:
key: deps-${{ matrix.os }}-${{ hashFiles('**/index.json') }}
restore-keys: deps-${{ matrix.os }}-

- name: Build dependencies
if: steps.deps-cache.outputs.cache-hit != 'true'
run: esy build-dependencies

- name: Build
run: esy build

- name: Test
if: ${{ matrix.os != 'windows-latest' }}
run: |
rm test/__snapshots__/.gitkeep
esy test
# esy dune exec bisect-ppx-report send-to Coveralls *.coverage
esy dune runtest --instrument-with bisect_ppx --force
esy bisect-ppx-report send-to Coveralls
env:
BISECT_ENABLE: "yes"
BISECT_SILENT: "ERR"
COVERALLS_REPO_TOKEN: ${{ secrets.COVERALLS_REPO_TOKEN }}
PULL_REQUEST_NUMBER: ${{ github.event.number }}

- name: Export dependencies
run: esy export-dependencies

- name: Web build
if: ${{ matrix.os == 'ubuntu-latest' }}
run: |
Expand Down Expand Up @@ -112,6 +114,11 @@ jobs:
name: bundled
path: _build/default/js/Js.bc.js

# Cleanup build cache if dependencies have changed
- name: Clean build cache
if: steps.deps-cache.outputs.cache-hit != 'true'
run: esy cleanup .

publish:
needs: build
name: Publish
Expand Down
2 changes: 1 addition & 1 deletion dune-project
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
(lang dune 2.0)
(lang dune 2.7)

(using menhir 2.0)
14 changes: 9 additions & 5 deletions esy.json
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
"bin": "esy b dune exec Bin",
"build": "esy b dune build",
"start": "esy b dune build --watch",
"test": "esy b dune exec test/Run.exe",
"test": "esy b dune runtest --force",
"format": "esy b dune build @fmt --auto-promote --root ."
},
"esy": {
Expand All @@ -42,7 +42,7 @@
},
"devDependencies": {
"@esy-ocaml/reason": "~3.6.0",
"@opam/bisect_ppx": "2.4.1",
"@opam/bisect_ppx": "2.5.0",
"@opam/dune": "^2.7.0",
"@opam/menhir": "20200624",
"@opam/ppx_deriving": "4.5",
Expand All @@ -56,8 +56,12 @@
"bats": "^1.1.0"
},
"dependencies": {
"@opam/js_of_ocaml": "3.7.0",
"@opam/js_of_ocaml-compiler": "3.7.0",
"@opam/js_of_ocaml-ppx": "3.7.0"
"@opam/js_of_ocaml": "3.7.1",
"@opam/js_of_ocaml-compiler": "3.7.1",
"@opam/js_of_ocaml-ppx": "3.7.1"
},
"resolutions": {
"esy-m4": "esy-packages/esy-m4#c7cf0ac9221be2b1f9d90e83559ca08397a629e7",
"@opam/menhir": "20201216"
}
}
Loading

0 comments on commit f99f39f

Please sign in to comment.