mcp: fix several goroutine leaks in tests (#494)
Fix some (but not all) goroutine leaks in tests. Others were nontrivial, because they relate to streamable http. For #489.
This commit is contained in:
parent
49d45a8097
commit
1696b595c6
1 changed files with 43 additions and 22 deletions
|
|
@ -25,6 +25,7 @@ func TestBatchFraming(t *testing.T) {
|
|||
r, w := io.Pipe()
|
||||
tport := newIOConn(rwc{r, w})
|
||||
tport.outgoingBatch = make([]jsonrpc.Message, 0, 2)
|
||||
defer tport.Close()
|
||||
|
||||
// Read the two messages into a channel, for easy testing later.
|
||||
read := make(chan jsonrpc.Message)
|
||||
|
|
|
|||
Loading…
Reference in a new issue