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

package gocb

import (
	gocbcore "github.com/couchbase/gocbcore/v10"
	mock "github.com/stretchr/testify/mock"
)

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

// buildConfig provides a mock function with given fields: cluster
func (_m *mockConnectionManager) buildConfig(cluster *Cluster) error {
	ret := _m.Called(cluster)

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

	return r0
}

// close provides a mock function with given fields:
func (_m *mockConnectionManager) close() error {
	ret := _m.Called()

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

	return r0
}

// connect provides a mock function with given fields:
func (_m *mockConnectionManager) connect() error {
	ret := _m.Called()

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

	return r0
}

// connection provides a mock function with given fields: bucketName
func (_m *mockConnectionManager) connection(bucketName string) (*gocbcore.Agent, error) {
	ret := _m.Called(bucketName)

	var r0 *gocbcore.Agent
	if rf, ok := ret.Get(0).(func(string) *gocbcore.Agent); ok {
		r0 = rf(bucketName)
	} else {
		if ret.Get(0) != nil {
			r0 = ret.Get(0).(*gocbcore.Agent)
		}
	}

	var r1 error
	if rf, ok := ret.Get(1).(func(string) error); ok {
		r1 = rf(bucketName)
	} else {
		r1 = ret.Error(1)
	}

	return r0, r1
}

// getAnalyticsProvider provides a mock function with given fields:
func (_m *mockConnectionManager) getAnalyticsProvider() (analyticsProvider, error) {
	ret := _m.Called()

	var r0 analyticsProvider
	if rf, ok := ret.Get(0).(func() analyticsProvider); ok {
		r0 = rf()
	} else {
		if ret.Get(0) != nil {
			r0 = ret.Get(0).(analyticsProvider)
		}
	}

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

	return r0, r1
}

// getDiagnosticsProvider provides a mock function with given fields: bucketName
func (_m *mockConnectionManager) getDiagnosticsProvider(bucketName string) (diagnosticsProvider, error) {
	ret := _m.Called(bucketName)

	var r0 diagnosticsProvider
	if rf, ok := ret.Get(0).(func(string) diagnosticsProvider); ok {
		r0 = rf(bucketName)
	} else {
		if ret.Get(0) != nil {
			r0 = ret.Get(0).(diagnosticsProvider)
		}
	}

	var r1 error
	if rf, ok := ret.Get(1).(func(string) error); ok {
		r1 = rf(bucketName)
	} else {
		r1 = ret.Error(1)
	}

	return r0, r1
}

// getHTTPProvider provides a mock function with given fields: bucketName
func (_m *mockConnectionManager) getHTTPProvider(bucketName string) (httpProvider, error) {
	ret := _m.Called(bucketName)

	var r0 httpProvider
	if rf, ok := ret.Get(0).(func(string) httpProvider); ok {
		r0 = rf(bucketName)
	} else {
		if ret.Get(0) != nil {
			r0 = ret.Get(0).(httpProvider)
		}
	}

	var r1 error
	if rf, ok := ret.Get(1).(func(string) error); ok {
		r1 = rf(bucketName)
	} else {
		r1 = ret.Error(1)
	}

	return r0, r1
}

// getKvCapabilitiesProvider provides a mock function with given fields: bucketName
func (_m *mockConnectionManager) getKvCapabilitiesProvider(bucketName string) (kvCapabilityVerifier, error) {
	ret := _m.Called(bucketName)

	var r0 kvCapabilityVerifier
	if rf, ok := ret.Get(0).(func(string) kvCapabilityVerifier); ok {
		r0 = rf(bucketName)
	} else {
		if ret.Get(0) != nil {
			r0 = ret.Get(0).(kvCapabilityVerifier)
		}
	}

	var r1 error
	if rf, ok := ret.Get(1).(func(string) error); ok {
		r1 = rf(bucketName)
	} else {
		r1 = ret.Error(1)
	}

	return r0, r1
}

// getKvProvider provides a mock function with given fields: bucketName
func (_m *mockConnectionManager) getKvProvider(bucketName string) (kvProvider, error) {
	ret := _m.Called(bucketName)

	var r0 kvProvider
	if rf, ok := ret.Get(0).(func(string) kvProvider); ok {
		r0 = rf(bucketName)
	} else {
		if ret.Get(0) != nil {
			r0 = ret.Get(0).(kvProvider)
		}
	}

	var r1 error
	if rf, ok := ret.Get(1).(func(string) error); ok {
		r1 = rf(bucketName)
	} else {
		r1 = ret.Error(1)
	}

	return r0, r1
}

// getQueryProvider provides a mock function with given fields:
func (_m *mockConnectionManager) getQueryProvider() (queryProvider, error) {
	ret := _m.Called()

	var r0 queryProvider
	if rf, ok := ret.Get(0).(func() queryProvider); ok {
		r0 = rf()
	} else {
		if ret.Get(0) != nil {
			r0 = ret.Get(0).(queryProvider)
		}
	}

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

	return r0, r1
}

// getSearchProvider provides a mock function with given fields:
func (_m *mockConnectionManager) getSearchProvider() (searchProvider, error) {
	ret := _m.Called()

	var r0 searchProvider
	if rf, ok := ret.Get(0).(func() searchProvider); ok {
		r0 = rf()
	} else {
		if ret.Get(0) != nil {
			r0 = ret.Get(0).(searchProvider)
		}
	}

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

	return r0, r1
}

// getViewProvider provides a mock function with given fields: bucketName
func (_m *mockConnectionManager) getViewProvider(bucketName string) (viewProvider, error) {
	ret := _m.Called(bucketName)

	var r0 viewProvider
	if rf, ok := ret.Get(0).(func(string) viewProvider); ok {
		r0 = rf(bucketName)
	} else {
		if ret.Get(0) != nil {
			r0 = ret.Get(0).(viewProvider)
		}
	}

	var r1 error
	if rf, ok := ret.Get(1).(func(string) error); ok {
		r1 = rf(bucketName)
	} else {
		r1 = ret.Error(1)
	}

	return r0, r1
}

// getWaitUntilReadyProvider provides a mock function with given fields: bucketName
func (_m *mockConnectionManager) getWaitUntilReadyProvider(bucketName string) (waitUntilReadyProvider, error) {
	ret := _m.Called(bucketName)

	var r0 waitUntilReadyProvider
	if rf, ok := ret.Get(0).(func(string) waitUntilReadyProvider); ok {
		r0 = rf(bucketName)
	} else {
		if ret.Get(0) != nil {
			r0 = ret.Get(0).(waitUntilReadyProvider)
		}
	}

	var r1 error
	if rf, ok := ret.Get(1).(func(string) error); ok {
		r1 = rf(bucketName)
	} else {
		r1 = ret.Error(1)
	}

	return r0, r1
}

// openBucket provides a mock function with given fields: bucketName
func (_m *mockConnectionManager) openBucket(bucketName string) error {
	ret := _m.Called(bucketName)

	var r0 error
	if rf, ok := ret.Get(0).(func(string) error); ok {
		r0 = rf(bucketName)
	} else {
		r0 = ret.Error(0)
	}

	return r0
}

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

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

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

	return mock
}
