mirror of
https://github.com/planetmint/planetmint-go.git
synced 2025-06-06 22:26:43 +00:00
Merge pull request #29 from planetmint/jmastr/fix-some-code-smells
Fix some code smells
This commit is contained in:
commit
141dde5cb4
@ -117,7 +117,9 @@ func (am AppModule) RegisterServices(cfg module.Configurator) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// RegisterInvariants registers the invariants of the module. If an invariant deviates from its predicted value, the InvariantRegistry triggers appropriate logic (most often the chain will be halted)
|
// RegisterInvariants registers the invariants of the module. If an invariant deviates from its predicted value, the InvariantRegistry triggers appropriate logic (most often the chain will be halted)
|
||||||
func (am AppModule) RegisterInvariants(_ sdk.InvariantRegistry) {}
|
func (am AppModule) RegisterInvariants(_ sdk.InvariantRegistry) {
|
||||||
|
// Implement if needed
|
||||||
|
}
|
||||||
|
|
||||||
// InitGenesis performs the module's genesis initialization. It returns no validator updates.
|
// InitGenesis performs the module's genesis initialization. It returns no validator updates.
|
||||||
func (am AppModule) InitGenesis(ctx sdk.Context, cdc codec.JSONCodec, gs json.RawMessage) []abci.ValidatorUpdate {
|
func (am AppModule) InitGenesis(ctx sdk.Context, cdc codec.JSONCodec, gs json.RawMessage) []abci.ValidatorUpdate {
|
||||||
@ -140,7 +142,9 @@ func (am AppModule) ExportGenesis(ctx sdk.Context, cdc codec.JSONCodec) json.Raw
|
|||||||
func (AppModule) ConsensusVersion() uint64 { return 1 }
|
func (AppModule) ConsensusVersion() uint64 { return 1 }
|
||||||
|
|
||||||
// BeginBlock contains the logic that is automatically triggered at the beginning of each block
|
// BeginBlock contains the logic that is automatically triggered at the beginning of each block
|
||||||
func (am AppModule) BeginBlock(_ sdk.Context, _ abci.RequestBeginBlock) {}
|
func (am AppModule) BeginBlock(_ sdk.Context, _ abci.RequestBeginBlock) {
|
||||||
|
// Implement if needed
|
||||||
|
}
|
||||||
|
|
||||||
// EndBlock contains the logic that is automatically triggered at the end of each block
|
// EndBlock contains the logic that is automatically triggered at the end of each block
|
||||||
func (am AppModule) EndBlock(_ sdk.Context, _ abci.RequestEndBlock) []abci.ValidatorUpdate {
|
func (am AppModule) EndBlock(_ sdk.Context, _ abci.RequestEndBlock) []abci.ValidatorUpdate {
|
||||||
|
@ -44,7 +44,9 @@ func (AppModule) GenerateGenesisState(simState *module.SimulationState) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// RegisterStoreDecoder registers a decoder.
|
// RegisterStoreDecoder registers a decoder.
|
||||||
func (am AppModule) RegisterStoreDecoder(_ sdk.StoreDecoderRegistry) {}
|
func (am AppModule) RegisterStoreDecoder(_ sdk.StoreDecoderRegistry) {
|
||||||
|
// Implement if needed
|
||||||
|
}
|
||||||
|
|
||||||
// ProposalContents doesn't return any content functions for governance proposals.
|
// ProposalContents doesn't return any content functions for governance proposals.
|
||||||
func (AppModule) ProposalContents(_ module.SimulationState) []simtypes.WeightedProposalContent {
|
func (AppModule) ProposalContents(_ module.SimulationState) []simtypes.WeightedProposalContent {
|
||||||
|
@ -117,7 +117,9 @@ func (am AppModule) RegisterServices(cfg module.Configurator) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// RegisterInvariants registers the invariants of the module. If an invariant deviates from its predicted value, the InvariantRegistry triggers appropriate logic (most often the chain will be halted)
|
// RegisterInvariants registers the invariants of the module. If an invariant deviates from its predicted value, the InvariantRegistry triggers appropriate logic (most often the chain will be halted)
|
||||||
func (am AppModule) RegisterInvariants(_ sdk.InvariantRegistry) {}
|
func (am AppModule) RegisterInvariants(_ sdk.InvariantRegistry) {
|
||||||
|
// Implement if needed
|
||||||
|
}
|
||||||
|
|
||||||
// InitGenesis performs the module's genesis initialization. It returns no validator updates.
|
// InitGenesis performs the module's genesis initialization. It returns no validator updates.
|
||||||
func (am AppModule) InitGenesis(ctx sdk.Context, cdc codec.JSONCodec, gs json.RawMessage) []abci.ValidatorUpdate {
|
func (am AppModule) InitGenesis(ctx sdk.Context, cdc codec.JSONCodec, gs json.RawMessage) []abci.ValidatorUpdate {
|
||||||
@ -140,7 +142,9 @@ func (am AppModule) ExportGenesis(ctx sdk.Context, cdc codec.JSONCodec) json.Raw
|
|||||||
func (AppModule) ConsensusVersion() uint64 { return 1 }
|
func (AppModule) ConsensusVersion() uint64 { return 1 }
|
||||||
|
|
||||||
// BeginBlock contains the logic that is automatically triggered at the beginning of each block
|
// BeginBlock contains the logic that is automatically triggered at the beginning of each block
|
||||||
func (am AppModule) BeginBlock(_ sdk.Context, _ abci.RequestBeginBlock) {}
|
func (am AppModule) BeginBlock(_ sdk.Context, _ abci.RequestBeginBlock) {
|
||||||
|
// Implement if needed
|
||||||
|
}
|
||||||
|
|
||||||
// EndBlock contains the logic that is automatically triggered at the end of each block
|
// EndBlock contains the logic that is automatically triggered at the end of each block
|
||||||
func (am AppModule) EndBlock(_ sdk.Context, _ abci.RequestEndBlock) []abci.ValidatorUpdate {
|
func (am AppModule) EndBlock(_ sdk.Context, _ abci.RequestEndBlock) []abci.ValidatorUpdate {
|
||||||
|
@ -44,7 +44,9 @@ func (AppModule) GenerateGenesisState(simState *module.SimulationState) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// RegisterStoreDecoder registers a decoder.
|
// RegisterStoreDecoder registers a decoder.
|
||||||
func (am AppModule) RegisterStoreDecoder(_ sdk.StoreDecoderRegistry) {}
|
func (am AppModule) RegisterStoreDecoder(_ sdk.StoreDecoderRegistry) {
|
||||||
|
// Implement if needed
|
||||||
|
}
|
||||||
|
|
||||||
// ProposalContents doesn't return any content functions for governance proposals.
|
// ProposalContents doesn't return any content functions for governance proposals.
|
||||||
func (AppModule) ProposalContents(_ module.SimulationState) []simtypes.WeightedProposalContent {
|
func (AppModule) ProposalContents(_ module.SimulationState) []simtypes.WeightedProposalContent {
|
||||||
|
@ -7,7 +7,7 @@ import (
|
|||||||
"github.com/stretchr/testify/require"
|
"github.com/stretchr/testify/require"
|
||||||
)
|
)
|
||||||
|
|
||||||
func TestMsgAttestMachine_ValidateBasic(t *testing.T) {
|
func TestMsgAttestMachineValidateBasic(t *testing.T) {
|
||||||
tests := []struct {
|
tests := []struct {
|
||||||
name string
|
name string
|
||||||
msg MsgAttestMachine
|
msg MsgAttestMachine
|
||||||
|
Loading…
x
Reference in New Issue
Block a user