| // Copyright 2021 The Chromium OS Authors. All rights reserved. | |
| // Use of this source code is governed by a BSD-style license that can be | |
| // found in the LICENSE file. | |
| // Code generated by MockGen. DO NOT EDIT. | |
| // Source: chromiumos/tast/common/firmware/serial (interfaces: Port) | |
| // Package mocks is a generated GoMock package. | |
| // CGO_ENABLED=0 GOPATH=/usr/lib/gopath:/mnt/host/source/src/platform/tast-tests:/mnt/host/source/src/platform/tast mockgen -destination=mock_port.go -self_package=chromiumos/tast/common/firmware/serial/mocks -package mocks chromiumos/tast/common/firmware/serial Port | |
| package mocks | |
| import ( | |
| context "context" | |
| reflect "reflect" | |
| gomock "github.com/golang/mock/gomock" | |
| ) | |
| // MockPort is a mock of Port interface. | |
| type MockPort struct { | |
| ctrl *gomock.Controller | |
| recorder *MockPortMockRecorder | |
| } | |
| // MockPortMockRecorder is the mock recorder for MockPort. | |
| type MockPortMockRecorder struct { | |
| mock *MockPort | |
| } | |
| // NewMockPort creates a new mock instance. | |
| func NewMockPort(ctrl *gomock.Controller) *MockPort { | |
| mock := &MockPort{ctrl: ctrl} | |
| mock.recorder = &MockPortMockRecorder{mock} | |
| return mock | |
| } | |
| // EXPECT returns an object that allows the caller to indicate expected use. | |
| func (m *MockPort) EXPECT() *MockPortMockRecorder { | |
| return m.recorder | |
| } | |
| // Close mocks base method. | |
| func (m *MockPort) Close(arg0 context.Context) error { | |
| m.ctrl.T.Helper() | |
| ret := m.ctrl.Call(m, "Close", arg0) | |
| ret0, _ := ret[0].(error) | |
| return ret0 | |
| } | |
| // Close indicates an expected call of Close. | |
| func (mr *MockPortMockRecorder) Close(arg0 interface{}) *gomock.Call { | |
| mr.mock.ctrl.T.Helper() | |
| return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Close", reflect.TypeOf((*MockPort)(nil).Close), arg0) | |
| } | |
| // Flush mocks base method. | |
| func (m *MockPort) Flush(arg0 context.Context) error { | |
| m.ctrl.T.Helper() | |
| ret := m.ctrl.Call(m, "Flush", arg0) | |
| ret0, _ := ret[0].(error) | |
| return ret0 | |
| } | |
| // Flush indicates an expected call of Flush. | |
| func (mr *MockPortMockRecorder) Flush(arg0 interface{}) *gomock.Call { | |
| mr.mock.ctrl.T.Helper() | |
| return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Flush", reflect.TypeOf((*MockPort)(nil).Flush), arg0) | |
| } | |
| // Read mocks base method. | |
| func (m *MockPort) Read(arg0 context.Context, arg1 []byte) (int, error) { | |
| m.ctrl.T.Helper() | |
| ret := m.ctrl.Call(m, "Read", arg0, arg1) | |
| ret0, _ := ret[0].(int) | |
| ret1, _ := ret[1].(error) | |
| return ret0, ret1 | |
| } | |
| // Read indicates an expected call of Read. | |
| func (mr *MockPortMockRecorder) Read(arg0, arg1 interface{}) *gomock.Call { | |
| mr.mock.ctrl.T.Helper() | |
| return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Read", reflect.TypeOf((*MockPort)(nil).Read), arg0, arg1) | |
| } | |
| // Write mocks base method. | |
| func (m *MockPort) Write(arg0 context.Context, arg1 []byte) (int, error) { | |
| m.ctrl.T.Helper() | |
| ret := m.ctrl.Call(m, "Write", arg0, arg1) | |
| ret0, _ := ret[0].(int) | |
| ret1, _ := ret[1].(error) | |
| return ret0, ret1 | |
| } | |
| // Write indicates an expected call of Write. | |
| func (mr *MockPortMockRecorder) Write(arg0, arg1 interface{}) *gomock.Call { | |
| mr.mock.ctrl.T.Helper() | |
| return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Write", reflect.TypeOf((*MockPort)(nil).Write), arg0, arg1) | |
| } |