NewErroringMockCache creates a new ErroringMockCache with the given error.
(err error)
| 224 | |
| 225 | // NewErroringMockCache creates a new ErroringMockCache with the given error. |
| 226 | func NewErroringMockCache(err error) *ErroringMockCache { |
| 227 | return &ErroringMockCache{ |
| 228 | MockCache: NewMockCache(), |
| 229 | GetMultiErr: err, |
| 230 | } |
| 231 | } |
| 232 | |
| 233 | func (m *ErroringMockCache) GetMulti(ctx context.Context, keys []string, opts ...Option) map[string][]byte { |
| 234 | result, _ := m.GetMultiWithError(ctx, keys, opts...) |