frostfs-api-go/reputation/message_test.go
Leonard Lyubich 25da5d2e13 Add v2 version to go module name
Replace all elements from `v2` to root directory.

Signed-off-by: Leonard Lyubich <leonard@nspcc.ru>
2021-11-17 15:29:33 +03:00

34 lines
1.5 KiB
Go

package reputation_test
import (
"testing"
reputationtest "github.com/nspcc-dev/neofs-api-go/v2/reputation/test"
"github.com/nspcc-dev/neofs-api-go/v2/rpc/message"
messagetest "github.com/nspcc-dev/neofs-api-go/v2/rpc/message/test"
)
func TestMessageConvert(t *testing.T) {
messagetest.TestRPCMessage(t,
func(empty bool) message.Message { return reputationtest.GenerateTrust(empty) },
func(empty bool) message.Message { return reputationtest.GenerateAnnounceLocalTrustRequestBody(empty) },
func(empty bool) message.Message { return reputationtest.GenerateAnnounceLocalTrustRequest(empty) },
func(empty bool) message.Message { return reputationtest.GenerateAnnounceLocalTrustResponseBody(empty) },
func(empty bool) message.Message { return reputationtest.GenerateAnnounceLocalTrustResponse(empty) },
func(empty bool) message.Message {
return reputationtest.GenerateAnnounceIntermediateResultRequestBody(empty)
},
func(empty bool) message.Message {
return reputationtest.GenerateAnnounceIntermediateResultRequest(empty)
},
func(empty bool) message.Message {
return reputationtest.GenerateAnnounceIntermediateResultResponseBody(empty)
},
func(empty bool) message.Message {
return reputationtest.GenerateAnnounceIntermediateResultResponse(empty)
},
func(empty bool) message.Message { return reputationtest.GenerateGlobalTrustBody(empty) },
func(empty bool) message.Message { return reputationtest.GenerateGlobalTrust(empty) },
func(empty bool) message.Message { return reputationtest.GeneratePeerToPeerTrust(empty) },
)
}