fix(test): 补充 admin service 分组测试字符串指针辅助函数

This commit is contained in:
IanShaw027
2026-04-09 12:39:05 +08:00
parent de9b9c9dfb
commit 66ff2def8c

View File

@@ -10,6 +10,11 @@ import (
"github.com/stretchr/testify/require"
)
func ptrString[T ~string](v T) *string {
s := string(v)
return &s
}
// groupRepoStubForAdmin 用于测试 AdminService 的 GroupRepository Stub
type groupRepoStubForAdmin struct {
created *Group // 记录 Create 调用的参数