From deb247d98dd064d477949088891c8211d6e9ed3f Mon Sep 17 00:00:00 2001 From: Suyash Kumar Date: Tue, 14 May 2024 09:10:07 -0700 Subject: [PATCH] Move testhelpers out of internal. PiperOrigin-RevId: 633605426 --- bulkfhir/transactiontime_test.go | 2 +- cmd/bulk_fhir_fetch/bulk_fhir_fetch_test.go | 2 +- fhir/processing/bcdarectify_test.go | 2 +- fhir/processing/documents_test.go | 2 +- fhir/processing/fhirstoresink_test.go | 2 +- fhir/processing/ndjsonsink_test.go | 2 +- fhir/rectify_test.go | 2 +- fhirstore/fhirstore_test.go | 2 +- gcs/gcs_test.go | 2 +- internal/logger/logger_test.go | 2 +- internal/logger/loggerredirect_test/logger_redirect_test.go | 2 +- {internal/testhelpers => testhelpers}/fhirstore.go | 0 {internal/testhelpers => testhelpers}/gcs.go | 0 {internal/testhelpers => testhelpers}/json.go | 0 {internal/testhelpers => testhelpers}/logserver.go | 0 15 files changed, 11 insertions(+), 11 deletions(-) rename {internal/testhelpers => testhelpers}/fhirstore.go (100%) rename {internal/testhelpers => testhelpers}/gcs.go (100%) rename {internal/testhelpers => testhelpers}/json.go (100%) rename {internal/testhelpers => testhelpers}/logserver.go (100%) diff --git a/bulkfhir/transactiontime_test.go b/bulkfhir/transactiontime_test.go index 5b6bdb3..2db8f90 100644 --- a/bulkfhir/transactiontime_test.go +++ b/bulkfhir/transactiontime_test.go @@ -22,7 +22,7 @@ import ( "time" "github.com/google/go-cmp/cmp" - "github.com/google/bulk_fhir_tools/internal/testhelpers" + "github.com/google/bulk_fhir_tools/testhelpers" ) func TestInMemoryTransactionTimeStore(t *testing.T) { diff --git a/cmd/bulk_fhir_fetch/bulk_fhir_fetch_test.go b/cmd/bulk_fhir_fetch/bulk_fhir_fetch_test.go index 15610c5..045b99f 100644 --- a/cmd/bulk_fhir_fetch/bulk_fhir_fetch_test.go +++ b/cmd/bulk_fhir_fetch/bulk_fhir_fetch_test.go @@ -33,7 +33,7 @@ import ( cpb "github.com/google/fhir/go/proto/google/fhir/proto/r4/core/codes_go_proto" "github.com/google/bulk_fhir_tools/gcs" "github.com/google/bulk_fhir_tools/internal/metrics" - "github.com/google/bulk_fhir_tools/internal/testhelpers" + "github.com/google/bulk_fhir_tools/testhelpers" "flag" diff --git a/fhir/processing/bcdarectify_test.go b/fhir/processing/bcdarectify_test.go index 79bcc16..8cf7687 100644 --- a/fhir/processing/bcdarectify_test.go +++ b/fhir/processing/bcdarectify_test.go @@ -21,7 +21,7 @@ import ( "github.com/google/go-cmp/cmp" "github.com/google/bulk_fhir_tools/fhir/processing" "github.com/google/bulk_fhir_tools/internal/metrics" - "github.com/google/bulk_fhir_tools/internal/testhelpers" + "github.com/google/bulk_fhir_tools/testhelpers" cpb "github.com/google/fhir/go/proto/google/fhir/proto/r4/core/codes_go_proto" ) diff --git a/fhir/processing/documents_test.go b/fhir/processing/documents_test.go index 9d9c255..f741f24 100644 --- a/fhir/processing/documents_test.go +++ b/fhir/processing/documents_test.go @@ -27,7 +27,7 @@ import ( "github.com/google/bulk_fhir_tools/bulkfhir" "github.com/google/bulk_fhir_tools/fhir/processing" "github.com/google/bulk_fhir_tools/internal/metrics" - "github.com/google/bulk_fhir_tools/internal/testhelpers" + "github.com/google/bulk_fhir_tools/testhelpers" cpb "github.com/google/fhir/go/proto/google/fhir/proto/r4/core/codes_go_proto" ) diff --git a/fhir/processing/fhirstoresink_test.go b/fhir/processing/fhirstoresink_test.go index d50df24..ae251db 100644 --- a/fhir/processing/fhirstoresink_test.go +++ b/fhir/processing/fhirstoresink_test.go @@ -30,7 +30,7 @@ import ( "github.com/google/bulk_fhir_tools/bulkfhir" "github.com/google/bulk_fhir_tools/fhir/processing" "github.com/google/bulk_fhir_tools/fhirstore" - "github.com/google/bulk_fhir_tools/internal/testhelpers" + "github.com/google/bulk_fhir_tools/testhelpers" cpb "github.com/google/fhir/go/proto/google/fhir/proto/r4/core/codes_go_proto" ) diff --git a/fhir/processing/ndjsonsink_test.go b/fhir/processing/ndjsonsink_test.go index 94558a0..b3544b0 100644 --- a/fhir/processing/ndjsonsink_test.go +++ b/fhir/processing/ndjsonsink_test.go @@ -25,7 +25,7 @@ import ( "github.com/google/go-cmp/cmp" "github.com/google/go-cmp/cmp/cmpopts" "github.com/google/bulk_fhir_tools/fhir/processing" - "github.com/google/bulk_fhir_tools/internal/testhelpers" + "github.com/google/bulk_fhir_tools/testhelpers" cpb "github.com/google/fhir/go/proto/google/fhir/proto/r4/core/codes_go_proto" rpb "github.com/google/fhir/go/proto/google/fhir/proto/r4/core/resources/bundle_and_contained_resource_go_proto" diff --git a/fhir/rectify_test.go b/fhir/rectify_test.go index 3b3e992..ab80c9a 100644 --- a/fhir/rectify_test.go +++ b/fhir/rectify_test.go @@ -19,7 +19,7 @@ import ( "github.com/google/go-cmp/cmp" "github.com/google/bulk_fhir_tools/fhir" - "github.com/google/bulk_fhir_tools/internal/testhelpers" + "github.com/google/bulk_fhir_tools/testhelpers" ) func TestRectifyBCDA(t *testing.T) { diff --git a/fhirstore/fhirstore_test.go b/fhirstore/fhirstore_test.go index cdd5a22..7f5d82e 100644 --- a/fhirstore/fhirstore_test.go +++ b/fhirstore/fhirstore_test.go @@ -27,7 +27,7 @@ import ( "github.com/google/go-cmp/cmp" "github.com/google/bulk_fhir_tools/fhirstore" "github.com/google/bulk_fhir_tools/internal/metrics" - "github.com/google/bulk_fhir_tools/internal/testhelpers" + "github.com/google/bulk_fhir_tools/testhelpers" cpb "github.com/google/fhir/go/proto/google/fhir/proto/r4/core/codes_go_proto" ) diff --git a/gcs/gcs_test.go b/gcs/gcs_test.go index ca3c1bc..bd4777a 100644 --- a/gcs/gcs_test.go +++ b/gcs/gcs_test.go @@ -19,7 +19,7 @@ import ( "io" "testing" - "github.com/google/bulk_fhir_tools/internal/testhelpers" + "github.com/google/bulk_fhir_tools/testhelpers" ) func TestGCSIsBucketInProjectId(t *testing.T) { diff --git a/internal/logger/logger_test.go b/internal/logger/logger_test.go index 909c052..a3c8e92 100644 --- a/internal/logger/logger_test.go +++ b/internal/logger/logger_test.go @@ -24,7 +24,7 @@ import ( "google.golang.org/api/option" "google.golang.org/grpc" "github.com/google/bulk_fhir_tools/internal/logger" - "github.com/google/bulk_fhir_tools/internal/testhelpers" + "github.com/google/bulk_fhir_tools/testhelpers" ) func TestGCPLogger(t *testing.T) { diff --git a/internal/logger/loggerredirect_test/logger_redirect_test.go b/internal/logger/loggerredirect_test/logger_redirect_test.go index 8685dc2..276c06e 100644 --- a/internal/logger/loggerredirect_test/logger_redirect_test.go +++ b/internal/logger/loggerredirect_test/logger_redirect_test.go @@ -27,7 +27,7 @@ import ( "google.golang.org/api/option" "google.golang.org/grpc" "github.com/google/bulk_fhir_tools/internal/logger" - "github.com/google/bulk_fhir_tools/internal/testhelpers" + "github.com/google/bulk_fhir_tools/testhelpers" ) // TestFallbackGCPLoggerAfterClose tests a fallback behavior if the user mistakenly makes logging diff --git a/internal/testhelpers/fhirstore.go b/testhelpers/fhirstore.go similarity index 100% rename from internal/testhelpers/fhirstore.go rename to testhelpers/fhirstore.go diff --git a/internal/testhelpers/gcs.go b/testhelpers/gcs.go similarity index 100% rename from internal/testhelpers/gcs.go rename to testhelpers/gcs.go diff --git a/internal/testhelpers/json.go b/testhelpers/json.go similarity index 100% rename from internal/testhelpers/json.go rename to testhelpers/json.go diff --git a/internal/testhelpers/logserver.go b/testhelpers/logserver.go similarity index 100% rename from internal/testhelpers/logserver.go rename to testhelpers/logserver.go