forked from soldair/node-qrcode
-
Notifications
You must be signed in to change notification settings - Fork 0
47 lines (36 loc) · 971 Bytes
/
tests.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
47
name: tests
on:
push:
pull_request:
jobs:
qrcode-cli:
runs-on: ubuntu-latest
strategy:
matrix:
node: [ 18, 20, 22 ]
fail-fast: false
steps:
- name: checkout
uses: actions/checkout@v4
- name: setup node
uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node }}
- name: install canvas dependencies
run: |
sudo apt-get update
sudo apt-get install build-essential libcairo2-dev libpango1.0-dev libjpeg-dev libgif-dev librsvg2-dev
- name: npm ci
run: npm ci
- name: npm link
run: npm link
- name: qrcode terminal output
run: qrcode "Lorem ipsum."
- name: qrcode PNG output
run: qrcode --output qrcode.png "Lorem ipsum."
- name: upload artifact
uses: actions/upload-artifact@v4
with:
name: qrcode-cli_tests_nodejs_${{ matrix.node }}
path: 'qrcode.png'
compression-level: 0