Skip to content

Commit 2f13f30

Browse files
authored
implement bidirectional_stream (#2872)
* implement bidirectional_stream * fix * add network test * add network test with duration * add CI * fix test command
1 parent cb121b2 commit 2f13f30

File tree

5 files changed

+374
-2
lines changed

5 files changed

+374
-2
lines changed

.github/workflows/unit-test-rust.yaml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,6 +46,9 @@ jobs:
4646
- name: Set Git config
4747
run: |
4848
git config --global --add safe.directory ${GITHUB_WORKSPACE}
49-
- name: Run tests for Rust / gotestfmt
49+
- name: Run tests for qbg / gotestfmt
5050
run: |
5151
TEST_RESULT_DIR=${GITHUB_WORKSPACE} make test/rust/qbg
52+
- name: Run tests for agent / gotestfmt
53+
run: |
54+
TEST_RESULT_DIR=${GITHUB_WORKSPACE} make test/rust/agent

Makefile.d/test.mk

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -290,6 +290,12 @@ test/cmd:
290290
CGO_LDFLAGS="$(TEST_LDFLAGS)" \
291291
go test -short -shuffle=on -race -mod=readonly -cover $(ROOTDIR)/cmd/...
292292

293+
.PHONY: test/rust
294+
## run tests for rust
295+
test/rust: \
296+
test/rust/qbg \
297+
test/rust/agent
298+
293299
.PHONY: test/rust/qbg
294300
## run tests for qbg
295301
test/rust/qbg:
@@ -300,6 +306,11 @@ test/rust/qbg:
300306
cargo test --manifest-path rust/Cargo.toml --package qbg --lib -- tests::test_index --exact --show-output
301307
rm -rf rust/libs/algorithms/qbg/index/
302308

309+
.PHONY: test/rust/agent
310+
## run tests for agent
311+
test/rust/agent:
312+
cargo test --manifest-path rust/Cargo.toml --package agent -- handler::common::tests --show-output
313+
303314
.PHONY: test/hack
304315
## run tests for hack
305316
test/hack:

rust/Cargo.lock

Lines changed: 19 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

rust/bin/agent/Cargo.toml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,7 @@ anyhow = "1.0.95"
2727
cargo = "0.81.0"
2828
config = "0.14.0"
2929
flexi_logger = "0.29"
30+
futures = "0.3.31"
3031
log = "0.4"
3132
prost = "0.13.4"
3233
prost-types = "0.13.4"
@@ -35,3 +36,7 @@ tokio = { version = "1.43.0", features = ["full"] }
3536
tokio-stream = { version = "0.1.17", features = ["full"] }
3637
tonic = "0.12.3"
3738
tonic-types = "0.12.3"
39+
40+
[dev-dependencies]
41+
bytes = "1.10.0"
42+
http-body = "1.0.1"

0 commit comments

Comments
 (0)