Fix deprecation warnings #16
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # Via https://github.com/Kraigie/nostrum/blob/master/.github/workflows/test_and_lint.yml | |
| name: Test & Lint | |
| on: [push, pull_request] | |
| jobs: | |
| test: | |
| runs-on: ubuntu-20.04 | |
| strategy: | |
| matrix: | |
| elixir-version: ['1.12', '1.13', '1.14'] | |
| otp-version: ['22', '23', '24', '25'] | |
| exclude: | |
| - elixir-version: '1.11' | |
| otp-version: '24' | |
| - elixir-version: '1.11' | |
| otp-version: '25' | |
| - elixir-version: '1.12' | |
| otp-version: '25' | |
| - elixir-version: '1.14' | |
| otp-version: '22' | |
| steps: | |
| - uses: actions/checkout@v2 | |
| - uses: erlef/setup-beam@v1 | |
| with: | |
| otp-version: ${{ matrix.otp-version }} | |
| elixir-version: ${{ matrix.elixir-version }} | |
| - uses: actions/cache@v2 | |
| with: | |
| path: | | |
| _build | |
| deps | |
| # Generate a hash of the OTP version and Elixir version | |
| key: ${{ matrix.otp-version }}-${{ matrix.elixir-version }}-mix-${{ hashFiles(format('{0}{1}', github.workspace, '/mix.lock')) }} | |
| restore-keys: ${{ matrix.otp-version }}-${{ matrix.elixir-version }}-mix | |
| - run: mix deps.get | |
| name: Fetch Dependencies | |
| - run: mix test | |
| name: Run Tests | |
| lint: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v2 | |
| - uses: erlef/setup-beam@v1 | |
| with: | |
| otp-version: 25 | |
| elixir-version: 1.14 | |
| - uses: actions/cache@v2 | |
| with: | |
| path: | | |
| _build | |
| deps | |
| # Generate a hash of the OTP version and Elixir version | |
| key: mix-${{ hashFiles(format('{0}{1}', github.workspace, '/mix.lock')) }} | |
| restore-keys: mix | |
| - run: mix deps.get | |
| name: Fetch Dependencies | |
| - run: mix credo --strict | |
| name: Lint | |
| - run: mix format --check-formatted | |
| name: Check Formatting | |
| # time for the final boss | |
| - run: mix dialyzer | |
| name: Run dialyzer |