From 7e7054f47ed2c5124ea4a08417204bbb9c6d41d8 Mon Sep 17 00:00:00 2001 From: Jack Zampolin Date: Thu, 5 Dec 2024 20:36:38 -0800 Subject: [PATCH] fix naming for gtbuilder and gtnetwork --- gturbine/{builder => gtbuilder}/helpers.go | 4 ++-- gturbine/{builder => gtbuilder}/helpers_test.go | 2 +- gturbine/{builder => gtbuilder}/tree.go | 2 +- gturbine/{builder => gtbuilder}/tree_test.go | 2 +- gturbine/{network => gtnetwork}/transport.go | 4 ++-- gturbine/{network => gtnetwork}/transport_test.go | 4 ++-- gturbine/turbine_test.go | 6 +++--- 7 files changed, 12 insertions(+), 12 deletions(-) rename gturbine/{builder => gtbuilder}/helpers.go (98%) rename gturbine/{builder => gtbuilder}/helpers_test.go (99%) rename gturbine/{builder => gtbuilder}/tree.go (99%) rename gturbine/{builder => gtbuilder}/tree_test.go (99%) rename gturbine/{network => gtnetwork}/transport.go (99%) rename gturbine/{network => gtnetwork}/transport_test.go (99%) diff --git a/gturbine/builder/helpers.go b/gturbine/gtbuilder/helpers.go similarity index 98% rename from gturbine/builder/helpers.go rename to gturbine/gtbuilder/helpers.go index af4b091..b2f4a18 100644 --- a/gturbine/builder/helpers.go +++ b/gturbine/gtbuilder/helpers.go @@ -1,4 +1,4 @@ -package builder +package gtbuilder import ( "bytes" @@ -50,4 +50,4 @@ func GetChildren(tree *gturbine.Tree, pubKey []byte) []tmconsensus.Validator { } return childLayer.Validators[startIdx:endIdx] -} \ No newline at end of file +} diff --git a/gturbine/builder/helpers_test.go b/gturbine/gtbuilder/helpers_test.go similarity index 99% rename from gturbine/builder/helpers_test.go rename to gturbine/gtbuilder/helpers_test.go index f821a1a..cc25430 100644 --- a/gturbine/builder/helpers_test.go +++ b/gturbine/gtbuilder/helpers_test.go @@ -1,4 +1,4 @@ -package builder +package gtbuilder import ( "bytes" diff --git a/gturbine/builder/tree.go b/gturbine/gtbuilder/tree.go similarity index 99% rename from gturbine/builder/tree.go rename to gturbine/gtbuilder/tree.go index 0894568..0283717 100644 --- a/gturbine/builder/tree.go +++ b/gturbine/gtbuilder/tree.go @@ -1,4 +1,4 @@ -package builder +package gtbuilder import ( "crypto/sha256" diff --git a/gturbine/builder/tree_test.go b/gturbine/gtbuilder/tree_test.go similarity index 99% rename from gturbine/builder/tree_test.go rename to gturbine/gtbuilder/tree_test.go index b5c9f7d..e001061 100644 --- a/gturbine/builder/tree_test.go +++ b/gturbine/gtbuilder/tree_test.go @@ -1,4 +1,4 @@ -package builder +package gtbuilder import ( "bytes" diff --git a/gturbine/network/transport.go b/gturbine/gtnetwork/transport.go similarity index 99% rename from gturbine/network/transport.go rename to gturbine/gtnetwork/transport.go index aeac48e..62ad834 100644 --- a/gturbine/network/transport.go +++ b/gturbine/gtnetwork/transport.go @@ -1,4 +1,4 @@ -package network +package gtnetwork import ( "context" @@ -135,4 +135,4 @@ func (t *Transport) close() { l.Close() } t.listeners = nil -} \ No newline at end of file +} diff --git a/gturbine/network/transport_test.go b/gturbine/gtnetwork/transport_test.go similarity index 99% rename from gturbine/network/transport_test.go rename to gturbine/gtnetwork/transport_test.go index c090b66..df2f8bb 100644 --- a/gturbine/network/transport_test.go +++ b/gturbine/gtnetwork/transport_test.go @@ -1,4 +1,4 @@ -package network +package gtnetwork import ( "net" @@ -102,4 +102,4 @@ func TestMultipleHandlers(t *testing.T) { } h.mu.Unlock() } -} \ No newline at end of file +} diff --git a/gturbine/turbine_test.go b/gturbine/turbine_test.go index 8ba35b6..93efe64 100644 --- a/gturbine/turbine_test.go +++ b/gturbine/turbine_test.go @@ -9,12 +9,12 @@ import ( "time" "github.com/gordian-engine/gordian/gturbine/gtencoding" + "github.com/gordian-engine/gordian/gturbine/gtnetwork" "github.com/gordian-engine/gordian/gturbine/gtshredding" - "github.com/gordian-engine/gordian/gturbine/network" ) type testNode struct { - transport *network.Transport + transport *gtnetwork.Transport processor *gtshredding.Processor codec gtencoding.ShardCodec shredHandler *testShredHandler @@ -58,7 +58,7 @@ func (h *testBlockHandler) ProcessBlock(height uint64, blockHash []byte, block [ func newTestNode(t *testing.T, basePort int) *testNode { encoder := gtencoding.NewBinaryShardCodec() - transport := network.NewTransport(network.Config{ + transport := gtnetwork.NewTransport(gtnetwork.Config{ BasePort: basePort, NumPorts: 10, })