Skip to content

Commit

Permalink
test: make #18472 test structure same as backports
Browse files Browse the repository at this point in the history
  • Loading branch information
julienrbrt committed Nov 17, 2023
1 parent 80e0c63 commit f9a6a34
Show file tree
Hide file tree
Showing 4 changed files with 22 additions and 24 deletions.
21 changes: 18 additions & 3 deletions client/tx/aux_builder_test.go
Original file line number Diff line number Diff line change
@@ -1,10 +1,11 @@
package tx
package tx_test

import (
"testing"

"github.com/stretchr/testify/require"

"github.com/cosmos/cosmos-sdk/client/tx"
"github.com/cosmos/cosmos-sdk/codec"
codectypes "github.com/cosmos/cosmos-sdk/codec/types"
cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types"
Expand All @@ -14,6 +15,20 @@ import (
typestx "github.com/cosmos/cosmos-sdk/types/tx"
"github.com/cosmos/cosmos-sdk/types/tx/signing"
"github.com/cosmos/cosmos-sdk/x/counter"
countertypes "github.com/cosmos/cosmos-sdk/x/counter/types"
)

const (
memo = "waboom"
timeoutHeight = uint64(5)
)

var (
_, pub1, addr1 = testdata.KeyTestPubAddr()
rawSig = []byte("dummy")
msg1 = &countertypes.MsgIncreaseCounter{Signer: addr1.String(), Count: 1}

chainID = "test-chain"
)

func TestAuxTxBuilder(t *testing.T) {
Expand All @@ -25,7 +40,7 @@ func TestAuxTxBuilder(t *testing.T) {
// required for test case: "GetAuxSignerData works for DIRECT_AUX"
counterModule.RegisterInterfaces(reg)

var b AuxTxBuilder
var b tx.AuxTxBuilder

testcases := []struct {
name string
Expand Down Expand Up @@ -199,7 +214,7 @@ func TestAuxTxBuilder(t *testing.T) {
for _, tc := range testcases {
tc := tc
t.Run(tc.name, func(t *testing.T) {
b = NewAuxTxBuilder()
b = tx.NewAuxTxBuilder()
err := tc.malleate()

if tc.expErr {
Expand Down
20 changes: 0 additions & 20 deletions client/tx/legacy_test.go

This file was deleted.

2 changes: 2 additions & 0 deletions client/tx/tx_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -369,6 +369,8 @@ func TestSign(t *testing.T) {
}

func TestPreprocessHook(t *testing.T) {
_, _, addr2 := testdata.KeyTestPubAddr()

txConfig, cdc := newTestTxConfig()
requireT := require.New(t)
path := hd.CreateHDPath(118, 0, 0).String()
Expand Down
3 changes: 2 additions & 1 deletion tools/confix/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,8 +31,9 @@ Ref: https://keepachangelog.com/en/1.0.0/

## [Unreleased]

* []() Remove invalid non SDK config from app.toml migration templates.
* [#18496](https://github.com/cosmos/cosmos-sdk/pull/18496) Remove invalid non SDK config from app.toml migration templates.


## [v0.1.0](https://github.com/cosmos/cosmos-sdk/releases/tag/tools/confix/v0.1.0) - 2023-11-07

* [#17904](https://github.com/cosmos/cosmos-sdk/pull/17904) Add `view` command.
Expand Down

0 comments on commit f9a6a34

Please sign in to comment.