-
Notifications
You must be signed in to change notification settings - Fork 21
46 lines (36 loc) · 1022 Bytes
/
test.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
name: Automate the collection of coverage
on:
push:
branches:
- main
pull_request:
types:
- opened
- synchronize
- reopened
jobs:
test:
name: Collection of coverage
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v3
- name: Setup Deno runtime
uses: denoland/setup-deno@v1
with:
deno-version: v1.28.2
- name: Check format
run: deno fmt --check
- name: Do lint
run: deno lint
- name: Check type
run: deno check $(find . -regex '.*\.\(js\|ts\|jsx\|tsx\|mjs\|mjsx\)' -printf '%p ')
- name: Test and collect coverage
run: deno test -A --coverage=tests/coverage
- name: Create coverage report
run: deno coverage ./tests/coverage --lcov > tests/coverage.lcov
- name: Upload to codecov
uses: codecov/[email protected]
with:
file: ./tests/coverage.lcov
fail_ci_if_error: true