name: Ctypes

on:
  - pull_request
  - push

jobs:
  tests:
    name: Tests

    strategy:
      fail-fast: false
      matrix:
        os:
          - macos-latest
          - ubuntu-latest
          - windows-latest
        ocaml-version:
          - 4.09.0
          - 4.10.0

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

    steps:
      - name: Checkout code
        uses: actions/checkout@v2

      - name: Use OCaml ${{ matrix.ocaml-version }}
        uses: avsm/setup-ocaml@v1
        with:
          ocaml-version: ${{ matrix.ocaml-version }}

      - name: Deps
        run: |
          opam pin add -n ctypes.dev .
          opam pin add -n ctypes-foreign.dev .
          opam depext -ty ctypes ctypes-foreign
          opam install -t --deps-only .

      - name: Build
        run: opam exec -- make

      - name: Test
        run: opam exec -- make test

name: Ctypes

on:
  - pull_request
  - push
  - workflow_dispatch

jobs:
  tests:
    name: Tests

    strategy:
      fail-fast: false
      matrix:
        os:
          - macos-latest
          - ubuntu-latest
          - windows-latest
        ocaml-version:
          - 4.09.0
          - 4.10.0

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

    steps:
      - name: Checkout code
        uses: actions/checkout@v2

      - name: Use OCaml ${{ matrix.ocaml-version }}
        uses: avsm/setup-ocaml@v1
        with:
          ocaml-version: ${{ matrix.ocaml-version }}

      - name: Deps
        run: |
          opam pin add -n ctypes.dev .
          opam pin add -n ctypes-foreign.dev .
          opam depext -ty ctypes ctypes-foreign
          opam install -t --deps-only .

      - name: Build
        run: opam exec -- make

      - name: Test
        run: opam exec -- make test

Add a workflow_dispatch button to the GitHub Actions config.
Add a workflow_dispatch button to the GitHub Actions config.
