Skip to content

Commit b269d88

Browse files
miaobyteclaude
andcommitted
ci: 并行测试 shm/fs/redis 三后端
原 ci 仅用 shm 跑 tutorial。改为 matrix 并行 job(test-shm/test-fs/ test-redis),各自 KVSPACE DSN 独立;redis job 起 redis:7 service。 fail-fast: false,单后端失败不影响其他后端诊断。 Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
1 parent 7cabf55 commit b269d88

1 file changed

Lines changed: 18 additions & 3 deletions

File tree

.github/workflows/ci.yml

Lines changed: 18 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,23 @@
11
name: ci
22
on: [push, pull_request, repository_dispatch]
33
jobs:
4-
build:
4+
test:
55
runs-on: ubuntu-latest
6+
name: test-${{ matrix.backend.name }}
7+
strategy:
8+
fail-fast: false
9+
matrix:
10+
backend:
11+
- { name: shm, dsn: "shm:///tmp/kvlang_ci_shm.shm" }
12+
- { name: fs, dsn: "fs:///tmp/kvlang_ci_fs" }
13+
- { name: redis, dsn: "redis://127.0.0.1:6379" }
14+
services:
15+
redis:
16+
image: redis:7
17+
ports: ["6379:6379"]
18+
options: >-
19+
--health-cmd "redis-cli ping"
20+
--health-interval 5s --health-timeout 3s --health-retries 10
621
steps:
722
- uses: actions/checkout@v4
823
- name: 下载 ABI 依赖
@@ -15,6 +30,6 @@ jobs:
1530
sudo cp layout/target/release/libkvlanglayout.so /usr/lib/
1631
make runtime-rs
1732
sudo make install
18-
- name: 测试
19-
env: { KVSPACE: "shm:///tmp/kvlang_ci" }
33+
- name: 测试 (${{ matrix.backend.name }})
34+
env: { KVSPACE: "${{ matrix.backend.dsn }}" }
2035
run: python3 tutorial/test.py

0 commit comments

Comments
 (0)