Skip to content

Commit

Permalink
ci: add code coverage back (#292)
Browse files Browse the repository at this point in the history
  • Loading branch information
linrongbin16 authored Nov 22, 2024
1 parent 1252fba commit de86ff3
Show file tree
Hide file tree
Showing 2 changed files with 25 additions and 25 deletions.
48 changes: 24 additions & 24 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -92,33 +92,33 @@ jobs:
if: ${{ !startsWith(matrix.os, 'windows') }}
- uses: notomo/action-setup-nvim-lua@v1
if: ${{ startsWith(matrix.os, 'windows') }}
- name: Run Test Cases
run: |
luarocks --lua-version=5.1 install vusted
vusted ./spec
# - name: Run Test Cases
# run: |
# luarocks install luacov
# luarocks install luacov-reporter-lcov
# luarocks --lua-version=5.1 install vusted
# vusted --coverage ./spec
# echo "ls -l ."
# ls -l .
# - name: Check Coverage Reports
# if: ${{ !startsWith(matrix.os, 'windows') }}
# run: |
# echo "luacov -r lcov"
# luacov -r lcov
# echo "ls -la ."
# ls -la .
# echo "tail ./luacov.report.out"
# tail -n 50 ./luacov.report.out
# - uses: codecov/codecov-action@v4
# if: ${{ !startsWith(matrix.os, 'windows') }}
# with:
# files: luacov.report.out
# env:
# CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
# vusted ./spec
- name: Run Test Cases
run: |
luarocks install luacov
luarocks install luacov-reporter-lcov
luarocks --lua-version=5.1 install vusted
vusted --coverage ./spec
echo "ls -l ."
ls -l .
- name: Check Coverage Reports
if: ${{ !startsWith(matrix.os, 'windows') }}
run: |
echo "luacov -r lcov"
luacov -r lcov
echo "ls -la ."
ls -la .
echo "tail ./luacov.report.out"
tail -n 50 ./luacov.report.out
- uses: codecov/codecov-action@v4
if: ${{ !startsWith(matrix.os, 'windows') }}
with:
files: luacov.report.out
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
release:
name: Release
if: ${{ github.ref == 'refs/heads/main' }}
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<a href="https://github.com/neovim/neovim/releases/"><img alt="require" src="https://img.shields.io/badge/require-stable-blue" /></a>
<a href="https://luarocks.org/modules/linrongbin16/commons.nvim"><img alt="luarocks" src="https://img.shields.io/luarocks/v/linrongbin16/commons.nvim" /></a>
<a href="https://github.com/linrongbin16/commons.nvim/actions/workflows/ci.yml"><img alt="ci.yml" src="https://img.shields.io/github/actions/workflow/status/linrongbin16/commons.nvim/ci.yml?label=ci" /></a>
<!-- <a href="https://app.codecov.io/github/linrongbin16/commons.nvim"><img alt="codecov" src="https://img.shields.io/codecov/c/github/linrongbin16/commons.nvim/main?label=codecov" /></a> -->
<a href="https://app.codecov.io/github/linrongbin16/commons.nvim"><img alt="codecov" src="https://img.shields.io/codecov/c/github/linrongbin16/commons.nvim/main?label=codecov" /></a>
</p>

<p align="center"><i>
Expand Down

0 comments on commit de86ff3

Please sign in to comment.