Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type StreamRowReaderMock ¶
type StreamRowReaderMock struct { // CloseFunc mocks the Close method. CloseFunc func(in1 context.Context) error // ReadFunc mocks the Read method. ReadFunc func() (string, error) // contains filtered or unexported fields }
StreamRowReaderMock is a mock implementation of observation.StreamRowReader.
func TestSomethingThatUsesStreamRowReader(t *testing.T) { // make and configure a mocked observation.StreamRowReader mockedStreamRowReader := &StreamRowReaderMock{ CloseFunc: func(in1 context.Context) error { panic("mock out the Close method") }, ReadFunc: func() (string, error) { panic("mock out the Read method") }, } // use mockedStreamRowReader in code that requires observation.StreamRowReader // and then make assertions. }
func (*StreamRowReaderMock) Close ¶
func (mock *StreamRowReaderMock) Close(in1 context.Context) error
Close calls CloseFunc.
func (*StreamRowReaderMock) CloseCalls ¶
func (mock *StreamRowReaderMock) CloseCalls() []struct { In1 context.Context }
CloseCalls gets all the calls that were made to Close. Check the length with:
len(mockedStreamRowReader.CloseCalls())
func (*StreamRowReaderMock) Read ¶
func (mock *StreamRowReaderMock) Read() (string, error)
Read calls ReadFunc.
func (*StreamRowReaderMock) ReadCalls ¶
func (mock *StreamRowReaderMock) ReadCalls() []struct { }
ReadCalls gets all the calls that were made to Read. Check the length with:
len(mockedStreamRowReader.ReadCalls())
Click to show internal directories.
Click to hide internal directories.