Skip to content

Commit c404413

Browse files
committed
Use Primula for code coverage
1 parent 6980d44 commit c404413

4 files changed

Lines changed: 13 additions & 26 deletions

File tree

.coveragerc

Lines changed: 0 additions & 3 deletions
This file was deleted.

.github/workflows/ci.yml

Lines changed: 8 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -34,8 +34,6 @@ jobs:
3434
fail-fast: false
3535
name: Vim ${{ matrix.vim_version }} on ${{ matrix.platform }}
3636
runs-on: ${{ matrix.os }}
37-
env:
38-
PROFILE: profile.txt
3937
timeout-minutes: 10
4038
steps:
4139
- name: Checkout code
@@ -58,21 +56,22 @@ jobs:
5856
uses: actions/setup-python@v5
5957
with:
6058
python-version: 3.x
61-
- name: Install covimerage
59+
- name: Install Primula
6260
run: |
63-
python -m pip install -U pip setuptools wheel
64-
python -m pip install -U covimerage
61+
python -m pip install -U pip
62+
python -m pip install -U primula
6563
- name: Test
6664
env:
6765
THEMIS_VIM: ${{ steps.vim.outputs.executable }}
68-
run: ./vim-themis/bin/themis --reporter spec
69-
- name: Generate XML coverage report
7066
run: |
71-
covimerage write_coverage ${{ env.PROFILE }}
72-
covimerage xml
67+
primula run ./vim-themis/bin/themis --reporter spec
68+
primula report -m
69+
- name: Generate XML coverage report
70+
run: primula xml
7371
- name: Upload coverage to Codecov
7472
uses: codecov/codecov-action@v4
7573
with:
7674
token: ${{ secrets.CODECOV_TOKEN }}
7775
fail_ci_if_error: true
7876
flags: ${{ matrix.platform }}
77+
plugin: noop

.gitignore

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
*.html
22
*.sw?
3-
.coverage_*
3+
.coverage
44
profile.txt
5+
tags

Asterfile

Lines changed: 3 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,7 @@
11
var os = require('os');
22
var path = require('path');
33
var vimscript = require('language/vimscript');
4-
var themis = vimscript.themis;
5-
var covimerage = vimscript.covimerage;
4+
var primula = vimscript.primula;
65
var rst2html = require('language/restructuredtext').rst2html;
76

87
var title = 'Aster ☆ ' + path.basename(os.getwd());
@@ -11,17 +10,8 @@ aster.title(title);
1110

1211
// vim
1312
aster.watch(/.+\.(?:vim|vimspec|themisrc)$/, function() {
14-
var prof = 'profile.txt';
15-
var cover = os.whence('covimerage');
16-
if (cover) {
17-
os.setenv('PROFILE', prof);
18-
}
19-
20-
themis('--reporter', 'dot');
21-
if (cover) {
22-
covimerage.write_coverage(prof);
23-
covimerage.report();
24-
}
13+
primula.run('themis', '--reporter', 'dot');
14+
primula.report('-m');
2515
});
2616

2717
// rst

0 commit comments

Comments
 (0)