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

package mocks

import (
	context "context"

	database "github.com/canonical/microceph/microceph/database"
	interfaces "github.com/canonical/microceph/microceph/interfaces"

	mock "github.com/stretchr/testify/mock"
)

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

// AddNew provides a mock function with given fields: ctx, s, service, groupID, groupConfig, serviceInfo
func (_m *GroupedServiceQueryIntf) AddNew(ctx context.Context, s interfaces.StateInterface, service string, groupID string, groupConfig interface{}, serviceInfo interface{}) error {
	ret := _m.Called(ctx, s, service, groupID, groupConfig, serviceInfo)

	if len(ret) == 0 {
		panic("no return value specified for AddNew")
	}

	var r0 error
	if rf, ok := ret.Get(0).(func(context.Context, interfaces.StateInterface, string, string, interface{}, interface{}) error); ok {
		r0 = rf(ctx, s, service, groupID, groupConfig, serviceInfo)
	} else {
		r0 = ret.Error(0)
	}

	return r0
}

// ExistsOnHost provides a mock function with given fields: ctx, s, service, groupID
func (_m *GroupedServiceQueryIntf) ExistsOnHost(ctx context.Context, s interfaces.StateInterface, service string, groupID string) (bool, error) {
	ret := _m.Called(ctx, s, service, groupID)

	if len(ret) == 0 {
		panic("no return value specified for ExistsOnHost")
	}

	var r0 bool
	var r1 error
	if rf, ok := ret.Get(0).(func(context.Context, interfaces.StateInterface, string, string) (bool, error)); ok {
		return rf(ctx, s, service, groupID)
	}
	if rf, ok := ret.Get(0).(func(context.Context, interfaces.StateInterface, string, string) bool); ok {
		r0 = rf(ctx, s, service, groupID)
	} else {
		r0 = ret.Get(0).(bool)
	}

	if rf, ok := ret.Get(1).(func(context.Context, interfaces.StateInterface, string, string) error); ok {
		r1 = rf(ctx, s, service, groupID)
	} else {
		r1 = ret.Error(1)
	}

	return r0, r1
}

// GetGroupedServices provides a mock function with given fields: ctx, s
func (_m *GroupedServiceQueryIntf) GetGroupedServices(ctx context.Context, s interfaces.StateInterface) ([]database.GroupedService, error) {
	ret := _m.Called(ctx, s)

	if len(ret) == 0 {
		panic("no return value specified for GetGroupedServices")
	}

	var r0 []database.GroupedService
	var r1 error
	if rf, ok := ret.Get(0).(func(context.Context, interfaces.StateInterface) ([]database.GroupedService, error)); ok {
		return rf(ctx, s)
	}
	if rf, ok := ret.Get(0).(func(context.Context, interfaces.StateInterface) []database.GroupedService); ok {
		r0 = rf(ctx, s)
	} else {
		if ret.Get(0) != nil {
			r0 = ret.Get(0).([]database.GroupedService)
		}
	}

	if rf, ok := ret.Get(1).(func(context.Context, interfaces.StateInterface) error); ok {
		r1 = rf(ctx, s)
	} else {
		r1 = ret.Error(1)
	}

	return r0, r1
}

// GetGroupedServicesOnHost provides a mock function with given fields: ctx, s
func (_m *GroupedServiceQueryIntf) GetGroupedServicesOnHost(ctx context.Context, s interfaces.StateInterface) ([]database.GroupedService, error) {
	ret := _m.Called(ctx, s)

	if len(ret) == 0 {
		panic("no return value specified for GetGroupedServicesOnHost")
	}

	var r0 []database.GroupedService
	var r1 error
	if rf, ok := ret.Get(0).(func(context.Context, interfaces.StateInterface) ([]database.GroupedService, error)); ok {
		return rf(ctx, s)
	}
	if rf, ok := ret.Get(0).(func(context.Context, interfaces.StateInterface) []database.GroupedService); ok {
		r0 = rf(ctx, s)
	} else {
		if ret.Get(0) != nil {
			r0 = ret.Get(0).([]database.GroupedService)
		}
	}

	if rf, ok := ret.Get(1).(func(context.Context, interfaces.StateInterface) error); ok {
		r1 = rf(ctx, s)
	} else {
		r1 = ret.Error(1)
	}

	return r0, r1
}

// RemoveForHost provides a mock function with given fields: ctx, s, service, groupID
func (_m *GroupedServiceQueryIntf) RemoveForHost(ctx context.Context, s interfaces.StateInterface, service string, groupID string) error {
	ret := _m.Called(ctx, s, service, groupID)

	if len(ret) == 0 {
		panic("no return value specified for RemoveForHost")
	}

	var r0 error
	if rf, ok := ret.Get(0).(func(context.Context, interfaces.StateInterface, string, string) error); ok {
		r0 = rf(ctx, s, service, groupID)
	} else {
		r0 = ret.Error(0)
	}

	return r0
}

// NewGroupedServiceQueryIntf creates a new instance of GroupedServiceQueryIntf. 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 NewGroupedServiceQueryIntf(t interface {
	mock.TestingT
	Cleanup(func())
}) *GroupedServiceQueryIntf {
	mock := &GroupedServiceQueryIntf{}
	mock.Mock.Test(t)

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

	return mock
}
