// Code generated by mockery v2.20.0. DO NOT EDIT.

package mocks

import (
	models "github.com/caraml-dev/merlin/models"
	mock "github.com/stretchr/testify/mock"

	uuid "github.com/google/uuid"
)

// VersionEndpointStorage is an autogenerated mock type for the VersionEndpointStorage type
type VersionEndpointStorage struct {
	mock.Mock
}

// CountEndpoints provides a mock function with given fields: environment, model
func (_m *VersionEndpointStorage) CountEndpoints(environment *models.Environment, model *models.Model) (int, error) {
	ret := _m.Called(environment, model)

	var r0 int
	var r1 error
	if rf, ok := ret.Get(0).(func(*models.Environment, *models.Model) (int, error)); ok {
		return rf(environment, model)
	}
	if rf, ok := ret.Get(0).(func(*models.Environment, *models.Model) int); ok {
		r0 = rf(environment, model)
	} else {
		r0 = ret.Get(0).(int)
	}

	if rf, ok := ret.Get(1).(func(*models.Environment, *models.Model) error); ok {
		r1 = rf(environment, model)
	} else {
		r1 = ret.Error(1)
	}

	return r0, r1
}

// Delete provides a mock function with given fields: endpoint
func (_m *VersionEndpointStorage) Delete(endpoint *models.VersionEndpoint) error {
	ret := _m.Called(endpoint)

	var r0 error
	if rf, ok := ret.Get(0).(func(*models.VersionEndpoint) error); ok {
		r0 = rf(endpoint)
	} else {
		r0 = ret.Error(0)
	}

	return r0
}

// Get provides a mock function with given fields: _a0
func (_m *VersionEndpointStorage) Get(_a0 uuid.UUID) (*models.VersionEndpoint, error) {
	ret := _m.Called(_a0)

	var r0 *models.VersionEndpoint
	var r1 error
	if rf, ok := ret.Get(0).(func(uuid.UUID) (*models.VersionEndpoint, error)); ok {
		return rf(_a0)
	}
	if rf, ok := ret.Get(0).(func(uuid.UUID) *models.VersionEndpoint); ok {
		r0 = rf(_a0)
	} else {
		if ret.Get(0) != nil {
			r0 = ret.Get(0).(*models.VersionEndpoint)
		}
	}

	if rf, ok := ret.Get(1).(func(uuid.UUID) error); ok {
		r1 = rf(_a0)
	} else {
		r1 = ret.Error(1)
	}

	return r0, r1
}

// ListEndpoints provides a mock function with given fields: model, version
func (_m *VersionEndpointStorage) ListEndpoints(model *models.Model, version *models.Version) ([]*models.VersionEndpoint, error) {
	ret := _m.Called(model, version)

	var r0 []*models.VersionEndpoint
	var r1 error
	if rf, ok := ret.Get(0).(func(*models.Model, *models.Version) ([]*models.VersionEndpoint, error)); ok {
		return rf(model, version)
	}
	if rf, ok := ret.Get(0).(func(*models.Model, *models.Version) []*models.VersionEndpoint); ok {
		r0 = rf(model, version)
	} else {
		if ret.Get(0) != nil {
			r0 = ret.Get(0).([]*models.VersionEndpoint)
		}
	}

	if rf, ok := ret.Get(1).(func(*models.Model, *models.Version) error); ok {
		r1 = rf(model, version)
	} else {
		r1 = ret.Error(1)
	}

	return r0, r1
}

// Save provides a mock function with given fields: endpoint
func (_m *VersionEndpointStorage) Save(endpoint *models.VersionEndpoint) error {
	ret := _m.Called(endpoint)

	var r0 error
	if rf, ok := ret.Get(0).(func(*models.VersionEndpoint) error); ok {
		r0 = rf(endpoint)
	} else {
		r0 = ret.Error(0)
	}

	return r0
}

type mockConstructorTestingTNewVersionEndpointStorage interface {
	mock.TestingT
	Cleanup(func())
}

// NewVersionEndpointStorage creates a new instance of VersionEndpointStorage. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations.
func NewVersionEndpointStorage(t mockConstructorTestingTNewVersionEndpointStorage) *VersionEndpointStorage {
	mock := &VersionEndpointStorage{}
	mock.Mock.Test(t)

	t.Cleanup(func() { mock.AssertExpectations(t) })

	return mock
}
