feat: add x/group app wiring integration tests (#12243)

## Description

ref: #12024 



---

### Author Checklist

*All items are required. Please add a note to the item if the item is not applicable and
please add links to any relevant follow up issues.*

I have...

- [ ] included the correct [type prefix](https://github.com/commitizen/conventional-commit-types/blob/v3.0.0/index.json) in the PR title
- [ ] added `!` to the type prefix if API or client breaking change
- [ ] targeted the correct branch (see [PR Targeting](https://github.com/cosmos/cosmos-sdk/blob/main/CONTRIBUTING.md#pr-targeting))
- [ ] provided a link to the relevant issue or specification
- [ ] followed the guidelines for [building modules](https://github.com/cosmos/cosmos-sdk/blob/main/docs/building-modules)
- [ ] included the necessary unit and integration [tests](https://github.com/cosmos/cosmos-sdk/blob/main/CONTRIBUTING.md#testing)
- [ ] added a changelog entry to `CHANGELOG.md`
- [ ] included comments for [documenting Go code](https://blog.golang.org/godoc)
- [ ] updated the relevant documentation or specification
- [ ] reviewed "Files changed" and left comments if necessary
- [ ] confirmed all CI checks have passed

### Reviewers Checklist

*All items are required. Please add a note if the item is not applicable and please add
your handle next to the items reviewed if you only reviewed selected items.*

I have...

- [ ] confirmed the correct [type prefix](https://github.com/commitizen/conventional-commit-types/blob/v3.0.0/index.json) in the PR title
- [ ] confirmed `!` in the type prefix if API or client breaking change
- [ ] confirmed all author checklist items have been addressed 
- [ ] reviewed state machine logic
- [ ] reviewed API design and naming
- [ ] reviewed documentation is accurate
- [ ] reviewed tests and test coverage
- [ ] manually tested (if applicable)
This commit is contained in:
likhita-809
2022-06-15 05:31:27 +00:00
committed by GitHub
parent d705a8bc8f
commit bfb91ab7bc
9 changed files with 92 additions and 18 deletions
+1
View File
@@ -45,6 +45,7 @@ type App struct {
beginBlockers []func(sdk.Context, abci.RequestBeginBlock)
endBlockers []func(sdk.Context, abci.RequestEndBlock) []abci.ValidatorUpdate
baseAppOptions []BaseAppOption
msgServiceRouter *baseapp.MsgServiceRouter
}
// RegisterModules registers the provided modules with the module manager and
+1 -2
View File
@@ -29,7 +29,6 @@ func (a *AppBuilder) Build(
logger log.Logger,
db dbm.DB,
traceStore io.Writer,
msgServiceRouter *baseapp.MsgServiceRouter,
baseAppOptions ...func(*baseapp.BaseApp),
) *App {
for _, option := range a.app.baseAppOptions {
@@ -37,7 +36,7 @@ func (a *AppBuilder) Build(
}
bApp := baseapp.NewBaseApp(a.app.config.AppName, logger, db, nil, baseAppOptions...)
bApp.SetMsgServiceRouter(msgServiceRouter)
bApp.SetMsgServiceRouter(a.app.msgServiceRouter)
bApp.SetCommitMultiStoreTracer(traceStore)
bApp.SetVersion(version.Version)
bApp.SetInterfaceRegistry(a.app.interfaceRegistry)
+5 -2
View File
@@ -3,6 +3,8 @@ package runtime
import (
"fmt"
abci "github.com/tendermint/tendermint/abci/types"
runtimev1alpha1 "cosmossdk.io/api/cosmos/app/runtime/v1alpha1"
"cosmossdk.io/core/appmodule"
"github.com/cosmos/cosmos-sdk/baseapp"
@@ -12,7 +14,6 @@ import (
"github.com/cosmos/cosmos-sdk/std"
storetypes "github.com/cosmos/cosmos-sdk/store/types"
"github.com/cosmos/cosmos-sdk/types/module"
abci "github.com/tendermint/tendermint/abci/types"
)
// BaseAppOption is a depinject.AutoGroupType which can be used to pass
@@ -62,15 +63,17 @@ func provideCodecs(moduleBasics map[string]AppModuleBasicWrapper) (
std.RegisterLegacyAminoCodec(amino)
cdc := codec.NewProtoCodec(interfaceRegistry)
msgServiceRouter := baseapp.NewMsgServiceRouter()
app := &App{
storeKeys: nil,
interfaceRegistry: interfaceRegistry,
cdc: cdc,
amino: amino,
basicManager: basicManager,
msgServiceRouter: msgServiceRouter,
}
return interfaceRegistry, cdc, amino, app, cdc, baseapp.NewMsgServiceRouter()
return interfaceRegistry, cdc, amino, app, cdc, msgServiceRouter
}
type appInputs struct {