GetTokens provides a mock function with given fields: delay
|
func ( _m * OCMClient ) GetTokens ( delay time . Duration ) ( string , string , error ) {
ret := _m . Called ( delay )
if len ( ret ) == 0 {
panic ( "no return value specified for GetTokens" )
}
var r0 string
var r1 string
var r2 error
if rf , ok := ret . Get ( 0 ) . ( func ( time . Duration ) ( string , string , error ) ) ; ok {
return rf ( delay )
}
if rf , ok := ret . Get ( 0 ) . ( func ( time . Duration ) string ) ; ok {
r0 = rf ( delay )
} else {
r0 = ret . Get ( 0 ) . ( string )
}
if rf , ok := ret . Get ( 1 ) . ( func ( time . Duration ) string ) ; ok {
r1 = rf ( delay )
} else {
r1 = ret . Get ( 1 ) . ( string )
}
if rf , ok := ret . Get ( 2 ) . ( func ( time . Duration ) error ) ; ok {
r2 = rf ( delay )
} else {
r2 = ret . Error ( 2 )
}
return r0 , r1 , r2
}
|
NewOCMClient creates a new instance of OCMClient. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations.
The first argument is typically a *testing.T value.
|
func NewOCMClient ( t interface {
mock . TestingT
Cleanup ( func ( ) )
} ) * OCMClient {
mock := & OCMClient { }
mock . Mock . Test ( t )
t . Cleanup ( func ( ) { mock . AssertExpectations ( t ) } )
return mock
}
|