omnibox_preferences.go RawHistoryFolder
1// Code generated by mockery; DO NOT EDIT.
2// github.com/vektra/mockery
3// template: testify
4
5package mocks
6
7import (
8 "context"
9
10 "github.com/bnema/dumber/internal/domain/entity"
11 mock "github.com/stretchr/testify/mock"
12)
13
14// NewMockOmniboxPreferencesSaver creates a new instance of MockOmniboxPreferencesSaver. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations.
15// The first argument is typically a *testing.T value.
16func NewMockOmniboxPreferencesSaver(t interface {
17 mock.TestingT
18 Cleanup(func())
19}) *MockOmniboxPreferencesSaver {
20 mock := &MockOmniboxPreferencesSaver{}
21 mock.Mock.Test(t)
22
23 t.Cleanup(func() { mock.AssertExpectations(t) })
24
25 return mock
26}
27
28// MockOmniboxPreferencesSaver is an autogenerated mock type for the OmniboxPreferencesSaver type
29type MockOmniboxPreferencesSaver struct {
30 mock.Mock
31}
32
33type MockOmniboxPreferencesSaver_Expecter struct {
34 mock *mock.Mock
35}
36
37func (_m *MockOmniboxPreferencesSaver) EXPECT() *MockOmniboxPreferencesSaver_Expecter {
38 return &MockOmniboxPreferencesSaver_Expecter{mock: &_m.Mock}
39}
40
41// SaveOmniboxInitialBehavior provides a mock function for the type MockOmniboxPreferencesSaver
42func (_mock *MockOmniboxPreferencesSaver) SaveOmniboxInitialBehavior(ctx context.Context, behavior entity.OmniboxInitialBehavior) error {
43 ret := _mock.Called(ctx, behavior)
44
45 if len(ret) == 0 {
46 panic("no return value specified for SaveOmniboxInitialBehavior")
47 }
48
49 var r0 error
50 if returnFunc, ok := ret.Get(0).(func(context.Context, entity.OmniboxInitialBehavior) error); ok {
51 r0 = returnFunc(ctx, behavior)
52 } else {
53 r0 = ret.Error(0)
54 }
55 return r0
56}
57
58// MockOmniboxPreferencesSaver_SaveOmniboxInitialBehavior_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'SaveOmniboxInitialBehavior'
59type MockOmniboxPreferencesSaver_SaveOmniboxInitialBehavior_Call struct {
60 *mock.Call
61}
62
63// SaveOmniboxInitialBehavior is a helper method to define mock.On call
64// - ctx context.Context
65// - behavior entity.OmniboxInitialBehavior
66func (_e *MockOmniboxPreferencesSaver_Expecter) SaveOmniboxInitialBehavior(ctx any, behavior any) *MockOmniboxPreferencesSaver_SaveOmniboxInitialBehavior_Call {
67 return &MockOmniboxPreferencesSaver_SaveOmniboxInitialBehavior_Call{Call: _e.mock.On("SaveOmniboxInitialBehavior", ctx, behavior)}
68}
69
70func (_c *MockOmniboxPreferencesSaver_SaveOmniboxInitialBehavior_Call) Run(run func(ctx context.Context, behavior entity.OmniboxInitialBehavior)) *MockOmniboxPreferencesSaver_SaveOmniboxInitialBehavior_Call {
71 _c.Call.Run(func(args mock.Arguments) {
72 var arg0 context.Context
73 if args[0] != nil {
74 arg0 = args[0].(context.Context)
75 }
76 var arg1 entity.OmniboxInitialBehavior
77 if args[1] != nil {
78 arg1 = args[1].(entity.OmniboxInitialBehavior)
79 }
80 run(
81 arg0,
82 arg1,
83 )
84 })
85 return _c
86}
87
88func (_c *MockOmniboxPreferencesSaver_SaveOmniboxInitialBehavior_Call) Return(err error) *MockOmniboxPreferencesSaver_SaveOmniboxInitialBehavior_Call {
89 _c.Call.Return(err)
90 return _c
91}
92
93func (_c *MockOmniboxPreferencesSaver_SaveOmniboxInitialBehavior_Call) RunAndReturn(run func(ctx context.Context, behavior entity.OmniboxInitialBehavior) error) *MockOmniboxPreferencesSaver_SaveOmniboxInitialBehavior_Call {
94 _c.Call.Return(run)
95 return _c
96}