Skip to content

Commit

Permalink
add test coverage for pipelining with groups
Browse files Browse the repository at this point in the history
  • Loading branch information
dwrensha committed Nov 22, 2022
1 parent 8f1cad4 commit 8ead5d3
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 1 deletion.
4 changes: 4 additions & 0 deletions capnp-rpc/test/test.capnp
Original file line number Diff line number Diff line change
Expand Up @@ -102,6 +102,10 @@ interface TestPipeline {

struct Box {
cap @0 :TestInterface;

foo :group {
capInGroup @1 :TestInterface;
}
}
}

Expand Down
4 changes: 4 additions & 0 deletions capnp-rpc/test/test.rs
Original file line number Diff line number Diff line change
Expand Up @@ -286,6 +286,10 @@ fn basic_pipelining() {

let promise = request.send();

// This is just here to check that code generation for pipelines
// inside of groups works correctly.
let _ = promise.pipeline.get_out_box().get_foo().get_cap_in_group();

let mut pipeline_request = promise.pipeline.get_out_box().get_cap().foo_request();
pipeline_request.get().set_i(321);
let pipeline_promise = pipeline_request.send();
Expand Down
2 changes: 1 addition & 1 deletion capnpc/test/test.capnp
Original file line number Diff line number Diff line change
Expand Up @@ -803,4 +803,4 @@ struct Issue260(T, Q) {
val1 @2 :Q;
val2 @3 :Int8;
}
}
}

0 comments on commit 8ead5d3

Please sign in to comment.