From e8a5e26b0f9d4782a431f1b6d03edb4b4ede077e Mon Sep 17 00:00:00 2001 From: Adam Shannon Date: Fri, 10 May 2024 10:31:03 -0500 Subject: [PATCH] database: one more fix for tests on Windows --- database/tls_test.go | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/database/tls_test.go b/database/tls_test.go index 1aefbd21..6a87e95c 100644 --- a/database/tls_test.go +++ b/database/tls_test.go @@ -11,8 +11,10 @@ import ( ) func Test_LoadClientCertsFromConfig(t *testing.T) { - certFilepath := filepath.Join("/", "tmp", "client_cert.pem") - keyFilepath := filepath.Join("/", "tmp", "client_cert_private_key.pem") + dir := t.TempDir() + + certFilepath := filepath.Join(dir, "client_cert.pem") + keyFilepath := filepath.Join(dir, "client_cert_private_key.pem") err := testcerts.GenerateCertsToFile(certFilepath, keyFilepath) require.Nil(t, err)