mirror of
https://gitlab.com/pulsechaincom/prysm-pulse.git
synced 2024-12-22 11:32:09 +00:00
2728b83f6a
* Starting * Done * Fix more tests * Fix test * Fix test * fix up * building * requirement * gaz * builds * rem deadcode * fix * fix up * removed checked method * Update service_test.go Co-authored-by: Raul Jordan <raul@prysmaticlabs.com> Co-authored-by: Nishant Das <nishdas93@gmail.com>
28 lines
631 B
Go
28 lines
631 B
Go
package testutil
|
|
|
|
import (
|
|
"math/big"
|
|
)
|
|
|
|
// MockExecutionChainInfoFetcher is a fake implementation of the powchain.ChainInfoFetcher
|
|
type MockExecutionChainInfoFetcher struct {
|
|
CurrEndpoint string
|
|
CurrError error
|
|
}
|
|
|
|
func (*MockExecutionChainInfoFetcher) GenesisExecutionChainInfo() (uint64, *big.Int) {
|
|
return uint64(0), &big.Int{}
|
|
}
|
|
|
|
func (*MockExecutionChainInfoFetcher) ExecutionClientConnected() bool {
|
|
return true
|
|
}
|
|
|
|
func (m *MockExecutionChainInfoFetcher) ExecutionClientEndpoint() string {
|
|
return m.CurrEndpoint
|
|
}
|
|
|
|
func (m *MockExecutionChainInfoFetcher) ExecutionClientConnectionErr() error {
|
|
return m.CurrError
|
|
}
|