-
Notifications
You must be signed in to change notification settings - Fork 73
130 lines (113 loc) · 4.06 KB
/
Copy pathinterop.yml
File metadata and controls
130 lines (113 loc) · 4.06 KB
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
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
name: Interoperability Tests
on:
pull_request:
merge_group:
push:
branches:
- master
workflow_dispatch:
concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true
jobs:
run-transport-interop:
name: Run transport interoperability tests
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v6
- uses: docker/setup-buildx-action@v4
- name: Build image
run: docker build --load -t nim-libp2p-transport-head -f interop/transport/Dockerfile .
- name: Run tests
uses: libp2p/test-plans/.github/actions/run-transport-interop-test@master
with:
test-filter: nim-libp2p-transport-head
# without suffix action fails because "hole-punching-interop" artifacts have
# the same name as "transport-interop" artifacts
test-results-suffix: transport-interop
extra-versions: ${{ github.workspace }}/interop/transport/version.json
worker-count: 4
known-errors: "^(c-v0\\.0\\.1 x nim-libp2p-transport-head \\(quic-v1\\)|eth-p2p-z-v0\\.0\\.1 x nim-libp2p-transport-head \\(quic-v1\\))$"
run-hole-punching-interop:
name: Run hole punching interoperability tests
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v6
- uses: docker/setup-buildx-action@v4
- name: Build image
run: docker build --load -t nim-libp2p-hp-head -f interop/hole-punching/Dockerfile .
- name: Run tests
uses: libp2p/test-plans/.github/actions/run-interop-hole-punch-test@master
with:
test-filter: nim-libp2p-hp-head
extra-versions: ${{ github.workspace }}/interop/hole-punching/version.json
s3-cache-bucket: ${{ vars.S3_LIBP2P_BUILD_CACHE_BUCKET_NAME }}
s3-access-key-id: ${{ vars.S3_LIBP2P_BUILD_CACHE_AWS_ACCESS_KEY_ID }}
s3-secret-access-key: ${{ secrets.S3_LIBP2P_BUILD_CACHE_AWS_SECRET_ACCESS_KEY }}
aws-region: ${{ vars.S3_LIBP2P_BUILD_CACHE_AWS_REGION }}
run-autonatv2-interop:
name: Run AutoNATv2 interoperability tests
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v6
- name: Set up Go
uses: actions/setup-go@v6
with:
go-version: "1.25"
- name: Set up Nim
uses: jiro4989/setup-nim-action@v2
with:
nim-version: "stable"
- name: Run Go and Nim together
run: |
nimble install_pinned
nimble setup
cd interop/autonatv2/go-peer
go mod tidy
go run testautonatv2.go &
cd ../nim-peer
nim r src/nim_peer.nim $(cat ../go-peer/peer.id)
run-kad-interop:
name: Run Kademlia DHT interoperability tests
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v6
- name: Set up Rust
uses: dtolnay/rust-toolchain@stable
with:
toolchain: stable
- name: Set up Nim
uses: jiro4989/setup-nim-action@v2
with:
nim-version: "stable"
- name: Run Nim and Rust together
run: |
nimble install_pinned
nimble setup
cd interop/kad/rust-peer
cargo run &
cd ../nim-peer
nim r src/nim_peer.nim
run-partial-message-interop:
name: Run Partial Message interoperability tests
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v6
- name: Set up Go
uses: actions/setup-go@v6
with:
go-version: "1.25"
- name: Set up Nim
uses: jiro4989/setup-nim-action@v2
with:
nim-version: "stable"
# build go and nim clients first to prevent one from waiting on the other to finish building.
# the go peer runs in the background because the interop test logic is implemented in the nim peer.
- name: Run Interop
run: |
nimble install_pinned
nimble setup
cd interop/partial-message
nim c ./nim-peer/src/peer.nim
go build -C ./go-peer -o peer ./peer.go
./go-peer/peer & ./nim-peer/src/peer