From 961cc04bdae4ab19cd2b13e17e7d10c9bf01506f Mon Sep 17 00:00:00 2001 From: Jim W Date: Fri, 6 Oct 2023 11:09:57 -0400 Subject: [PATCH] switch some exp pkg usage to stable (#10876) * change maps pkg from exp to stable where applicable * replace exp_rand with crypto_rand --- core/internal/features/ocr2/features_ocr2_test.go | 2 +- core/services/blockhashstore/test_util.go | 2 +- core/services/chainlink/config_general_test.go | 3 +-- core/services/ocr2/plugins/s4/integration_test.go | 2 +- 4 files changed, 4 insertions(+), 5 deletions(-) diff --git a/core/internal/features/ocr2/features_ocr2_test.go b/core/internal/features/ocr2/features_ocr2_test.go index 3883e0319ed..0a6192c99c3 100644 --- a/core/internal/features/ocr2/features_ocr2_test.go +++ b/core/internal/features/ocr2/features_ocr2_test.go @@ -5,6 +5,7 @@ import ( "encoding/json" "fmt" "io" + "maps" "math/big" "net/http" "net/http/httptest" @@ -26,7 +27,6 @@ import ( "github.com/smartcontractkit/libocr/gethwrappers2/ocr2aggregator" "github.com/stretchr/testify/assert" "github.com/stretchr/testify/require" - "golang.org/x/exp/maps" testoffchainaggregator2 "github.com/smartcontractkit/libocr/gethwrappers2/testocr2aggregator" confighelper2 "github.com/smartcontractkit/libocr/offchainreporting2plus/confighelper" diff --git a/core/services/blockhashstore/test_util.go b/core/services/blockhashstore/test_util.go index 6b7c3836650..0ab07931295 100644 --- a/core/services/blockhashstore/test_util.go +++ b/core/services/blockhashstore/test_util.go @@ -2,11 +2,11 @@ package blockhashstore import ( "context" + "crypto/rand" "math/big" "github.com/ethereum/go-ethereum/common" "github.com/pkg/errors" - "golang.org/x/exp/rand" ) type TestCoordinator struct { diff --git a/core/services/chainlink/config_general_test.go b/core/services/chainlink/config_general_test.go index 8e95e389ffc..46931e53e2b 100644 --- a/core/services/chainlink/config_general_test.go +++ b/core/services/chainlink/config_general_test.go @@ -5,13 +5,12 @@ package chainlink import ( _ "embed" "fmt" + "maps" "net/url" "strings" "testing" "time" - maps "golang.org/x/exp/maps" - "github.com/stretchr/testify/assert" "github.com/stretchr/testify/require" diff --git a/core/services/ocr2/plugins/s4/integration_test.go b/core/services/ocr2/plugins/s4/integration_test.go index 01b269e2c85..98ccd312e4b 100644 --- a/core/services/ocr2/plugins/s4/integration_test.go +++ b/core/services/ocr2/plugins/s4/integration_test.go @@ -4,6 +4,7 @@ import ( "context" "crypto/ecdsa" "fmt" + "maps" "math/rand" "testing" "time" @@ -26,7 +27,6 @@ import ( "github.com/stretchr/testify/assert" "github.com/stretchr/testify/require" "go.uber.org/multierr" - "golang.org/x/exp/maps" ) // Disclaimer: this is not a true integration test, it's more of a S4 feature test, on purpose.