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
+4 -1
View File
@@ -7,12 +7,15 @@ import (
"testing"
"github.com/cosmos/cosmos-sdk/testutil/network"
"github.com/cosmos/cosmos-sdk/x/group/testutil"
"github.com/stretchr/testify/require"
"github.com/stretchr/testify/suite"
)
func TestIntegrationTestSuite(t *testing.T) {
cfg := network.DefaultConfig()
cfg, err := network.DefaultConfigWithAppConfig(testutil.AppConfig)
require.NoError(t, err)
cfg.NumValidators = 2
suite.Run(t, NewIntegrationTestSuite(cfg))
}
+49
View File
@@ -0,0 +1,49 @@
modules:
- name: runtime
config:
"@type": cosmos.app.runtime.v1alpha1.Module
app_name: GroupApp
begin_blockers: [staking, auth, bank, genutil, authz, group, params]
end_blockers: [staking, auth, bank, genutil, authz, group, params]
init_genesis: [auth, bank, staking, genutil, authz, group, params]
- name: auth
config:
"@type": cosmos.auth.module.v1.Module
bech32_prefix: cosmos
module_account_permissions:
- account: fee_collector
- account: bonded_tokens_pool
permissions: [burner, staking]
- account: not_bonded_tokens_pool
permissions: [burner, staking]
- name: bank
config:
"@type": cosmos.bank.module.v1.Module
- name: params
config:
"@type": cosmos.params.module.v1.Module
- name: tx
config:
"@type": cosmos.tx.module.v1.Module
- name: staking
config:
"@type": cosmos.staking.module.v1.Module
- name: authz
config:
"@type": cosmos.authz.module.v1.Module
- name: group
config:
"@type": cosmos.group.v1.module.v1.Module
- name: genutil
config:
"@type": cosmos.genutil.module.v1.Module
+20
View File
@@ -0,0 +1,20 @@
package testutil
import (
_ "embed"
"cosmossdk.io/core/appconfig"
_ "github.com/cosmos/cosmos-sdk/x/auth"
_ "github.com/cosmos/cosmos-sdk/x/auth/tx/module"
_ "github.com/cosmos/cosmos-sdk/x/authz"
_ "github.com/cosmos/cosmos-sdk/x/bank"
_ "github.com/cosmos/cosmos-sdk/x/genutil"
_ "github.com/cosmos/cosmos-sdk/x/group"
_ "github.com/cosmos/cosmos-sdk/x/params"
_ "github.com/cosmos/cosmos-sdk/x/staking"
)
//go:embed app.yaml
var appConfig []byte
var AppConfig = appconfig.LoadYAML(appConfig)