Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(v50): proto annotation for cosmos msg service #383

Open
wants to merge 2 commits into
base: release/v0.4.x
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 9 additions & 0 deletions app/app_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,10 @@ import (

"cosmossdk.io/log"
db "github.com/cosmos/cosmos-db"
"github.com/cosmos/cosmos-sdk/types/msgservice"
authtypes "github.com/cosmos/cosmos-sdk/x/auth/types"
govtypes "github.com/cosmos/cosmos-sdk/x/gov/types"
"github.com/cosmos/gogoproto/proto"
"github.com/stretchr/testify/require"
)

Expand Down Expand Up @@ -34,3 +36,10 @@ func TestGetMaccPerms(t *testing.T) {
dup := GetMaccPerms()
require.Equal(t, maccPerms, dup, "duplicated module account permissions differed from actual module account permissions")
}

func TestProtoAnnotations(t *testing.T) {
r, err := proto.MergedRegistry()
require.NoError(t, err)
err = msgservice.ValidateProtoAnnotations(r)
require.NoError(t, err)
}
2 changes: 2 additions & 0 deletions proto/alliance/alliance/tx.proto
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@ import "amino/amino.proto";
option go_package = "github.com/terra-money/alliance/x/alliance/types";

service Msg {
option (cosmos.msg.v1.service) = true;

rpc Delegate(MsgDelegate) returns (MsgDelegateResponse);
rpc Redelegate(MsgRedelegate) returns(MsgRedelegateResponse);
rpc Undelegate(MsgUndelegate) returns(MsgUndelegateResponse);
Expand Down
1 change: 1 addition & 0 deletions x/alliance/types/query.pb.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

131 changes: 66 additions & 65 deletions x/alliance/types/tx.pb.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.