Skip to content

Commit cb4061b

Browse files
committed
add lcov + ci on push
1 parent 20d2dd4 commit cb4061b

File tree

2 files changed

+31
-1
lines changed

2 files changed

+31
-1
lines changed

.github/workflows/ci-on-push.yml

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
name: Angular Build & Test (PR)
2+
3+
on:
4+
push:
5+
branches:
6+
- "**"
7+
8+
jobs:
9+
build-test:
10+
runs-on: ubuntu-latest
11+
steps:
12+
- name: Checkout repository
13+
uses: actions/checkout@v4
14+
- name: Set up Node
15+
uses: actions/setup-node@v4
16+
with:
17+
node-version: 22
18+
cache: 'npm'
19+
- name: Install dependencies
20+
run: npm ci
21+
- name: Build Angular library
22+
run: npx ng build ngx-flow
23+
- name: Run unit tests
24+
run: npx ng test ngx-flow --watch=false --browsers=ChromeHeadless --code-coverage
25+
- name: Send coverage to QLTY
26+
uses: qltysh/qlty-action/coverage@v2
27+
with:
28+
token: ${{secrets.QLTY_COVERAGE_TOKEN}}
29+
files: coverage/ngx-flow/lcov.info

karma.base.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,8 @@ module.exports = function (config, project) {
2929
subdir: '.',
3030
reporters: [
3131
{type: 'html'},
32-
{type: 'text-summary'}
32+
{type: 'text-summary'},
33+
{type: 'lcov'}
3334
]
3435
},
3536
specReporter: {

0 commit comments

Comments
 (0)