github.com/web-platform-tests/wpt.fyi@v0.0.0-20240530210107-70cf978996f1/api/query/cache/index/index_mock.go (about)

     1  // Code generated by MockGen. DO NOT EDIT.
     2  // Source: api/query/cache/index/index.go
     3  
     4  // Package index is a generated GoMock package.
     5  package index
     6  
     7  import (
     8  	reflect "reflect"
     9  
    10  	gomock "github.com/golang/mock/gomock"
    11  	metrics "github.com/web-platform-tests/wpt.fyi/shared/metrics"
    12  	query "github.com/web-platform-tests/wpt.fyi/api/query"
    13  	shared "github.com/web-platform-tests/wpt.fyi/shared"
    14  )
    15  
    16  // MockIndex is a mock of Index interface
    17  type MockIndex struct {
    18  	ctrl     *gomock.Controller
    19  	recorder *MockIndexMockRecorder
    20  }
    21  
    22  // MockIndexMockRecorder is the mock recorder for MockIndex
    23  type MockIndexMockRecorder struct {
    24  	mock *MockIndex
    25  }
    26  
    27  // NewMockIndex creates a new mock instance
    28  func NewMockIndex(ctrl *gomock.Controller) *MockIndex {
    29  	mock := &MockIndex{ctrl: ctrl}
    30  	mock.recorder = &MockIndexMockRecorder{mock}
    31  	return mock
    32  }
    33  
    34  // EXPECT returns an object that allows the caller to indicate expected use
    35  func (m *MockIndex) EXPECT() *MockIndexMockRecorder {
    36  	return m.recorder
    37  }
    38  
    39  // Bind mocks base method
    40  func (m *MockIndex) Bind(arg0 []shared.TestRun, arg1 query.ConcreteQuery) (query.Plan, error) {
    41  	ret := m.ctrl.Call(m, "Bind", arg0, arg1)
    42  	ret0, _ := ret[0].(query.Plan)
    43  	ret1, _ := ret[1].(error)
    44  	return ret0, ret1
    45  }
    46  
    47  // Bind indicates an expected call of Bind
    48  func (mr *MockIndexMockRecorder) Bind(arg0, arg1 interface{}) *gomock.Call {
    49  	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Bind", reflect.TypeOf((*MockIndex)(nil).Bind), arg0, arg1)
    50  }
    51  
    52  // Run mocks base method
    53  func (m *MockIndex) Run(arg0 RunID) (shared.TestRun, error) {
    54  	m.ctrl.T.Helper()
    55  	ret := m.ctrl.Call(m, "Run", arg0)
    56  	ret0, _ := ret[0].(shared.TestRun)
    57  	ret1, _ := ret[1].(error)
    58  	return ret0, ret1
    59  }
    60  
    61  // Run indicates an expected call of Run
    62  func (mr *MockIndexMockRecorder) Run(arg0 interface{}) *gomock.Call {
    63  	mr.mock.ctrl.T.Helper()
    64  	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Run", reflect.TypeOf((*MockIndex)(nil).Run), arg0)
    65  }
    66  
    67  // Runs mocks base method
    68  func (m *MockIndex) Runs(arg0 []RunID) ([]shared.TestRun, error) {
    69  	ret := m.ctrl.Call(m, "Runs", arg0)
    70  	ret0, _ := ret[0].([]shared.TestRun)
    71  	ret1, _ := ret[1].(error)
    72  	return ret0, ret1
    73  }
    74  
    75  // Runs indicates an expected call of Runs
    76  func (mr *MockIndexMockRecorder) Runs(arg0 interface{}) *gomock.Call {
    77  	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Runs", reflect.TypeOf((*MockIndex)(nil).Runs), arg0)
    78  }
    79  
    80  // IngestRun mocks base method
    81  func (m *MockIndex) IngestRun(arg0 shared.TestRun) error {
    82  	ret := m.ctrl.Call(m, "IngestRun", arg0)
    83  	ret0, _ := ret[0].(error)
    84  	return ret0
    85  }
    86  
    87  // IngestRun indicates an expected call of IngestRun
    88  func (mr *MockIndexMockRecorder) IngestRun(arg0 interface{}) *gomock.Call {
    89  	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "IngestRun", reflect.TypeOf((*MockIndex)(nil).IngestRun), arg0)
    90  }
    91  
    92  // EvictRuns mocks base method
    93  func (m *MockIndex) EvictRuns(arg0 float64) (int, error) {
    94  	ret := m.ctrl.Call(m, "EvictRuns", arg0)
    95  	ret0, _ := ret[0].(int)
    96  	ret1, _ := ret[1].(error)
    97  	return ret0, ret1
    98  }
    99  
   100  // EvictRuns indicates an expected call of EvictRuns
   101  func (mr *MockIndexMockRecorder) EvictRuns(arg0 interface{}) *gomock.Call {
   102  	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "EvictRuns", reflect.TypeOf((*MockIndex)(nil).EvictRuns), arg0)
   103  }
   104  
   105  // SetIngestChan mocks base method
   106  func (m *MockIndex) SetIngestChan(arg0 chan bool) {
   107  	m.ctrl.Call(m, "SetIngestChan", arg0)
   108  }
   109  
   110  // SetIngestChan indicates an expected call of SetIngestChan
   111  func (mr *MockIndexMockRecorder) SetIngestChan(arg0 interface{}) *gomock.Call {
   112  	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "SetIngestChan", reflect.TypeOf((*MockIndex)(nil).SetIngestChan), arg0)
   113  }
   114  
   115  // MockReportLoader is a mock of ReportLoader interface
   116  type MockReportLoader struct {
   117  	ctrl     *gomock.Controller
   118  	recorder *MockReportLoaderMockRecorder
   119  }
   120  
   121  // MockReportLoaderMockRecorder is the mock recorder for MockReportLoader
   122  type MockReportLoaderMockRecorder struct {
   123  	mock *MockReportLoader
   124  }
   125  
   126  // NewMockReportLoader creates a new mock instance
   127  func NewMockReportLoader(ctrl *gomock.Controller) *MockReportLoader {
   128  	mock := &MockReportLoader{ctrl: ctrl}
   129  	mock.recorder = &MockReportLoaderMockRecorder{mock}
   130  	return mock
   131  }
   132  
   133  // EXPECT returns an object that allows the caller to indicate expected use
   134  func (m *MockReportLoader) EXPECT() *MockReportLoaderMockRecorder {
   135  	return m.recorder
   136  }
   137  
   138  // Load mocks base method
   139  func (m *MockReportLoader) Load(arg0 shared.TestRun) (*metrics.TestResultsReport, error) {
   140  	ret := m.ctrl.Call(m, "Load", arg0)
   141  	ret0, _ := ret[0].(*metrics.TestResultsReport)
   142  	ret1, _ := ret[1].(error)
   143  	return ret0, ret1
   144  }
   145  
   146  // Load indicates an expected call of Load
   147  func (mr *MockReportLoaderMockRecorder) Load(arg0 interface{}) *gomock.Call {
   148  	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Load", reflect.TypeOf((*MockReportLoader)(nil).Load), arg0)
   149  }