Skip to content

Commit

Permalink
Add coverage test (#11)
Browse files Browse the repository at this point in the history
  • Loading branch information
bn-d committed May 12, 2023
1 parent be1c628 commit a155e13
Show file tree
Hide file tree
Showing 6 changed files with 27 additions and 6 deletions.
12 changes: 11 additions & 1 deletion .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ jobs:
- ubuntu-latest
ocaml-compiler:
- 4.04.x
- 4.14.x
- 4.14.1

runs-on: ${{ matrix.os }}

Expand All @@ -37,3 +37,13 @@ jobs:

- name: Test
run: opam exec -- dune runtest --verbose

- name: Coverage
if: ${{ matrix.ocaml-compiler == '4.14.1' }}
env:
COVERALLS_REPO_TOKEN: ${{ secrets.COVERALLS_REPO_TOKEN }}
PULL_REQUEST_NUMBER: ${{ github.event.number }}
run: |
opam exec -- dune runtest --instrument-with bisect_ppx --force
opam exec -- bisect-ppx-report summary
opam exec -- bisect-ppx-report send-to Coveralls
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
# ocamlbuild working directory
_build/
_coverage/

# Merlin configuring file for Vim and Emacs
.merlin
Expand Down
12 changes: 9 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,13 @@
# [@@deriving make]
[![OCaml](https://img.shields.io/badge/-OCaml-EC6813?logo=ocaml&labelColor=grey)](#)
[![CI](https://github.com/bn-d/ppx_make/actions/workflows/build.yml/badge.svg?branch=master)](https://github.com/bn-d/ppx_make/actions/workflows/build.yml)
[![GitHub release status](https://img.shields.io/github/v/release/bn-d/ppx_make)](https://github.com/bn-d/ppx_make/releases)
[![OCaml][ocaml-badge]](#)
[![CI][ci-badge]](https://github.com/bn-d/ppx_make/actions/workflows/build.yml)
[![GitHub release status][release-badge]](https://github.com/bn-d/ppx_make/releases)
[![Coverage Status][coveralls-badge]](https://coveralls.io/github/bn-d/ppx_make?branch=main)

[ocaml-badge]: https://img.shields.io/badge/-OCaml-EC6813?logo=ocaml&labelColor=white
[ci-badge]: https://github.com/bn-d/ppx_make/actions/workflows/build.yml/badge.svg?branch=master
[release-badge]: https://img.shields.io/github/v/release/bn-d/ppx_make
[coveralls-badge]: https://coveralls.io/repos/github/bn-d/ppx_make/badge.svg?branch=main

`[@@deriving]` plugin to generate make functions.

Expand Down
3 changes: 2 additions & 1 deletion dune-project
Original file line number Diff line number Diff line change
Expand Up @@ -16,4 +16,5 @@
(description "[@@deriving] plugin to generate make functions")
(depends
(ppxlib (>= 0.10.0))
(ounit2 :with-test)))
(ounit2 :with-test)
(bisect_ppx :with-test)))
1 change: 1 addition & 0 deletions ppx_make.opam
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ depends: [
"dune" {>= "2.7"}
"ppxlib" {>= "0.10.0"}
"ounit2" {with-test}
"bisect_ppx" {with-test}
"odoc" {with-doc}
]
build: [
Expand Down
4 changes: 3 additions & 1 deletion src/dune
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,6 @@
(kind ppx_deriver)
(preprocess
(pps ppxlib.metaquot))
(libraries ppxlib))
(libraries ppxlib)
(instrumentation
(backend bisect_ppx)))

0 comments on commit a155e13

Please sign in to comment.