Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
陈曦
sub2api
Commits
66ff2def
Commit
66ff2def
authored
Apr 09, 2026
by
IanShaw027
Browse files
fix(test): 补充 admin service 分组测试字符串指针辅助函数
parent
de9b9c9d
Changes
1
Show whitespace changes
Inline
Side-by-side
backend/internal/service/admin_service_group_test.go
View file @
66ff2def
...
@@ -10,6 +10,11 @@ import (
...
@@ -10,6 +10,11 @@ import (
"github.com/stretchr/testify/require"
"github.com/stretchr/testify/require"
)
)
func
ptrString
[
T
~
string
](
v
T
)
*
string
{
s
:=
string
(
v
)
return
&
s
}
// groupRepoStubForAdmin 用于测试 AdminService 的 GroupRepository Stub
// groupRepoStubForAdmin 用于测试 AdminService 的 GroupRepository Stub
type
groupRepoStubForAdmin
struct
{
type
groupRepoStubForAdmin
struct
{
created
*
Group
// 记录 Create 调用的参数
created
*
Group
// 记录 Create 调用的参数
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment