trpc.group/trpc-go/trpc-go@v1.0.3/server/mockserver/server_mock.go (about)

     1  //
     2  //
     3  // Tencent is pleased to support the open source community by making tRPC available.
     4  //
     5  // Copyright (C) 2023 THL A29 Limited, a Tencent company.
     6  // All rights reserved.
     7  //
     8  // If you have downloaded a copy of the tRPC source code from Tencent,
     9  // please note that tRPC source code is licensed under the  Apache 2.0 License,
    10  // A copy of the Apache 2.0 License is included in this file.
    11  //
    12  //
    13  
    14  // Code generated by MockGen. DO NOT EDIT.
    15  // Source: service.go
    16  
    17  // Package mockserver is a generated GoMock package.
    18  package mockserver
    19  
    20  import (
    21  	reflect "reflect"
    22  
    23  	gomock "github.com/golang/mock/gomock"
    24  )
    25  
    26  // MockService is a mock of Service interface
    27  type MockService struct {
    28  	ctrl     *gomock.Controller
    29  	recorder *MockServiceMockRecorder
    30  }
    31  
    32  // MockServiceMockRecorder is the mock recorder for MockService
    33  type MockServiceMockRecorder struct {
    34  	mock *MockService
    35  }
    36  
    37  // NewMockService creates a new mock instance
    38  func NewMockService(ctrl *gomock.Controller) *MockService {
    39  	mock := &MockService{ctrl: ctrl}
    40  	mock.recorder = &MockServiceMockRecorder{mock}
    41  	return mock
    42  }
    43  
    44  // EXPECT returns an object that allows the caller to indicate expected use
    45  func (m *MockService) EXPECT() *MockServiceMockRecorder {
    46  	return m.recorder
    47  }
    48  
    49  // Register mocks base method
    50  func (m *MockService) Register(serviceDesc, serviceImpl interface{}) error {
    51  	m.ctrl.T.Helper()
    52  	ret := m.ctrl.Call(m, "Register", serviceDesc, serviceImpl)
    53  	ret0, _ := ret[0].(error)
    54  	return ret0
    55  }
    56  
    57  // Register indicates an expected call of Register
    58  func (mr *MockServiceMockRecorder) Register(serviceDesc, serviceImpl interface{}) *gomock.Call {
    59  	mr.mock.ctrl.T.Helper()
    60  	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Register", reflect.TypeOf((*MockService)(nil).Register), serviceDesc, serviceImpl)
    61  }
    62  
    63  // Serve mocks base method
    64  func (m *MockService) Serve() error {
    65  	m.ctrl.T.Helper()
    66  	ret := m.ctrl.Call(m, "Serve")
    67  	ret0, _ := ret[0].(error)
    68  	return ret0
    69  }
    70  
    71  // Serve indicates an expected call of Serve
    72  func (mr *MockServiceMockRecorder) Serve() *gomock.Call {
    73  	mr.mock.ctrl.T.Helper()
    74  	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Serve", reflect.TypeOf((*MockService)(nil).Serve))
    75  }
    76  
    77  // Close mocks base method
    78  func (m *MockService) Close(arg0 chan struct{}) error {
    79  	m.ctrl.T.Helper()
    80  	ret := m.ctrl.Call(m, "Close", arg0)
    81  	ret0, _ := ret[0].(error)
    82  	return ret0
    83  }
    84  
    85  // Close indicates an expected call of Close
    86  func (mr *MockServiceMockRecorder) Close(arg0 interface{}) *gomock.Call {
    87  	mr.mock.ctrl.T.Helper()
    88  	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Close", reflect.TypeOf((*MockService)(nil).Close), arg0)
    89  }