From 13aff7b3db95325b309ac14dd7126b2d9a4dbcf2 Mon Sep 17 00:00:00 2001 From: Thom Carlin Date: Thu, 8 Aug 2024 14:13:35 -0400 Subject: [PATCH] Change common_test.go to use black box testing --- pkg/utils/common_test.go | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/pkg/utils/common_test.go b/pkg/utils/common_test.go index 956c8d1e8..7d9f32979 100644 --- a/pkg/utils/common_test.go +++ b/pkg/utils/common_test.go @@ -1,4 +1,4 @@ -package utils +package utils_test import ( "crypto/x509" @@ -10,6 +10,7 @@ import ( "testing" "github.com/ansible/receptor/pkg/logger" + "github.com/ansible/receptor/pkg/utils" ) func TestParseReceptorNamesFromCert(t *testing.T) { @@ -110,7 +111,7 @@ Bdt96MbGrC0= for _, tt := range tests { t.Run(tt.name, func(t *testing.T) { - got, got1, err := ParseReceptorNamesFromCert(tt.args.cert, tt.args.expectedHostname, tt.args.logger) + got, got1, err := utils.ParseReceptorNamesFromCert(tt.args.cert, tt.args.expectedHostname, tt.args.logger) if (err != nil) != tt.wantErr { t.Errorf("ParseReceptorNamesFromCert() error = %v, wantErr %v", err, tt.wantErr)