From d5fc0e0e9e6a176ab33e069b402659c7c632a67b Mon Sep 17 00:00:00 2001 From: Lukasz Klimek <842586+lklimek@users.noreply.github.com> Date: Thu, 2 Dec 2021 10:38:19 +0100 Subject: [PATCH] refactor(dash/types): rename package dashtypes to types --- abci/example/kvstore/helpers.go | 2 +- dash/quorum/mock/mock_switch.go | 2 +- dash/quorum/mock/test_helpers.go | 2 +- dash/quorum/validator_conn_executor_test.go | 2 +- dash/{dashtypes => types}/nodeid_resolver.go | 2 +- dash/{dashtypes => types}/validator_address.go | 2 +- dash/{dashtypes => types}/validator_address_test.go | 2 +- node/node_test.go | 2 +- state/execution.go | 2 +- state/execution_test.go | 2 +- state/state_test.go | 2 +- test/e2e/tests/validator_test.go | 2 +- types/protobuf.go | 2 +- types/protobuf_test.go | 2 +- types/validator.go | 2 +- types/validator_set.go | 2 +- 16 files changed, 16 insertions(+), 16 deletions(-) rename dash/{dashtypes => types}/nodeid_resolver.go (98%) rename dash/{dashtypes => types}/validator_address.go (99%) rename dash/{dashtypes => types}/validator_address_test.go (98%) diff --git a/abci/example/kvstore/helpers.go b/abci/example/kvstore/helpers.go index d9ce769090..068e8ffa62 100644 --- a/abci/example/kvstore/helpers.go +++ b/abci/example/kvstore/helpers.go @@ -5,7 +5,7 @@ import ( "github.com/tendermint/tendermint/crypto" "github.com/tendermint/tendermint/crypto/bls12381" cryptoenc "github.com/tendermint/tendermint/crypto/encoding" - "github.com/tendermint/tendermint/dash/dashtypes" + dashtypes "github.com/tendermint/tendermint/dash/types" ) func ValUpdate( diff --git a/dash/quorum/mock/mock_switch.go b/dash/quorum/mock/mock_switch.go index 9bec5f47f8..e3ff892b9e 100644 --- a/dash/quorum/mock/mock_switch.go +++ b/dash/quorum/mock/mock_switch.go @@ -5,7 +5,7 @@ import ( "strings" "time" - "github.com/tendermint/tendermint/dash/dashtypes" + dashtypes "github.com/tendermint/tendermint/dash/types" "github.com/tendermint/tendermint/p2p" "github.com/tendermint/tendermint/p2p/mocks" ) diff --git a/dash/quorum/mock/test_helpers.go b/dash/quorum/mock/test_helpers.go index 21beb83080..fcd1654191 100644 --- a/dash/quorum/mock/test_helpers.go +++ b/dash/quorum/mock/test_helpers.go @@ -6,7 +6,7 @@ import ( "math" "github.com/tendermint/tendermint/crypto" - "github.com/tendermint/tendermint/dash/dashtypes" + dashtypes "github.com/tendermint/tendermint/dash/types" "github.com/tendermint/tendermint/libs/bytes" "github.com/tendermint/tendermint/types" ) diff --git a/dash/quorum/validator_conn_executor_test.go b/dash/quorum/validator_conn_executor_test.go index 0a55f709b2..c973ffc788 100644 --- a/dash/quorum/validator_conn_executor_test.go +++ b/dash/quorum/validator_conn_executor_test.go @@ -10,9 +10,9 @@ import ( "github.com/stretchr/testify/require" abci "github.com/tendermint/tendermint/abci/types" "github.com/tendermint/tendermint/crypto" - "github.com/tendermint/tendermint/dash/dashtypes" "github.com/tendermint/tendermint/dash/quorum/mock" "github.com/tendermint/tendermint/dash/quorum/selectpeers" + dashtypes "github.com/tendermint/tendermint/dash/types" tmbytes "github.com/tendermint/tendermint/libs/bytes" "github.com/tendermint/tendermint/libs/log" mmock "github.com/tendermint/tendermint/mempool/mock" diff --git a/dash/dashtypes/nodeid_resolver.go b/dash/types/nodeid_resolver.go similarity index 98% rename from dash/dashtypes/nodeid_resolver.go rename to dash/types/nodeid_resolver.go index 9157145a6e..2633e29a30 100644 --- a/dash/dashtypes/nodeid_resolver.go +++ b/dash/types/nodeid_resolver.go @@ -1,4 +1,4 @@ -package dashtypes +package types import ( "fmt" diff --git a/dash/dashtypes/validator_address.go b/dash/types/validator_address.go similarity index 99% rename from dash/dashtypes/validator_address.go rename to dash/types/validator_address.go index 7025544606..497389b670 100644 --- a/dash/dashtypes/validator_address.go +++ b/dash/types/validator_address.go @@ -1,4 +1,4 @@ -package dashtypes +package types import ( "errors" diff --git a/dash/dashtypes/validator_address_test.go b/dash/types/validator_address_test.go similarity index 98% rename from dash/dashtypes/validator_address_test.go rename to dash/types/validator_address_test.go index 315117eb0c..e14c02cff3 100644 --- a/dash/dashtypes/validator_address_test.go +++ b/dash/types/validator_address_test.go @@ -1,4 +1,4 @@ -package dashtypes +package types import ( "testing" diff --git a/node/node_test.go b/node/node_test.go index 2f3981fef1..378cb3fa95 100644 --- a/node/node_test.go +++ b/node/node_test.go @@ -10,7 +10,7 @@ import ( "time" "github.com/tendermint/tendermint/crypto" - "github.com/tendermint/tendermint/dash/dashtypes" + dashtypes "github.com/tendermint/tendermint/dash/types" "github.com/stretchr/testify/assert" "github.com/stretchr/testify/require" diff --git a/state/execution.go b/state/execution.go index f83671f7c7..38f749c482 100644 --- a/state/execution.go +++ b/state/execution.go @@ -7,7 +7,7 @@ import ( "time" "github.com/tendermint/tendermint/crypto/bls12381" - "github.com/tendermint/tendermint/dash/dashtypes" + dashtypes "github.com/tendermint/tendermint/dash/types" abci "github.com/tendermint/tendermint/abci/types" "github.com/tendermint/tendermint/crypto" diff --git a/state/execution_test.go b/state/execution_test.go index d1633a1534..4126a3f8d7 100644 --- a/state/execution_test.go +++ b/state/execution_test.go @@ -8,7 +8,7 @@ import ( "github.com/tendermint/tendermint/crypto" "github.com/tendermint/tendermint/crypto/bls12381" - "github.com/tendermint/tendermint/dash/dashtypes" + dashtypes "github.com/tendermint/tendermint/dash/types" "github.com/stretchr/testify/assert" "github.com/stretchr/testify/mock" diff --git a/state/state_test.go b/state/state_test.go index 5fd1169111..3a840271ee 100644 --- a/state/state_test.go +++ b/state/state_test.go @@ -16,7 +16,7 @@ import ( "github.com/tendermint/tendermint/crypto" "github.com/tendermint/tendermint/crypto/bls12381" cryptoenc "github.com/tendermint/tendermint/crypto/encoding" - "github.com/tendermint/tendermint/dash/dashtypes" + dashtypes "github.com/tendermint/tendermint/dash/types" tmrand "github.com/tendermint/tendermint/libs/rand" tmstate "github.com/tendermint/tendermint/proto/tendermint/state" tmproto "github.com/tendermint/tendermint/proto/tendermint/types" diff --git a/test/e2e/tests/validator_test.go b/test/e2e/tests/validator_test.go index d32fe41dd7..4017caa055 100644 --- a/test/e2e/tests/validator_test.go +++ b/test/e2e/tests/validator_test.go @@ -7,7 +7,7 @@ import ( "github.com/dashevo/dashd-go/btcjson" "github.com/tendermint/tendermint/crypto" - "github.com/tendermint/tendermint/dash/dashtypes" + dashtypes "github.com/tendermint/tendermint/dash/types" "github.com/stretchr/testify/require" diff --git a/types/protobuf.go b/types/protobuf.go index a19ca40c8f..1a84183fdf 100644 --- a/types/protobuf.go +++ b/types/protobuf.go @@ -5,7 +5,7 @@ import ( "github.com/tendermint/tendermint/crypto" "github.com/tendermint/tendermint/crypto/bls12381" - "github.com/tendermint/tendermint/dash/dashtypes" + dashtypes "github.com/tendermint/tendermint/dash/types" abci "github.com/tendermint/tendermint/abci/types" "github.com/tendermint/tendermint/crypto/ed25519" diff --git a/types/protobuf_test.go b/types/protobuf_test.go index 593bd4c41a..0eb275861e 100644 --- a/types/protobuf_test.go +++ b/types/protobuf_test.go @@ -6,7 +6,7 @@ import ( "github.com/dashevo/dashd-go/btcjson" "github.com/tendermint/tendermint/crypto/bls12381" - "github.com/tendermint/tendermint/dash/dashtypes" + dashtypes "github.com/tendermint/tendermint/dash/types" "github.com/stretchr/testify/assert" "github.com/stretchr/testify/require" diff --git a/types/validator.go b/types/validator.go index 1b4aff7c6d..4ed0d7bd47 100644 --- a/types/validator.go +++ b/types/validator.go @@ -9,7 +9,7 @@ import ( "github.com/tendermint/tendermint/crypto" "github.com/tendermint/tendermint/crypto/bls12381" ce "github.com/tendermint/tendermint/crypto/encoding" - "github.com/tendermint/tendermint/dash/dashtypes" + dashtypes "github.com/tendermint/tendermint/dash/types" tmproto "github.com/tendermint/tendermint/proto/tendermint/types" ) diff --git a/types/validator_set.go b/types/validator_set.go index 2e0bc40bae..501a2ec815 100644 --- a/types/validator_set.go +++ b/types/validator_set.go @@ -15,7 +15,7 @@ import ( "github.com/tendermint/tendermint/crypto/bls12381" cryptoenc "github.com/tendermint/tendermint/crypto/encoding" "github.com/tendermint/tendermint/crypto/merkle" - "github.com/tendermint/tendermint/dash/dashtypes" + dashtypes "github.com/tendermint/tendermint/dash/types" tmproto "github.com/tendermint/tendermint/proto/tendermint/types" )