// Code generated by moq; DO NOT EDIT.
// github.com/matryer/moq

package fake

import (
	"sync"

	"sigs.k8s.io/controller-runtime/pkg/client"
)

// ListItemMock is a mock implementation of common.ListItem.
//
//	func TestSomethingThatUsesListItem(t *testing.T) {
//
//		// make and configure a mocked common.ListItem
//		mockedListItem := &ListItemMock{
//			GetItemsFunc: func() []client.Object {
//				panic("mock out the GetItems method")
//			},
//		}
//
//		// use mockedListItem in code that requires common.ListItem
//		// and then make assertions.
//
//	}
type ListItemMock struct {
	// GetItemsFunc mocks the GetItems method.
	GetItemsFunc func() []client.Object

	// calls tracks calls to the methods.
	calls struct {
		// GetItems holds details about calls to the GetItems method.
		GetItems []struct {
		}
	}
	lockGetItems sync.RWMutex
}

// GetItems calls GetItemsFunc.
func (mock *ListItemMock) GetItems() []client.Object {
	if mock.GetItemsFunc == nil {
		panic("ListItemMock.GetItemsFunc: method is nil but ListItem.GetItems was just called")
	}
	callInfo := struct {
	}{}
	mock.lockGetItems.Lock()
	mock.calls.GetItems = append(mock.calls.GetItems, callInfo)
	mock.lockGetItems.Unlock()
	return mock.GetItemsFunc()
}

// GetItemsCalls gets all the calls that were made to GetItems.
// Check the length with:
//
//	len(mockedListItem.GetItemsCalls())
func (mock *ListItemMock) GetItemsCalls() []struct {
} {
	var calls []struct {
	}
	mock.lockGetItems.RLock()
	calls = mock.calls.GetItems
	mock.lockGetItems.RUnlock()
	return calls
}
