Skip to content

Commit

Permalink
ci(serum): add a GitHub actions workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
Dalgona committed Aug 9, 2020
1 parent 97dd999 commit d803c6e
Showing 1 changed file with 47 additions and 0 deletions.
47 changes: 47 additions & 0 deletions .github/workflows/build_and_test.yml
@@ -0,0 +1,47 @@
name: Build and Test Serum

on: [push, pull_request]

jobs:
build-and-test:
name: Build and Test Serum
runs-on: ubuntu-latest

strategy:
matrix:
otp-version: ['22.3.4.5']
elixir-version: ['1.9.4', '1.10.4']

env:
MIX_ENV: test

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

- name: Checkout Code
uses: actions/checkout@v2

- name: Cache Dependencies
uses: actions/cache@v2
with:
path: |
_build
deps
key: mix-lock-${{ matrix.otp-version }}-${{ matrix.elixir-version }}-${{ hashFiles('mix.lock') }}

- name: Fetch and Compile Dependencies
run: mix do deps.get, deps.compile

- name: Enforce Coding Styles
run: |
mix format --check-formatted
mix credo --all --strict
- name: Run Tests and Generate Coverage Report
run: mix coveralls.github
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

0 comments on commit d803c6e

Please sign in to comment.