mirror of
https://gitlab.com/pulsechaincom/prysm-pulse.git
synced 2024-12-25 12:57:18 +00:00
a9a4bb9163
* move testutil * util pkg * build * gaz Co-authored-by: prylabs-bulldozer[bot] <58059840+prylabs-bulldozer[bot]@users.noreply.github.com>
24 lines
701 B
Go
24 lines
701 B
Go
package fieldtrie
|
|
|
|
import (
|
|
"testing"
|
|
|
|
ethpb "github.com/prysmaticlabs/prysm/proto/prysm/v1alpha1"
|
|
"github.com/prysmaticlabs/prysm/testing/assert"
|
|
)
|
|
|
|
func Test_handlePendingAttestation_OutOfRange(t *testing.T) {
|
|
items := make([]*ethpb.PendingAttestation, 1)
|
|
indices := []uint64{3}
|
|
_, err := handlePendingAttestation(items, indices, false)
|
|
assert.ErrorContains(t, "index 3 greater than number of pending attestations 1", err)
|
|
}
|
|
|
|
func Test_handleEth1DataSlice_OutOfRange(t *testing.T) {
|
|
items := make([]*ethpb.Eth1Data, 1)
|
|
indices := []uint64{3}
|
|
_, err := HandleEth1DataSlice(items, indices, false)
|
|
assert.ErrorContains(t, "index 3 greater than number of items in eth1 data slice 1", err)
|
|
|
|
}
|