1
0
mirror of https://github.com/go-micro/go-micro.git synced 2024-12-24 10:07:04 +02:00

add local/remote to testsocket

This commit is contained in:
Asim Aslam 2018-11-14 19:45:46 +00:00
parent 71bacf6991
commit c6a2c8de6c

View File

@ -15,6 +15,8 @@ type testCodec struct {
}
type testSocket struct {
local string
remote string
}
// TestCodecWriteError simulates what happens when a codec is unable
@ -87,6 +89,14 @@ func (c *testCodec) String() string {
return "string"
}
func (s testSocket) Local() string {
return s.local
}
func (s testSocket) Remote() string {
return s.remote
}
func (s testSocket) Recv(message *transport.Message) error {
return nil
}