diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index f010e8fc..070b70ea 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -8,11 +8,11 @@ on: jobs: test: - name: ${{ matrix.test-type }} test on OTP ${{matrix.otp}} + name: ${{ matrix.test-type }} test on OTP ${{matrix.otp_vsn}} strategy: matrix: - otp_vsn: ['25.3', '24.3'] - rebar_vsn: ['3.20.0'] + otp_vsn: ['26.1', '25.3', '24.3'] + rebar_vsn: ['3.22.0'] test-type: ['regular', 'integration'] runs-on: 'ubuntu-22.04' steps: @@ -23,6 +23,11 @@ jobs: rebar3-version: ${{ matrix.rebar_vsn }} - if: matrix.test-type == 'regular' run: make test + - if: matrix.test-type == 'regular' + name: Upload coverage reports to Codecov + uses: codecov/codecov-action@v3 + env: + CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }} - if: matrix.test-type == 'integration' run: make integration_test env: diff --git a/.gitignore b/.gitignore index aac4a924..934bdaad 100644 --- a/.gitignore +++ b/.gitignore @@ -19,3 +19,4 @@ _build rebar3.crashdump *~ doc/ +codecov.json diff --git a/Makefile b/Makefile index 66abc406..9b19a9a2 100644 --- a/Makefile +++ b/Makefile @@ -29,13 +29,16 @@ ct: ## make ct SUITE=some_test_SUITE,another_test_SUITE ## SUITE=some_test_SUITE make ct ## SUITE=some_test_SUITE,another_test_SUITE make ct - @ echo $(REBAR) ct --verbose $(SUITE_OPTS) - @ $(REBAR) ct --verbose $(SUITE_OPTS) + @ echo $(REBAR) ct -c --verbose $(SUITE_OPTS) + @ $(REBAR) ct -c --verbose $(SUITE_OPTS) lint: $(REBAR) as elvis lint -test: compile xref dialyzer ct lint +test: compile xref dialyzer ct lint codecov + +codecov: + $(REBAR) as test codecov analyze integration_test: ./integration_test/stop_test_cluster.sh diff --git a/README.md b/README.md index cd924be2..28e21efe 100644 --- a/README.md +++ b/README.md @@ -2,6 +2,7 @@ [![](https://github.com/esl/amoc/workflows/CI/badge.svg)](https://github.com/esl/amoc/actions?query=workflow%3ACI) [![Hex](http://img.shields.io/hexpm/v/amoc.svg)](https://hex.pm/packages/amoc) [![Hex Docs](https://img.shields.io/badge/hex-docs-lightgreen.svg)](https://hexdocs.pm/amoc/) +[![codecov](https://codecov.io/github/esl/amoc/graph/badge.svg?token=R1zXAjO7H7)](https://codecov.io/github/esl/amoc) ---------------------------------------------------------------------------------------------- A Murder of Crows, aka amoc, is a simple framework for running massively parallel tests in a distributed environment. diff --git a/rebar.config b/rebar.config index 2e123097..44819b56 100644 --- a/rebar.config +++ b/rebar.config @@ -9,6 +9,7 @@ {profiles, [ {test, [ + {plugins, [{rebar3_codecov, "0.6.0"}]}, {deps, [ {meck, "0.9.2"}, {proper, "1.4.0"},