Skip to content

Commit

Permalink
Add GitHub action for building/testing
Browse files Browse the repository at this point in the history
  • Loading branch information
sktrent committed Jan 12, 2024
1 parent 5c0ef7a commit f61c4e8
Show file tree
Hide file tree
Showing 3 changed files with 42 additions and 2 deletions.
37 changes: 37 additions & 0 deletions .github/workflows/run-tests.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
name: Run tests

on:
pull_request:
push:

permissions: read-all

jobs:
build:
strategy:
fail-fast: false
matrix:
os:
- macos-latest
- ubuntu-latest
- windows-latest
ocaml-compiler:
- "4.14"
- "5.1"

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

steps:
- name: Checkout tree
uses: actions/checkout@v4

- name: Set-up OCaml ${{ matrix.ocaml-compiler }}
uses: ocaml/setup-ocaml@v2
with:
ocaml-compiler: ${{ matrix.ocaml-compiler }}

- run: opam install . --deps-only --with-test

- run: opam exec -- dune build

- run: opam exec -- dune runtest
5 changes: 4 additions & 1 deletion dune-project
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,10 @@
(package
(name middleware)
(synopsis "Composable stacked functions, which can respond to inner calls")
(depends ocaml dune)
(depends
(ocaml (>= 4.14.0))
dune
)
(tags
(middleware composition funciton)))

Expand Down
2 changes: 1 addition & 1 deletion middleware.opam
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ tags: ["middleware" "composition" "funciton"]
homepage: "https://github.com/skolemlabs/midddleware"
bug-reports: "https://github.com/skolemlabs/midddleware/issues"
depends: [
"ocaml"
"ocaml" {>= "4.14.0"}
"dune" {>= "3.11"}
"odoc" {with-doc}
]
Expand Down

0 comments on commit f61c4e8

Please sign in to comment.