Files
prysm/time/slots/testing/mock.go
Bastin 92bd211e4d upgrade v6 to v7 (#15989)
* upgrade v6 to v7

* changelog

* update-go-ssz
2025-11-06 16:16:23 +00:00

19 lines
440 B
Go

// Package testing includes useful mocks for slot tickers in unit tests.
package testing
import "github.com/OffchainLabs/prysm/v7/consensus-types/primitives"
// MockTicker defines a useful struct for mocking the Ticker interface
// from the slotutil package.
type MockTicker struct {
Channel chan primitives.Slot
}
// C --
func (m *MockTicker) C() <-chan primitives.Slot {
return m.Channel
}
// Done --
func (_ *MockTicker) Done() {}