Skip to content

Commit

Permalink
Add github actions
Browse files Browse the repository at this point in the history
  • Loading branch information
mobileoverlord committed Apr 16, 2024
1 parent f456ace commit 3313bf6
Show file tree
Hide file tree
Showing 2 changed files with 41 additions and 4 deletions.
41 changes: 41 additions & 0 deletions .github/workflows/build_test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
name: Build and Test

on:
pull_request:
branches:
- "**"
push:
branches:
- main

permissions:
contents: read

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

steps:
- uses: actions/checkout@v4
- name: Set up Elixir
uses: erlef/setup-beam@v1
with:
elixir-version: '1.16.2'
otp-version: '26.2.3'
- name: Restore dependencies cache
uses: actions/cache@v4
with:
path: deps
key: ${{ runner.os }}-mix-${{ hashFiles('**/mix.lock') }}
restore-keys: ${{ runner.os }}-mix-
- name: Get dependencies and compile
run: |
mix deps.get
mix compile --warnings-as-errors
- name: Verify formatting
run: mix format --check-formatted
- name: Audit dependencies
run: mix hex.audit
- name: Run tests
run: mix test
4 changes: 0 additions & 4 deletions test/peridio/rat_test.exs
Original file line number Diff line number Diff line change
@@ -1,8 +1,4 @@
defmodule Peridio.RATTest do
use ExUnit.Case
doctest Peridio.RAT

test "greets the world" do
assert Peridio.RAT.hello() == :world
end
end

0 comments on commit 3313bf6

Please sign in to comment.