mirror of
https://github.com/harness/drone.git
synced 2025-05-05 15:32:56 +00:00
* fix merge conflicts * fix merge conflicts * fix review comment * fix review comment * fix review comment * fix: [AH-771]: gitness unit test refactoring * fix: [AH-771]: resolved review comments * fix: [AH-771]: resolved review comments * fix: [AH-771] Registry test refactoring and improvements - Refactored registry metadata test implementations - Improved code organization and readability - Fixed line length issues in test files - Removed unused fields from request.go - Added proper license headers - Fixed linting issues in mock files - Simplified test setup and assertions - Updated wire generation for cmd package - Added nolint:exhaustive directive for package type switch fix: [AH-771] Registry test refactoring and improvements - Refactored registry metadata test implementations - Improved code organization and readability - Fixed line length issues in test files - Removed unused fields from request.go - Added proper license headers - Fixed linting issues in mock files - Simplifi
40 lines
949 B
Go
40 lines
949 B
Go
// Code generated by testify. DO NOT EDIT.
|
|
|
|
package mocks
|
|
|
|
import (
|
|
"context"
|
|
|
|
gitnesswebhook "github.com/harness/gitness/app/services/webhook"
|
|
|
|
"github.com/stretchr/testify/mock"
|
|
)
|
|
|
|
// WebhookService is a mock of WebhookService interface.
|
|
type WebhookService struct {
|
|
mock.Mock
|
|
}
|
|
|
|
// ReTriggerWebhookExecution provides a mock function
|
|
func (m *WebhookService) ReTriggerWebhookExecution(ctx context.Context, webhookExecutionID int64) (*gitnesswebhook.TriggerResult, error) {
|
|
ret := m.Called(ctx, webhookExecutionID)
|
|
|
|
var r0 *gitnesswebhook.TriggerResult
|
|
if rf, ok := ret.Get(0).(func(context.Context, int64) *gitnesswebhook.TriggerResult); ok {
|
|
r0 = rf(ctx, webhookExecutionID)
|
|
} else {
|
|
if ret.Get(0) != nil {
|
|
r0 = ret.Get(0).(*gitnesswebhook.TriggerResult)
|
|
}
|
|
}
|
|
|
|
var r1 error
|
|
if rf, ok := ret.Get(1).(func(context.Context, int64) error); ok {
|
|
r1 = rf(ctx, webhookExecutionID)
|
|
} else {
|
|
r1 = ret.Error(1)
|
|
}
|
|
|
|
return r0, r1
|
|
}
|