diff --git a/login/login_test.go b/login/login_test.go index 1ce9416..3125880 100644 --- a/login/login_test.go +++ b/login/login_test.go @@ -63,8 +63,9 @@ func sendAndRecv(peer *cnet.Peer, recv chan *cnet.PacketEvent, is *is.I, sID, rI // receive response evnt := <-recv - is.Equal(evnt.PktID, rID) // should receive expected type + defer protocol.PutBuffer(evnt.Pkt) + is.Equal(evnt.PktID, rID) // should receive expected type is.NoErr(protocol.NewPacket(evnt.Pkt).Decode(in)) // packet.Decode() should not return an error }