diff --git a/proto/tendermint/farming/v1beta1/proposal.proto b/proto/tendermint/farming/v1beta1/proposal.proto index b6dee06c..b7a679f3 100644 --- a/proto/tendermint/farming/v1beta1/proposal.proto +++ b/proto/tendermint/farming/v1beta1/proposal.proto @@ -1,6 +1,6 @@ syntax = "proto3"; -package tendermint.farming.v1beta1; +package cosmos.farming.v1beta1; import "gogoproto/gogo.proto"; import "cosmos_proto/cosmos.proto"; diff --git a/x/farming/client/testutil/cli_test.go b/x/farming/client/testutil/cli_test.go new file mode 100644 index 00000000..477bdb46 --- /dev/null +++ b/x/farming/client/testutil/cli_test.go @@ -0,0 +1,17 @@ +// +build norace + +package testutil + +import ( + "testing" + + "github.com/stretchr/testify/suite" +) + +func TestIntegrationTestSuite(t *testing.T) { + suite.Run(t, new(IntegrationTestSuite)) +} + +func TestQueryCmdTestSuite(t *testing.T) { + suite.Run(t, new(QueryCmdTestSuite)) +} diff --git a/x/farming/client/cli/cli_test.go b/x/farming/client/testutil/suite.go similarity index 61% rename from x/farming/client/cli/cli_test.go rename to x/farming/client/testutil/suite.go index 826272fb..8882c2a5 100644 --- a/x/farming/client/cli/cli_test.go +++ b/x/farming/client/testutil/suite.go @@ -1,13 +1,14 @@ -// +build norace - -package cli_test +package testutil import ( "fmt" - "testing" + "os" + "strconv" + "time" "github.com/gogo/protobuf/proto" "github.com/stretchr/testify/suite" + tmcli "github.com/tendermint/tendermint/libs/cli" tmdb "github.com/tendermint/tm-db" "github.com/cosmos/cosmos-sdk/client/flags" @@ -15,9 +16,11 @@ import ( clitestutil "github.com/cosmos/cosmos-sdk/testutil/cli" "github.com/cosmos/cosmos-sdk/testutil/network" sdk "github.com/cosmos/cosmos-sdk/types" + bankcli "github.com/cosmos/cosmos-sdk/x/bank/client/cli" "github.com/tendermint/farming/x/farming/client/cli" - farmingtestutil "github.com/tendermint/farming/x/farming/client/testutil" + farmingcli "github.com/tendermint/farming/x/farming/client/cli" + farmingkeeper "github.com/tendermint/farming/x/farming/keeper" "github.com/tendermint/farming/x/farming/types" farmingtypes "github.com/tendermint/farming/x/farming/types" ) @@ -37,7 +40,7 @@ func (s *IntegrationTestSuite) SetupTest() { s.T().Log("setting up integration test suite") db := tmdb.NewMemDB() - cfg := farmingtestutil.NewConfig(db) + cfg := NewConfig(db) cfg.NumValidators = 1 var genesisState farmingtypes.GenesisState @@ -62,11 +65,6 @@ func (s *IntegrationTestSuite) TearDownTest() { s.network.Cleanup() } -// TestIntegrationTestSuite every integration test suite. -func TestIntegrationTestSuite(t *testing.T) { - suite.Run(t, new(IntegrationTestSuite)) -} - func (s *IntegrationTestSuite) TestNewCreateFixedAmountPlanCmd() { val := s.network.Validators[0] @@ -456,7 +454,7 @@ func (s *IntegrationTestSuite) TestNewStakeCmd() { func (s *IntegrationTestSuite) TestNewUnstakeCmd() { val := s.network.Validators[0] - _, err := farmingtestutil.MsgStakeExec( + _, err := MsgStakeExec( val.ClientCtx, val.Address.String(), sdk.NewCoin("stake", sdk.NewInt(10_000_000)).String(), @@ -530,7 +528,7 @@ func (s *IntegrationTestSuite) TestNewHarvestCmd() { EpochAmount: sdk.NewCoins(sdk.NewInt64Coin("node0token", 100_000_000)), } - _, err := farmingtestutil.MsgCreateFixedAmountPlanExec( + _, err := MsgCreateFixedAmountPlanExec( val.ClientCtx, val.Address.String(), testutil.WriteToNewTempFile(s.T(), req.String()).Name(), @@ -538,7 +536,7 @@ func (s *IntegrationTestSuite) TestNewHarvestCmd() { s.Require().NoError(err) // stake coins - _, err = farmingtestutil.MsgStakeExec( + _, err = MsgStakeExec( val.ClientCtx, val.Address.String(), sdk.NewCoin("stake", sdk.NewInt(10_000_000)).String(), @@ -601,3 +599,498 @@ func (s *IntegrationTestSuite) TestNewHarvestCmd() { }) } } + +type QueryCmdTestSuite struct { + suite.Suite + + cfg network.Config + network *network.Network +} + +func (s *QueryCmdTestSuite) SetupSuite() { + s.T().Log("setting up integration test suite") + + db := tmdb.NewMemDB() + cfg := NewConfig(db) + cfg.NumValidators = 1 + + var genesisState farmingtypes.GenesisState + err := cfg.Codec.UnmarshalJSON(cfg.GenesisState[farmingtypes.ModuleName], &genesisState) + s.Require().NoError(err) + + genesisState.Params = farmingtypes.DefaultParams() + cfg.GenesisState[farmingtypes.ModuleName] = cfg.Codec.MustMarshalJSON(&genesisState) + cfg.AccountTokens = sdk.NewInt(100_000_000_000) // node0token denom + cfg.StakingTokens = sdk.NewInt(100_000_000_000) // stake denom + + s.cfg = cfg + s.network = network.New(s.T(), cfg) + + _, err = s.network.WaitForHeight(1) + s.Require().NoError(err) + + s.createFixedAmountPlan( + "test", + sdk.NewDecCoins(sdk.NewInt64DecCoin(sdk.DefaultBondDenom, 1)), + types.ParseTime("0001-01-01T00:00:00Z"), + types.ParseTime("9999-01-01T00:00:00Z"), + sdk.NewCoins(sdk.NewInt64Coin("node0token", 100_000_000)), + ) + s.fundFarmingPool(1, sdk.NewCoins(sdk.NewInt64Coin("node0token", 1_000_000_000))) + s.stake(sdk.NewCoins(sdk.NewInt64Coin(sdk.DefaultBondDenom, 1000000))) + s.advanceEpoch() + s.advanceEpoch() +} + +func (s *QueryCmdTestSuite) TearDownSuite() { + s.T().Log("tearing down integration test suite") + s.network.Cleanup() +} + +func (s *QueryCmdTestSuite) createFixedAmountPlan(name string, stakingCoinWeights sdk.DecCoins, startTime, endTime time.Time, epochAmount sdk.Coins) { + val := s.network.Validators[0] + clientCtx := val.ClientCtx + + req := cli.PrivateFixedPlanRequest{ + Name: name, + StakingCoinWeights: stakingCoinWeights, + StartTime: startTime, + EndTime: endTime, + EpochAmount: epochAmount, + } + file := testutil.WriteToNewTempFile(s.T(), req.String()) + defer os.Remove(file.Name()) + + args := append([]string{ + file.Name(), + fmt.Sprintf("--%s=%s", flags.FlagFrom, val.Address.String()), + }, commonArgs...) + + cmd := farmingcli.NewCreateFixedAmountPlanCmd() + + _, err := clitestutil.ExecTestCLICmd(clientCtx, cmd, args) + s.Require().NoError(err) +} + +func (s *QueryCmdTestSuite) fundFarmingPool(poolId uint64, amount sdk.Coins) { + val := s.network.Validators[0] + clientCtx := val.ClientCtx + types.RegisterInterfaces(clientCtx.InterfaceRegistry) + + cmd := farmingcli.GetCmdQueryPlan() + args := []string{ + strconv.FormatUint(poolId, 10), + fmt.Sprintf("--%s=json", tmcli.OutputFlag), + } + out, err := clitestutil.ExecTestCLICmd(clientCtx, cmd, args) + s.Require().NoError(err) + var resp types.QueryPlanResponse + clientCtx.Codec.MustUnmarshalJSON(out.Bytes(), &resp) + plan, err := types.UnpackPlan(resp.Plan) + s.Require().NoError(err) + + cmd = bankcli.NewSendTxCmd() + args = append([]string{ + val.Address.String(), + plan.GetFarmingPoolAddress().String(), + amount.String(), + }, commonArgs...) + _, err = clitestutil.ExecTestCLICmd(clientCtx, cmd, args) + s.Require().NoError(err) +} + +func (s *QueryCmdTestSuite) stake(amount sdk.Coins) { + val := s.network.Validators[0] + clientCtx := val.ClientCtx + + args := append([]string{ + amount.String(), + fmt.Sprintf("--%s=%s", flags.FlagFrom, val.Address.String()), + }, commonArgs...) + + cmd := farmingcli.NewStakeCmd() + + _, err := clitestutil.ExecTestCLICmd(clientCtx, cmd, args) + s.Require().NoError(err) +} + +func (s *QueryCmdTestSuite) advanceEpoch() { + farmingkeeper.EnableAdvanceEpoch = true + + val := s.network.Validators[0] + clientCtx := val.ClientCtx + + args := append([]string{ + fmt.Sprintf("--%s=%s", flags.FlagFrom, val.Address.String()), + }, commonArgs...) + + cmd := farmingcli.NewAdvanceEpochCmd() + + _, err := clitestutil.ExecTestCLICmd(clientCtx, cmd, args) + s.Require().NoError(err) +} + +func (s *QueryCmdTestSuite) TestCmdQueryParams() { + val := s.network.Validators[0] + clientCtx := val.ClientCtx + + testCases := []struct { + name string + args []string + expectErr bool + }{ + { + "happy case", + []string{fmt.Sprintf("--%s=json", tmcli.OutputFlag)}, + false, + }, + { + "with specific height", + []string{fmt.Sprintf("--%s=1", flags.FlagHeight), fmt.Sprintf("--%s=json", tmcli.OutputFlag)}, + false, + }, + } + + for _, tc := range testCases { + s.Run(tc.name, func() { + cmd := cli.GetCmdQueryParams() + + out, err := clitestutil.ExecTestCLICmd(clientCtx, cmd, tc.args) + if tc.expectErr { + s.Require().Error(err) + s.Require().NotEqual("internal", err.Error()) + } else { + s.Require().NoError(err) + + var params farmingtypes.Params + s.Require().NoError(clientCtx.Codec.UnmarshalJSON(out.Bytes(), ¶ms)) + s.Require().NotEmpty(params.FarmingFeeCollector) + } + }) + } +} + +func (s *QueryCmdTestSuite) TestCmdQueryPlans() { + val := s.network.Validators[0] + clientCtx := val.ClientCtx + types.RegisterInterfaces(clientCtx.InterfaceRegistry) + + testCases := []struct { + name string + args []string + expectErr bool + postRun func(*types.QueryPlansResponse) + }{ + { + "happy case", + []string{ + fmt.Sprintf("--%s=json", tmcli.OutputFlag), + }, + false, + func(resp *farmingtypes.QueryPlansResponse) { + plans, err := types.UnpackPlans(resp.Plans) + s.Require().NoError(err) + s.Require().Len(plans, 1) + s.Require().Equal(uint64(1), plans[0].GetId()) + }, + }, + { + "invalid plan type", + []string{ + fmt.Sprintf("--%s=%s", farmingcli.FlagPlanType, "invalid"), + fmt.Sprintf("--%s=json", tmcli.OutputFlag), + }, + true, + nil, + }, + { + "invalid farming pool addr", + []string{ + fmt.Sprintf("--%s=%s", farmingcli.FlagFarmingPoolAddr, "invalid"), + fmt.Sprintf("--%s=json", tmcli.OutputFlag), + }, + true, + nil, + }, + { + "invalid termination addr", + []string{ + fmt.Sprintf("--%s=%s", farmingcli.FlagTerminationAddr, "invalid"), + fmt.Sprintf("--%s=json", tmcli.OutputFlag), + }, + true, + nil, + }, + { + "invalid staking coin denom", + []string{ + fmt.Sprintf("--%s=%s", farmingcli.FlagStakingCoinDenom, "!"), + fmt.Sprintf("--%s=json", tmcli.OutputFlag), + }, + true, + nil, + }, + } + + for _, tc := range testCases { + s.Run(tc.name, func() { + cmd := cli.GetCmdQueryPlans() + + out, err := clitestutil.ExecTestCLICmd(clientCtx, cmd, tc.args) + if tc.expectErr { + s.Require().Error(err) + } else { + s.Require().NoError(err) + var resp types.QueryPlansResponse + s.Require().NoError(clientCtx.Codec.UnmarshalJSON(out.Bytes(), &resp), out.String()) + tc.postRun(&resp) + } + }) + } +} + +func (s *QueryCmdTestSuite) TestCmdQueryPlan() { + val := s.network.Validators[0] + clientCtx := val.ClientCtx + types.RegisterInterfaces(clientCtx.InterfaceRegistry) + + testCases := []struct { + name string + args []string + expectErr bool + postRun func(*types.QueryPlanResponse) + }{ + { + "happy case", + []string{ + strconv.Itoa(1), + fmt.Sprintf("--%s=json", tmcli.OutputFlag), + }, + false, + func(resp *farmingtypes.QueryPlanResponse) { + plan, err := types.UnpackPlan(resp.Plan) + s.Require().NoError(err) + s.Require().Equal(uint64(1), plan.GetId()) + }, + }, + { + "id not found", + []string{ + strconv.Itoa(10), + fmt.Sprintf("--%s=json", tmcli.OutputFlag), + }, + true, + nil, + }, + } + + for _, tc := range testCases { + s.Run(tc.name, func() { + cmd := cli.GetCmdQueryPlan() + + out, err := clitestutil.ExecTestCLICmd(clientCtx, cmd, tc.args) + if tc.expectErr { + s.Require().Error(err) + } else { + s.Require().NoError(err) + var resp types.QueryPlanResponse + s.Require().NoError(clientCtx.Codec.UnmarshalJSON(out.Bytes(), &resp), out.String()) + tc.postRun(&resp) + } + }) + } +} + +func (s *QueryCmdTestSuite) TestCmdQueryStakings() { + val := s.network.Validators[0] + clientCtx := val.ClientCtx + + testCases := []struct { + name string + args []string + expectErr bool + postRun func(*types.QueryStakingsResponse) + }{ + { + "happy case", + []string{ + val.Address.String(), + fmt.Sprintf("--%s=json", tmcli.OutputFlag), + }, + false, + func(resp *farmingtypes.QueryStakingsResponse) { + s.Require().True(coinsEq(sdk.NewCoins(sdk.NewInt64Coin(sdk.DefaultBondDenom, 1000000)), resp.StakedCoins)) + }, + }, + { + "invalid farmer addr", + []string{ + "invalid", + fmt.Sprintf("--%s=json", tmcli.OutputFlag), + }, + true, + nil, + }, + } + + for _, tc := range testCases { + s.Run(tc.name, func() { + cmd := cli.GetCmdQueryStakings() + + out, err := clitestutil.ExecTestCLICmd(clientCtx, cmd, tc.args) + if tc.expectErr { + s.Require().Error(err) + } else { + s.Require().NoError(err) + var resp types.QueryStakingsResponse + s.Require().NoError(clientCtx.Codec.UnmarshalJSON(out.Bytes(), &resp), out.String()) + tc.postRun(&resp) + } + }) + } +} + +func (s *QueryCmdTestSuite) TestCmdQueryTotalStakings() { + val := s.network.Validators[0] + clientCtx := val.ClientCtx + + testCases := []struct { + name string + args []string + expectErr bool + postRun func(*types.QueryTotalStakingsResponse) + }{ + { + "happy case", + []string{ + sdk.DefaultBondDenom, + fmt.Sprintf("--%s=json", tmcli.OutputFlag), + }, + false, + func(resp *farmingtypes.QueryTotalStakingsResponse) { + s.Require().True(intEq(sdk.NewInt(1000000), resp.Amount)) + }, + }, + { + "invalid staking coin denom", + []string{ + "!", + fmt.Sprintf("--%s=json", tmcli.OutputFlag), + }, + true, + nil, + }, + } + + for _, tc := range testCases { + s.Run(tc.name, func() { + cmd := cli.GetCmdQueryTotalStakings() + + out, err := clitestutil.ExecTestCLICmd(clientCtx, cmd, tc.args) + if tc.expectErr { + s.Require().Error(err) + } else { + s.Require().NoError(err) + var resp types.QueryTotalStakingsResponse + s.Require().NoError(clientCtx.Codec.UnmarshalJSON(out.Bytes(), &resp), out.String()) + tc.postRun(&resp) + } + }) + } +} + +func (s *QueryCmdTestSuite) TestCmdQueryRewards() { + val := s.network.Validators[0] + clientCtx := val.ClientCtx + + testCases := []struct { + name string + args []string + expectErr bool + postRun func(*types.QueryRewardsResponse) + }{ + { + "happy case", + []string{ + val.Address.String(), + fmt.Sprintf("--%s=json", tmcli.OutputFlag), + }, + false, + func(resp *farmingtypes.QueryRewardsResponse) { + s.Require().True(coinsEq(sdk.NewCoins(sdk.NewInt64Coin("node0token", 100_000_000)), resp.Rewards)) + }, + }, + { + "invalid farmer addr", + []string{ + "invalid", + fmt.Sprintf("--%s=json", tmcli.OutputFlag), + }, + true, + nil, + }, + } + + for _, tc := range testCases { + s.Run(tc.name, func() { + cmd := cli.GetCmdQueryRewards() + + out, err := clitestutil.ExecTestCLICmd(clientCtx, cmd, tc.args) + if tc.expectErr { + s.Require().Error(err) + } else { + s.Require().NoError(err) + var resp types.QueryRewardsResponse + s.Require().NoError(clientCtx.Codec.UnmarshalJSON(out.Bytes(), &resp), out.String()) + tc.postRun(&resp) + } + }) + } +} + +func (s *QueryCmdTestSuite) TestCmdQueryCurrentEpochDays() { + val := s.network.Validators[0] + clientCtx := val.ClientCtx + + testCases := []struct { + name string + args []string + expectErr bool + postRun func(*types.QueryCurrentEpochDaysResponse) + }{ + { + "happy case", + []string{ + fmt.Sprintf("--%s=json", tmcli.OutputFlag), + }, + false, + func(resp *farmingtypes.QueryCurrentEpochDaysResponse) { + s.Require().Equal(uint32(1), resp.CurrentEpochDays) + }, + }, + } + + for _, tc := range testCases { + s.Run(tc.name, func() { + cmd := cli.GetCmdQueryCurrentEpochDays() + + out, err := clitestutil.ExecTestCLICmd(clientCtx, cmd, tc.args) + if tc.expectErr { + s.Require().Error(err) + } else { + s.Require().NoError(err) + var resp types.QueryCurrentEpochDaysResponse + s.Require().NoError(clientCtx.Codec.UnmarshalJSON(out.Bytes(), &resp), out.String()) + tc.postRun(&resp) + } + }) + } +} + +func intEq(exp, got sdk.Int) (bool, string, string, string) { + return exp.Equal(got), "expected:\t%v\ngot:\t\t%v", exp.String(), got.String() +} + +func coinsEq(exp, got sdk.Coins) (bool, string, string, string) { + return exp.IsEqual(got), "expected:\t%v\ngot:\t\t%v", exp.String(), got.String() +} diff --git a/x/farming/types/codec.go b/x/farming/types/codec.go index 58439c78..be1f2b7c 100644 --- a/x/farming/types/codec.go +++ b/x/farming/types/codec.go @@ -34,7 +34,7 @@ func RegisterInterfaces(registry types.InterfaceRegistry) { ) registry.RegisterInterface( - "tendermint.farming.v1beta1.PlanI", + "cosmos.farming.v1beta1.PlanI", (*PlanI)(nil), &FixedAmountPlan{}, &RatioPlan{}, diff --git a/x/farming/types/plan_test.go b/x/farming/types/plan_test.go index d5df6133..de287b01 100644 --- a/x/farming/types/plan_test.go +++ b/x/farming/types/plan_test.go @@ -4,10 +4,10 @@ import ( "testing" "time" - "github.com/cosmos/cosmos-sdk/types/address" "github.com/stretchr/testify/require" sdk "github.com/cosmos/cosmos-sdk/types" + "github.com/cosmos/cosmos-sdk/types/address" sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" "github.com/tendermint/farming/x/farming/types" diff --git a/x/farming/types/proposal.pb.go b/x/farming/types/proposal.pb.go index 404ad278..cab0810c 100644 --- a/x/farming/types/proposal.pb.go +++ b/x/farming/types/proposal.pb.go @@ -343,10 +343,10 @@ func (m *DeleteRequestProposal) GetPlanId() uint64 { } func init() { - proto.RegisterType((*PublicPlanProposal)(nil), "tendermint.farming.v1beta1.PublicPlanProposal") - proto.RegisterType((*AddRequestProposal)(nil), "tendermint.farming.v1beta1.AddRequestProposal") - proto.RegisterType((*UpdateRequestProposal)(nil), "tendermint.farming.v1beta1.UpdateRequestProposal") - proto.RegisterType((*DeleteRequestProposal)(nil), "tendermint.farming.v1beta1.DeleteRequestProposal") + proto.RegisterType((*PublicPlanProposal)(nil), "cosmos.farming.v1beta1.PublicPlanProposal") + proto.RegisterType((*AddRequestProposal)(nil), "cosmos.farming.v1beta1.AddRequestProposal") + proto.RegisterType((*UpdateRequestProposal)(nil), "cosmos.farming.v1beta1.UpdateRequestProposal") + proto.RegisterType((*DeleteRequestProposal)(nil), "cosmos.farming.v1beta1.DeleteRequestProposal") } func init() { @@ -354,56 +354,56 @@ func init() { } var fileDescriptor_4719b03c30c7910a = []byte{ - // 773 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xcc, 0x56, 0x4f, 0x4f, 0xdb, 0x48, - 0x1c, 0x8d, 0xc9, 0x5f, 0x26, 0x2b, 0xad, 0x76, 0x08, 0x6c, 0x08, 0xac, 0x1d, 0x79, 0xa5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23, 0x00, 0x00, 0xff, 0xff, 0x06, 0x3e, 0x94, - 0x84, 0xaa, 0x09, 0x00, 0x00, + // 775 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xcc, 0x56, 0x3f, 0x6f, 0xdb, 0x38, + 0x1c, 0xb5, 0xe2, 0xbf, 0xa1, 0x0f, 0x38, 0x1c, 0xe3, 0xe4, 0x1c, 0x27, 0x27, 0x19, 0x3a, 0xe0, + 0xe0, 0xbb, 0x43, 0xa4, 0x26, 0xdd, 0xb2, 0xc5, 0x0d, 0x10, 0x74, 0xaa, 0x2b, 0xb4, 0x68, 0xd1, + 0x45, 0xa0, 0x4d, 0xc6, 0x11, 0x22, 0x89, 0xaa, 0x48, 0xb7, 0xcd, 0xd6, 0xa5, 0x40, 0x87, 0xa2, + 0xc8, 0xd8, 0x31, 0xe8, 0x98, 0x4f, 0x92, 0x31, 0x63, 0xd1, 0xc1, 0x29, 0x92, 0x6f, 0xe0, 0xa5, + 0x6b, 0x21, 0x92, 0x72, 0x8d, 0x46, 0x4e, 0x1d, 0x20, 0x05, 0x32, 0x89, 0x3f, 0xf2, 0xf7, 0x1e, + 0x9f, 0x1e, 0xf9, 0x6c, 0x81, 0x7f, 0x39, 0x09, 0x31, 0x89, 0x03, 0x2f, 0xe4, 0xf6, 0x2e, 0x4a, + 0x9e, 0x7d, 0xfb, 0xc5, 0x7a, 0x97, 0x70, 0xb4, 0x6e, 0x47, 0x31, 0x8d, 0x28, 0x43, 0xbe, 0x15, + 0xc5, 0x94, 0x53, 0xb8, 0xd4, 0xa3, 0x2c, 0xa0, 0xcc, 0x52, 0x6d, 0x96, 0x6a, 0x6b, 0xd4, 0xfa, + 0xb4, 0x4f, 0x45, 0x8b, 0x9d, 0x8c, 0x64, 0x77, 0x63, 0x59, 0x76, 0xbb, 0x72, 0x41, 0x41, 0xe5, + 0x92, 0x2e, 0x2b, 0xbb, 0x8b, 0x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e5, 0x0e, 0x58, 0xcc, 0xfc, 0x77, 0x9a, 0x9a, + 0x95, 0xf6, 0xce, 0xc9, 0xb9, 0xae, 0x9d, 0x9e, 0xeb, 0xda, 0x97, 0x73, 0x5d, 0x3b, 0xbc, 0xd0, + 0x73, 0xa7, 0x17, 0x7a, 0xee, 0xd3, 0x85, 0x9e, 0x7b, 0xb6, 0x36, 0xa1, 0x2a, 0xe3, 0xcb, 0xe6, + 0xd5, 0x78, 0x24, 0x04, 0x76, 0x4b, 0xe2, 0x8c, 0xee, 0x7e, 0x0b, 0x00, 0x00, 0xff, 0xff, 0x88, + 0x08, 0x21, 0xe4, 0x9a, 0x09, 0x00, 0x00, } func (m *PublicPlanProposal) Marshal() (dAtA []byte, err error) {