name: CI

on: [push, pull_request]

jobs:
  format:
    name: Format
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v1

      - name: Install OTP and Elixir
        uses: actions/setup-elixir@v1
        with:
          otp-version: 22.2
          elixir-version: 1.10.1

      - name: Install dependencies
        run: mix deps.get

      - name: Check mix format
        run: mix format --check-formatted

  test:
    name: Test
    runs-on: ubuntu-latest
    strategy:
      fail-fast: false
      matrix:
        pair:
          - erlang: 22.2
            elixir: 1.10.1
          - erlang: 22.1
            elixir: 1.9.4
          - erlang: 21.3
            elixir: 1.8.2
          - erlang: 20.3.1
            elixir: 1.7.4
          - erlang: 19.3
            elixir: 1.6.6
    steps:
      - uses: actions/checkout@v1

      - name: Install OTP and Elixir
        uses: actions/setup-elixir@v1
        with:
          otp-version: ${{matrix.pair.erlang}}
          elixir-version: ${{matrix.pair.elixir}}

      - name: Install dependencies
        run: mix deps.get

      - name: Start docker
        run: docker-compose up --detach

      - name: Run tests
        run: mix test --trace --exclude propcheck

name: CI

on: [push, pull_request]

jobs:
  format:
    name: Format
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v1

      - name: Install OTP and Elixir
        uses: actions/setup-elixir@v1
        with:
          otp-version: 22.2
          elixir-version: 1.10.1

      - name: Install dependencies
        run: mix deps.get

      - name: Check mix format
        run: mix format --check-formatted

  test:
    name: Test
    runs-on: ubuntu-latest
    strategy:
      fail-fast: false
      matrix:
        pair:
          - erlang: 22.3
            elixir: 1.10.3
          - erlang: 22.1
            elixir: 1.9.4
          - erlang: 21.3
            elixir: 1.8.2
          - erlang: 20.3.1
            elixir: 1.7.4
          - erlang: 19.3
            elixir: 1.7.4
    steps:
      - uses: actions/checkout@v1

      - name: Install OTP and Elixir
        uses: actions/setup-elixir@v1
        with:
          otp-version: ${{matrix.pair.erlang}}
          elixir-version: ${{matrix.pair.elixir}}

      - name: Install dependencies
        run: mix deps.get

      - name: Start docker
        run: docker-compose up --detach

      - name: Run tests
        run: mix test --trace --exclude propcheck

Update Elixir/Erlang versions on CI
Update Elixir/Erlang versions on CI
