Files
tasks/common/persistence/history_branch_util_mock.go
Yichao YangandGitHub 827606b041 CHASM: Revert ArchetypeID change for NewHistoryBranch (#8718)
## What changed?
- Revert ArchetypeID change for NewHistoryBranch

## Why?
- Will do this later, too many breaking changes for internal repo
- Not technically required for chasm, because chasm executions right now
don't have history events.

## How did you test it?
- [x] built
- [ ] run locally and tested manually
- [x] covered by existing tests
- [ ] added new unit test(s)
- [ ] added new functional test(s)
2025-11-27 01:58:28 +00:00

88 lines
3.7 KiB
Go

// Code generated by MockGen. DO NOT EDIT.
// Source: history_branch_util.go
//
// Generated by this command:
//
// mockgen -package persistence -source history_branch_util.go -destination history_branch_util_mock.go
//
// Package persistence is a generated GoMock package.
package persistence
import (
reflect "reflect"
time "time"
persistence "go.temporal.io/server/api/persistence/v1"
gomock "go.uber.org/mock/gomock"
)
// MockHistoryBranchUtil is a mock of HistoryBranchUtil interface.
type MockHistoryBranchUtil struct {
ctrl *gomock.Controller
recorder *MockHistoryBranchUtilMockRecorder
isgomock struct{}
}
// MockHistoryBranchUtilMockRecorder is the mock recorder for MockHistoryBranchUtil.
type MockHistoryBranchUtilMockRecorder struct {
mock *MockHistoryBranchUtil
}
// NewMockHistoryBranchUtil creates a new mock instance.
func NewMockHistoryBranchUtil(ctrl *gomock.Controller) *MockHistoryBranchUtil {
mock := &MockHistoryBranchUtil{ctrl: ctrl}
mock.recorder = &MockHistoryBranchUtilMockRecorder{mock}
return mock
}
// EXPECT returns an object that allows the caller to indicate expected use.
func (m *MockHistoryBranchUtil) EXPECT() *MockHistoryBranchUtilMockRecorder {
return m.recorder
}
// NewHistoryBranch mocks base method.
func (m *MockHistoryBranchUtil) NewHistoryBranch(namespaceID, workflowID, runID, treeID string, branchID *string, ancestors []*persistence.HistoryBranchRange, runTimeout, executionTimeout, retentionDuration time.Duration) ([]byte, error) {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "NewHistoryBranch", namespaceID, workflowID, runID, treeID, branchID, ancestors, runTimeout, executionTimeout, retentionDuration)
ret0, _ := ret[0].([]byte)
ret1, _ := ret[1].(error)
return ret0, ret1
}
// NewHistoryBranch indicates an expected call of NewHistoryBranch.
func (mr *MockHistoryBranchUtilMockRecorder) NewHistoryBranch(namespaceID, workflowID, runID, treeID, branchID, ancestors, runTimeout, executionTimeout, retentionDuration any) *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "NewHistoryBranch", reflect.TypeOf((*MockHistoryBranchUtil)(nil).NewHistoryBranch), namespaceID, workflowID, runID, treeID, branchID, ancestors, runTimeout, executionTimeout, retentionDuration)
}
// ParseHistoryBranchInfo mocks base method.
func (m *MockHistoryBranchUtil) ParseHistoryBranchInfo(branchToken []byte) (*persistence.HistoryBranch, error) {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "ParseHistoryBranchInfo", branchToken)
ret0, _ := ret[0].(*persistence.HistoryBranch)
ret1, _ := ret[1].(error)
return ret0, ret1
}
// ParseHistoryBranchInfo indicates an expected call of ParseHistoryBranchInfo.
func (mr *MockHistoryBranchUtilMockRecorder) ParseHistoryBranchInfo(branchToken any) *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ParseHistoryBranchInfo", reflect.TypeOf((*MockHistoryBranchUtil)(nil).ParseHistoryBranchInfo), branchToken)
}
// UpdateHistoryBranchInfo mocks base method.
func (m *MockHistoryBranchUtil) UpdateHistoryBranchInfo(branchToken []byte, branchInfo *persistence.HistoryBranch, runID string) ([]byte, error) {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "UpdateHistoryBranchInfo", branchToken, branchInfo, runID)
ret0, _ := ret[0].([]byte)
ret1, _ := ret[1].(error)
return ret0, ret1
}
// UpdateHistoryBranchInfo indicates an expected call of UpdateHistoryBranchInfo.
func (mr *MockHistoryBranchUtilMockRecorder) UpdateHistoryBranchInfo(branchToken, branchInfo, runID any) *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "UpdateHistoryBranchInfo", reflect.TypeOf((*MockHistoryBranchUtil)(nil).UpdateHistoryBranchInfo), branchToken, branchInfo, runID)
}