github.com/goravel/framework@v1.13.9/contracts/http/mocks/View.go (about) 1 // Code generated by mockery v2.33.1. DO NOT EDIT. 2 3 package mocks 4 5 import mock "github.com/stretchr/testify/mock" 6 7 // View is an autogenerated mock type for the View type 8 type View struct { 9 mock.Mock 10 } 11 12 // Exists provides a mock function with given fields: view 13 func (_m *View) Exists(view string) bool { 14 ret := _m.Called(view) 15 16 var r0 bool 17 if rf, ok := ret.Get(0).(func(string) bool); ok { 18 r0 = rf(view) 19 } else { 20 r0 = ret.Get(0).(bool) 21 } 22 23 return r0 24 } 25 26 // GetShared provides a mock function with given fields: 27 func (_m *View) GetShared() map[string]interface{} { 28 ret := _m.Called() 29 30 var r0 map[string]interface{} 31 if rf, ok := ret.Get(0).(func() map[string]interface{}); ok { 32 r0 = rf() 33 } else { 34 if ret.Get(0) != nil { 35 r0 = ret.Get(0).(map[string]interface{}) 36 } 37 } 38 39 return r0 40 } 41 42 // Share provides a mock function with given fields: key, value 43 func (_m *View) Share(key string, value interface{}) { 44 _m.Called(key, value) 45 } 46 47 // Shared provides a mock function with given fields: key, def 48 func (_m *View) Shared(key string, def ...interface{}) interface{} { 49 var _ca []interface{} 50 _ca = append(_ca, key) 51 _ca = append(_ca, def...) 52 ret := _m.Called(_ca...) 53 54 var r0 interface{} 55 if rf, ok := ret.Get(0).(func(string, ...interface{}) interface{}); ok { 56 r0 = rf(key, def...) 57 } else { 58 if ret.Get(0) != nil { 59 r0 = ret.Get(0).(interface{}) 60 } 61 } 62 63 return r0 64 } 65 66 // NewView creates a new instance of View. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations. 67 // The first argument is typically a *testing.T value. 68 func NewView(t interface { 69 mock.TestingT 70 Cleanup(func()) 71 }) *View { 72 mock := &View{} 73 mock.Mock.Test(t) 74 75 t.Cleanup(func() { mock.AssertExpectations(t) }) 76 77 return mock 78 }