From fee69e7c20b72ca05c4572a876f3cacc53eebbe1 Mon Sep 17 00:00:00 2001 From: JustSong Date: Sun, 23 Jun 2024 13:48:52 +0800 Subject: [PATCH] fix: fix ut --- common/image/image_test.go | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/common/image/image_test.go b/common/image/image_test.go index 15ed78bc..5b669b51 100644 --- a/common/image/image_test.go +++ b/common/image/image_test.go @@ -2,6 +2,7 @@ package image_test import ( "encoding/base64" + "github.com/songquanpeng/one-api/common/client" "image" _ "image/gif" _ "image/jpeg" @@ -44,6 +45,11 @@ var ( } ) +func TestMain(m *testing.M) { + client.Init() + m.Run() +} + func TestDecode(t *testing.T) { // Bytes read: varies sometimes // jpeg: 1063892