github.com/wgh-/mattermost-server@v4.8.0-rc2+incompatible/store/storetest/mocks/FileInfoStore.go (about)

     1  // Code generated by mockery v1.0.0
     2  
     3  // Regenerate this file using `make store-mocks`.
     4  
     5  package mocks
     6  
     7  import mock "github.com/stretchr/testify/mock"
     8  import model "github.com/mattermost/mattermost-server/model"
     9  import store "github.com/mattermost/mattermost-server/store"
    10  
    11  // FileInfoStore is an autogenerated mock type for the FileInfoStore type
    12  type FileInfoStore struct {
    13  	mock.Mock
    14  }
    15  
    16  // AttachToPost provides a mock function with given fields: fileId, postId
    17  func (_m *FileInfoStore) AttachToPost(fileId string, postId string) store.StoreChannel {
    18  	ret := _m.Called(fileId, postId)
    19  
    20  	var r0 store.StoreChannel
    21  	if rf, ok := ret.Get(0).(func(string, string) store.StoreChannel); ok {
    22  		r0 = rf(fileId, postId)
    23  	} else {
    24  		if ret.Get(0) != nil {
    25  			r0 = ret.Get(0).(store.StoreChannel)
    26  		}
    27  	}
    28  
    29  	return r0
    30  }
    31  
    32  // DeleteForPost provides a mock function with given fields: postId
    33  func (_m *FileInfoStore) DeleteForPost(postId string) store.StoreChannel {
    34  	ret := _m.Called(postId)
    35  
    36  	var r0 store.StoreChannel
    37  	if rf, ok := ret.Get(0).(func(string) store.StoreChannel); ok {
    38  		r0 = rf(postId)
    39  	} else {
    40  		if ret.Get(0) != nil {
    41  			r0 = ret.Get(0).(store.StoreChannel)
    42  		}
    43  	}
    44  
    45  	return r0
    46  }
    47  
    48  // Get provides a mock function with given fields: id
    49  func (_m *FileInfoStore) Get(id string) store.StoreChannel {
    50  	ret := _m.Called(id)
    51  
    52  	var r0 store.StoreChannel
    53  	if rf, ok := ret.Get(0).(func(string) store.StoreChannel); ok {
    54  		r0 = rf(id)
    55  	} else {
    56  		if ret.Get(0) != nil {
    57  			r0 = ret.Get(0).(store.StoreChannel)
    58  		}
    59  	}
    60  
    61  	return r0
    62  }
    63  
    64  // GetByPath provides a mock function with given fields: path
    65  func (_m *FileInfoStore) GetByPath(path string) store.StoreChannel {
    66  	ret := _m.Called(path)
    67  
    68  	var r0 store.StoreChannel
    69  	if rf, ok := ret.Get(0).(func(string) store.StoreChannel); ok {
    70  		r0 = rf(path)
    71  	} else {
    72  		if ret.Get(0) != nil {
    73  			r0 = ret.Get(0).(store.StoreChannel)
    74  		}
    75  	}
    76  
    77  	return r0
    78  }
    79  
    80  // GetForPost provides a mock function with given fields: postId, readFromMaster, allowFromCache
    81  func (_m *FileInfoStore) GetForPost(postId string, readFromMaster bool, allowFromCache bool) store.StoreChannel {
    82  	ret := _m.Called(postId, readFromMaster, allowFromCache)
    83  
    84  	var r0 store.StoreChannel
    85  	if rf, ok := ret.Get(0).(func(string, bool, bool) store.StoreChannel); ok {
    86  		r0 = rf(postId, readFromMaster, allowFromCache)
    87  	} else {
    88  		if ret.Get(0) != nil {
    89  			r0 = ret.Get(0).(store.StoreChannel)
    90  		}
    91  	}
    92  
    93  	return r0
    94  }
    95  
    96  // InvalidateFileInfosForPostCache provides a mock function with given fields: postId
    97  func (_m *FileInfoStore) InvalidateFileInfosForPostCache(postId string) {
    98  	_m.Called(postId)
    99  }
   100  
   101  // PermanentDelete provides a mock function with given fields: fileId
   102  func (_m *FileInfoStore) PermanentDelete(fileId string) store.StoreChannel {
   103  	ret := _m.Called(fileId)
   104  
   105  	var r0 store.StoreChannel
   106  	if rf, ok := ret.Get(0).(func(string) store.StoreChannel); ok {
   107  		r0 = rf(fileId)
   108  	} else {
   109  		if ret.Get(0) != nil {
   110  			r0 = ret.Get(0).(store.StoreChannel)
   111  		}
   112  	}
   113  
   114  	return r0
   115  }
   116  
   117  // PermanentDeleteBatch provides a mock function with given fields: endTime, limit
   118  func (_m *FileInfoStore) PermanentDeleteBatch(endTime int64, limit int64) store.StoreChannel {
   119  	ret := _m.Called(endTime, limit)
   120  
   121  	var r0 store.StoreChannel
   122  	if rf, ok := ret.Get(0).(func(int64, int64) store.StoreChannel); ok {
   123  		r0 = rf(endTime, limit)
   124  	} else {
   125  		if ret.Get(0) != nil {
   126  			r0 = ret.Get(0).(store.StoreChannel)
   127  		}
   128  	}
   129  
   130  	return r0
   131  }
   132  
   133  // Save provides a mock function with given fields: info
   134  func (_m *FileInfoStore) Save(info *model.FileInfo) store.StoreChannel {
   135  	ret := _m.Called(info)
   136  
   137  	var r0 store.StoreChannel
   138  	if rf, ok := ret.Get(0).(func(*model.FileInfo) store.StoreChannel); ok {
   139  		r0 = rf(info)
   140  	} else {
   141  		if ret.Get(0) != nil {
   142  			r0 = ret.Get(0).(store.StoreChannel)
   143  		}
   144  	}
   145  
   146  	return r0
   147  }