-
Notifications
You must be signed in to change notification settings - Fork 7
59 lines (56 loc) · 2.15 KB
/
ci.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
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
name: "CI"
on:
push:
branches:
pull_request:
jobs:
"node-test":
name: "Build and test on Node.js"
runs-on: ubuntu-latest
steps:
- name: "Checkout this repo"
uses: actions/checkout@v3
- name: "Setup Node.js"
uses: actions/setup-node@v3
with:
node-version: "18.x"
cache: "npm"
- name: "Install npm dependencies"
run: "npm ci"
- name: "Checkout hrana-test-server"
uses: actions/checkout@v3
with:
repository: "libsql/hrana-test-server"
path: "hrana-test-server"
- name: "Setup Python"
uses: actions/setup-python@v4
with:
python-version: "3.10"
cache: "pip"
- name: "Install pip dependencies"
run: "pip install -r hrana-test-server/requirements.txt"
- name: "Build"
run: "npm run build"
- name: "Test version 1 over WebSocket"
run: "python hrana-test-server/server_v1.py npm test"
env: {"VERSION": "1", "URL": "ws://localhost:8080"}
- name: "Test version 2 over WebSocket"
run: "python hrana-test-server/server_v2.py npm test"
env: {"VERSION": "2", "URL": "ws://localhost:8080"}
- name: "Test version 2 over HTTP"
run: "python hrana-test-server/server_v2.py npm test"
env: {"VERSION": "2", "URL": "http://localhost:8080"}
- name: "Test version 3 over WebSocket and JSON"
run: "python hrana-test-server/server_v3.py npm test"
env: {"VERSION": "3", "URL": "ws://localhost:8080", "ENCODING": "json"}
- name: "Test version 3 over WebSocket and Protobuf"
run: "python hrana-test-server/server_v3.py npm test"
env: {"VERSION": "3", "URL": "ws://localhost:8080", "ENCODING": "protobuf"}
- name: "Test version 3 over HTTP and JSON"
run: "python hrana-test-server/server_v3.py npm test"
env: {"VERSION": "3", "URL": "http://localhost:8080", "ENCODING": "json"}
- name: "Test version 3 over HTTP and Protobuf"
run: "python hrana-test-server/server_v3.py npm test"
env: {"VERSION": "3", "URL": "http://localhost:8080", "ENCODING": "protobuf"}
- name: "Example"
run: "python hrana-test-server/server_v3.py node examples/readme_example.js"