30 lines
675 B
Go
30 lines
675 B
Go
|
package cosmostest_test
|
||
|
|
||
|
import (
|
||
|
"testing"
|
||
|
|
||
|
keepertest "cosmos-test/testutil/keeper"
|
||
|
"cosmos-test/testutil/nullify"
|
||
|
"cosmos-test/x/cosmostest"
|
||
|
"cosmos-test/x/cosmostest/types"
|
||
|
"github.com/stretchr/testify/require"
|
||
|
)
|
||
|
|
||
|
func TestGenesis(t *testing.T) {
|
||
|
genesisState := types.GenesisState{
|
||
|
Params: types.DefaultParams(),
|
||
|
|
||
|
// this line is used by starport scaffolding # genesis/test/state
|
||
|
}
|
||
|
|
||
|
k, ctx := keepertest.CosmostestKeeper(t)
|
||
|
cosmostest.InitGenesis(ctx, *k, genesisState)
|
||
|
got := cosmostest.ExportGenesis(ctx, *k)
|
||
|
require.NotNil(t, got)
|
||
|
|
||
|
nullify.Fill(&genesisState)
|
||
|
nullify.Fill(got)
|
||
|
|
||
|
// this line is used by starport scaffolding # genesis/test/assert
|
||
|
}
|