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

package time

import (
	time "time"

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

	stdtime "github.com/projectcalico/calico/lib/std/time"
)

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

// After provides a mock function with given fields: t
func (_m *Clock) After(t time.Duration) <-chan time.Time {
	ret := _m.Called(t)

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

	var r0 <-chan time.Time
	if rf, ok := ret.Get(0).(func(time.Duration) <-chan time.Time); ok {
		r0 = rf(t)
	} else {
		if ret.Get(0) != nil {
			r0 = ret.Get(0).(<-chan time.Time)
		}
	}

	return r0
}

// NewTicker provides a mock function with given fields: d
func (_m *Clock) NewTicker(d time.Duration) stdtime.Ticker {
	ret := _m.Called(d)

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

	var r0 stdtime.Ticker
	if rf, ok := ret.Get(0).(func(time.Duration) stdtime.Ticker); ok {
		r0 = rf(d)
	} else {
		if ret.Get(0) != nil {
			r0 = ret.Get(0).(stdtime.Ticker)
		}
	}

	return r0
}

// NewTimer provides a mock function with given fields: d
func (_m *Clock) NewTimer(d time.Duration) stdtime.Timer {
	ret := _m.Called(d)

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

	var r0 stdtime.Timer
	if rf, ok := ret.Get(0).(func(time.Duration) stdtime.Timer); ok {
		r0 = rf(d)
	} else {
		if ret.Get(0) != nil {
			r0 = ret.Get(0).(stdtime.Timer)
		}
	}

	return r0
}

// Now provides a mock function with no fields
func (_m *Clock) Now() time.Time {
	ret := _m.Called()

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

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

	return r0
}

// Since provides a mock function with given fields: t
func (_m *Clock) Since(t time.Time) time.Duration {
	ret := _m.Called(t)

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

	var r0 time.Duration
	if rf, ok := ret.Get(0).(func(time.Time) time.Duration); ok {
		r0 = rf(t)
	} else {
		r0 = ret.Get(0).(time.Duration)
	}

	return r0
}

// Sleep provides a mock function with given fields: d
func (_m *Clock) Sleep(d time.Duration) {
	_m.Called(d)
}

// Unix provides a mock function with given fields: sec, nsec
func (_m *Clock) Unix(sec int64, nsec int64) time.Time {
	ret := _m.Called(sec, nsec)

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

	var r0 time.Time
	if rf, ok := ret.Get(0).(func(int64, int64) time.Time); ok {
		r0 = rf(sec, nsec)
	} else {
		r0 = ret.Get(0).(time.Time)
	}

	return r0
}

// Until provides a mock function with given fields: t
func (_m *Clock) Until(t time.Time) time.Duration {
	ret := _m.Called(t)

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

	var r0 time.Duration
	if rf, ok := ret.Get(0).(func(time.Time) time.Duration); ok {
		r0 = rf(t)
	} else {
		r0 = ret.Get(0).(time.Duration)
	}

	return r0
}

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

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

	return mock
}
