language: c
env:
  # ppx_deriving seems not to generate anything
  #  - OCAML_VERSION=4.03.0
  #  - OCAML_VERSION=4.03.0+flambda
  #  - OCAML_VERSION=4.04.2
  #  - OCAML_VERSION=4.04.2+flambda
  #  Only 4.06 allows type constructors with different parameters to be substituted.
  - OCAML_VERSION=4.05.0
  - OCAML_VERSION=4.05.0+flambda
  #  Only 4.06 allows type constructors with different parameters to be substituted.
  # - OCAML_VERSION=4.06.1
  # - OCAML_VERSION=4.06.1+flambda
addons:
  apt:
    sources:
      - avsm
    packages:
      - opam
      - time
cache:
  directories:
    - $HOME/.opam
before_install:
  - export OPAMYES=1
  - export OPAMVERBOSE=1
  - opam init
  - opam switch ${OCAML_VERSION}
  - eval `opam config env`
  - opam update
  - opam pin add dolmen https://github.com/Gbury/dolmen.git#1cabe6b20b3b5f32c4dd9704fdb105cd941cd572
  - opam pin add --no-action witan .
  - opam install --deps-only witan
  - opam install ounit
  - opam list --installed
  - opam upgrade --yes
  - opam list --installed
install:
  - make build-dev
script:
  - make test-dev
