generated from PenaSide/GolangTemplate
91 lines
2.2 KiB
Go
91 lines
2.2 KiB
Go
// Code generated by mockery v2.26.0. DO NOT EDIT.
|
|
|
|
package mocks
|
|
|
|
import (
|
|
mock "github.com/stretchr/testify/mock"
|
|
models "penahub.gitlab.yandexcloud.net/pena-services/pena-social-auth/internal/models"
|
|
)
|
|
|
|
// JwtUtil is an autogenerated mock type for the jwtUtil type
|
|
type JwtUtil struct {
|
|
mock.Mock
|
|
}
|
|
|
|
type JwtUtil_Expecter struct {
|
|
mock *mock.Mock
|
|
}
|
|
|
|
func (_m *JwtUtil) EXPECT() *JwtUtil_Expecter {
|
|
return &JwtUtil_Expecter{mock: &_m.Mock}
|
|
}
|
|
|
|
// Validate provides a mock function with given fields: _a0
|
|
func (_m *JwtUtil) Validate(_a0 string) (*models.JWTAuthUser, error) {
|
|
ret := _m.Called(_a0)
|
|
|
|
var r0 *models.JWTAuthUser
|
|
var r1 error
|
|
if rf, ok := ret.Get(0).(func(string) (*models.JWTAuthUser, error)); ok {
|
|
return rf(_a0)
|
|
}
|
|
if rf, ok := ret.Get(0).(func(string) *models.JWTAuthUser); ok {
|
|
r0 = rf(_a0)
|
|
} else {
|
|
if ret.Get(0) != nil {
|
|
r0 = ret.Get(0).(*models.JWTAuthUser)
|
|
}
|
|
}
|
|
|
|
if rf, ok := ret.Get(1).(func(string) error); ok {
|
|
r1 = rf(_a0)
|
|
} else {
|
|
r1 = ret.Error(1)
|
|
}
|
|
|
|
return r0, r1
|
|
}
|
|
|
|
// JwtUtil_Validate_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Validate'
|
|
type JwtUtil_Validate_Call struct {
|
|
*mock.Call
|
|
}
|
|
|
|
// Validate is a helper method to define mock.On call
|
|
// - _a0 string
|
|
func (_e *JwtUtil_Expecter) Validate(_a0 interface{}) *JwtUtil_Validate_Call {
|
|
return &JwtUtil_Validate_Call{Call: _e.mock.On("Validate", _a0)}
|
|
}
|
|
|
|
func (_c *JwtUtil_Validate_Call) Run(run func(_a0 string)) *JwtUtil_Validate_Call {
|
|
_c.Call.Run(func(args mock.Arguments) {
|
|
run(args[0].(string))
|
|
})
|
|
return _c
|
|
}
|
|
|
|
func (_c *JwtUtil_Validate_Call) Return(_a0 *models.JWTAuthUser, _a1 error) *JwtUtil_Validate_Call {
|
|
_c.Call.Return(_a0, _a1)
|
|
return _c
|
|
}
|
|
|
|
func (_c *JwtUtil_Validate_Call) RunAndReturn(run func(string) (*models.JWTAuthUser, error)) *JwtUtil_Validate_Call {
|
|
_c.Call.Return(run)
|
|
return _c
|
|
}
|
|
|
|
type mockConstructorTestingTNewJwtUtil interface {
|
|
mock.TestingT
|
|
Cleanup(func())
|
|
}
|
|
|
|
// NewJwtUtil creates a new instance of JwtUtil. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations.
|
|
func NewJwtUtil(t mockConstructorTestingTNewJwtUtil) *JwtUtil {
|
|
mock := &JwtUtil{}
|
|
mock.Mock.Test(t)
|
|
|
|
t.Cleanup(func() { mock.AssertExpectations(t) })
|
|
|
|
return mock
|
|
}
|