This is an automated email from the ASF dual-hosted git repository.

linkinstar pushed a commit to branch dev
in repository https://gitbox.apache.org/repos/asf/answer.git

commit ee6e67243ddebf876d485dfc50db6b9968db9b92
Author: LinkinStars <linkins...@foxmail.com>
AuthorDate: Fri Jun 13 16:02:11 2025 +0800

    test(internal): add mock for IsBrandingFileUsed method
---
 internal/service/mock/siteinfo_repo_mock.go | 29 +++++++++++++++++++++++++++++
 1 file changed, 29 insertions(+)

diff --git a/internal/service/mock/siteinfo_repo_mock.go 
b/internal/service/mock/siteinfo_repo_mock.go
index 1b841278..a98ceb68 100644
--- a/internal/service/mock/siteinfo_repo_mock.go
+++ b/internal/service/mock/siteinfo_repo_mock.go
@@ -77,6 +77,21 @@ func (mr *MockSiteInfoRepoMockRecorder) GetByType(ctx, 
siteType any) *gomock.Cal
        return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "GetByType", 
reflect.TypeOf((*MockSiteInfoRepo)(nil).GetByType), ctx, siteType)
 }
 
+// IsBrandingFileUsed mocks base method.
+func (m *MockSiteInfoRepo) IsBrandingFileUsed(ctx context.Context, filePath 
string) (bool, error) {
+       m.ctrl.T.Helper()
+       ret := m.ctrl.Call(m, "IsBrandingFileUsed", ctx, filePath)
+       ret0, _ := ret[0].(bool)
+       ret1, _ := ret[1].(error)
+       return ret0, ret1
+}
+
+// IsBrandingFileUsed indicates an expected call of IsBrandingFileUsed.
+func (mr *MockSiteInfoRepoMockRecorder) IsBrandingFileUsed(ctx, filePath any) 
*gomock.Call {
+       mr.mock.ctrl.T.Helper()
+       return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, 
"IsBrandingFileUsed", 
reflect.TypeOf((*MockSiteInfoRepo)(nil).IsBrandingFileUsed), ctx, filePath)
+}
+
 // SaveByType mocks base method.
 func (m *MockSiteInfoRepo) SaveByType(ctx context.Context, siteType string, 
data *entity.SiteInfo) error {
        m.ctrl.T.Helper()
@@ -306,3 +321,17 @@ func (mr *MockSiteInfoCommonServiceMockRecorder) 
GetSiteWrite(ctx any) *gomock.C
        mr.mock.ctrl.T.Helper()
        return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "GetSiteWrite", 
reflect.TypeOf((*MockSiteInfoCommonService)(nil).GetSiteWrite), ctx)
 }
+
+// IsBrandingFileUsed mocks base method.
+func (m *MockSiteInfoCommonService) IsBrandingFileUsed(ctx context.Context, 
filePath string) bool {
+       m.ctrl.T.Helper()
+       ret := m.ctrl.Call(m, "IsBrandingFileUsed", ctx, filePath)
+       ret0, _ := ret[0].(bool)
+       return ret0
+}
+
+// IsBrandingFileUsed indicates an expected call of IsBrandingFileUsed.
+func (mr *MockSiteInfoCommonServiceMockRecorder) IsBrandingFileUsed(ctx, 
filePath any) *gomock.Call {
+       mr.mock.ctrl.T.Helper()
+       return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, 
"IsBrandingFileUsed", 
reflect.TypeOf((*MockSiteInfoCommonService)(nil).IsBrandingFileUsed), ctx, 
filePath)
+}

Reply via email to