-
Notifications
You must be signed in to change notification settings - Fork 68
40 lines (40 loc) · 1.38 KB
/
testing.yaml
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
name: testing
on:
pull_request:
branches:
- main
jobs:
test:
name: Node ${{ matrix.node_version }} - ${{ matrix.architecture }} on ${{ matrix.os }}
runs-on: ${{ matrix.os }}
strategy:
matrix:
os:
- ubuntu-22.04
node_version:
- 14
- 16
- 18
architecture:
- x64
steps:
- uses: actions/checkout@v3
- uses: pnpm/action-setup@v2
with:
version: latest
- uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node_version }}
check-latest: true
architecture: ${{ matrix.architecture }}
- run: docker compose up -d
- run: docker compose exec -T cluster-1_master-1 redis-cli --cluster create 127.0.0.1:16380 127.0.0.1:16381 127.0.0.1:16382 --cluster-yes
- run: docker compose exec -T cluster-2_master-1 redis-cli --cluster create 127.0.0.1:16480 127.0.0.1:16481 127.0.0.1:16482 --cluster-yes
- run: pnpm install --frozen-lockfile
- run: pnpm -F "@liaoliaots/nestjs-redis" lint
- run: pnpm -F "@liaoliaots/nestjs-redis" test
- run: pnpm -F "@liaoliaots/nestjs-redis" test:e2e
- run: pnpm -F "@liaoliaots/nestjs-redis-health" lint
- run: pnpm -F "@liaoliaots/nestjs-redis-health" test
- run: pnpm -F "@liaoliaots/nestjs-redis-health" test:e2e
- run: docker compose down -v