Skip to content

Commit

Permalink
ci: adds publish to coveralls.io
Browse files Browse the repository at this point in the history
  • Loading branch information
Vladislav Grubov committed Sep 13, 2023
1 parent d047a6a commit 2568efb
Show file tree
Hide file tree
Showing 2 changed files with 27 additions and 8 deletions.
31 changes: 23 additions & 8 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,19 +28,34 @@ jobs:
- uses: docker/setup-buildx-action@v2
- name: run test suite for ${{matrix.version}}
run: make test-${{matrix.version}}
- name: rename luacov.stats.out
run: mv luacov.stats.out luacov.stats.out-${{matrix.version}}
- uses: actions/upload-artifact@master
with:
name: luacov.stats.out
path: luacov.stats.out-${{matrix.version}}
run-coverage-report:
runs-on: ubuntu-latest
needs: ["run-unit-tests"]
steps:
- uses: actions/checkout@master
- uses: tarantool/setup-tarantool@v2
with:
tarantool-version: '2.10.7'
- name: install luacov-console 1.1.0
run: tarantoolctl rocks install luacov-console 1.1.0
- name: install luacov-coveralls 0.2.3
run: tarantoolctl rocks install --server=http://luarocks.org luacov-coveralls 0.2.3
run: tarantoolctl rocks install --server=https://luarocks.org luacov-coveralls 0.2.3
- name: install luacov-console 1.2.0
run: tarantoolctl rocks --server http://moonlibs.github.io/rocks install luacov-console 1.2.0
- uses: actions/download-artifact@master
with:
name: luacov.stats.out
- name: debug
run: ls -la .
- name: merge luacov.stats.out
run: cat luacov.stats.out-* | >luacov.stats.out tarantool -e 'm={} for k in io.lines() do local vs=io.read():split(" ") vs[#vs]=nil local r = m[k] if r then for i, v in pairs(vs) do r[i]=r[i]+v end else m[k]=vs end end; for k, v in pairs(m) do print(k) print(table.concat(v, " ")) end'
- name: prepare coverage report
run: .rocks/bin/luacov-console "$(pwd)" && .rocks/bin/luacov-console -s
# - name: publish coveralls report
# env:
# COVERALLS_REPO_TOKEN: ${{ secrets.COVERALLS_REPO_TOKEN }}
# run: .rocks/bin/luacov-coveralls -v
run: .rocks/bin/luacov-console . && .rocks/bin/luacov-console -s
- name: publish coveralls report
env:
COVERALLS_REPO_TOKEN: ${{ secrets.COVERALLS_REPO_TOKEN }}
run: .rocks/bin/luacov-coveralls -v
4 changes: 4 additions & 0 deletions .luacov
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,10 @@ exclude = {
"builtin/",
}

pathcorrect = {
{ "^/source/config/", "" },
}

coveralls = {
root = "/",
debug = true,
Expand Down

0 comments on commit 2568efb

Please sign in to comment.