mirror of
https://github.com/OffchainLabs/prysm.git
synced 2026-01-09 15:37:56 -05:00
Fix typos in test code (#14991)
* Update keymanager_test.go * Update fork_test.go * Update README.md * Update README.md
This commit is contained in:
@@ -38,7 +38,7 @@ The request JSON object is a non-nested object with the following properties. Th
|
|||||||
|memory_node_bytes_total |long |system |(currently unsupported) |?? |
|
|memory_node_bytes_total |long |system |(currently unsupported) |?? |
|
||||||
|memory_node_bytes_free |long |system |(currently unsupported) |?? |
|
|memory_node_bytes_free |long |system |(currently unsupported) |?? |
|
||||||
|memory_node_bytes_cached |long |system |(currently unsupported) |?? |
|
|memory_node_bytes_cached |long |system |(currently unsupported) |?? |
|
||||||
|memory_node_bytes_bufferd |long |system |(currently unsupported) |?? |
|
|memory_node_bytes_buffers |long |system |(currently unsupported) |?? |
|
||||||
|disk_node_bytes_total |long |system |(currently unsupported) |?? |
|
|disk_node_bytes_total |long |system |(currently unsupported) |?? |
|
||||||
|disk_node_bytes_free |long |system |(currently unsupported) |?? |
|
|disk_node_bytes_free |long |system |(currently unsupported) |?? |
|
||||||
|disk_node_io_seconds |long |system |(currently unsupported) |?? |
|
|disk_node_io_seconds |long |system |(currently unsupported) |?? |
|
||||||
|
|||||||
@@ -255,13 +255,13 @@ func TestNextForkData(t *testing.T) {
|
|||||||
name string
|
name string
|
||||||
setConfg func()
|
setConfg func()
|
||||||
currEpoch primitives.Epoch
|
currEpoch primitives.Epoch
|
||||||
wantedForkVerison [4]byte
|
wantedForkVersion [4]byte
|
||||||
wantedEpoch primitives.Epoch
|
wantedEpoch primitives.Epoch
|
||||||
}{
|
}{
|
||||||
{
|
{
|
||||||
name: "genesis fork",
|
name: "genesis fork",
|
||||||
currEpoch: 0,
|
currEpoch: 0,
|
||||||
wantedForkVerison: [4]byte{'A', 'B', 'C', 'D'},
|
wantedForkVersion: [4]byte{'A', 'B', 'C', 'D'},
|
||||||
wantedEpoch: math.MaxUint64,
|
wantedEpoch: math.MaxUint64,
|
||||||
setConfg: func() {
|
setConfg: func() {
|
||||||
cfg = cfg.Copy()
|
cfg = cfg.Copy()
|
||||||
@@ -275,7 +275,7 @@ func TestNextForkData(t *testing.T) {
|
|||||||
{
|
{
|
||||||
name: "altair pre-fork",
|
name: "altair pre-fork",
|
||||||
currEpoch: 5,
|
currEpoch: 5,
|
||||||
wantedForkVerison: [4]byte{'A', 'B', 'C', 'F'},
|
wantedForkVersion: [4]byte{'A', 'B', 'C', 'F'},
|
||||||
wantedEpoch: 10,
|
wantedEpoch: 10,
|
||||||
setConfg: func() {
|
setConfg: func() {
|
||||||
cfg = cfg.Copy()
|
cfg = cfg.Copy()
|
||||||
@@ -291,7 +291,7 @@ func TestNextForkData(t *testing.T) {
|
|||||||
{
|
{
|
||||||
name: "altair on fork",
|
name: "altair on fork",
|
||||||
currEpoch: 10,
|
currEpoch: 10,
|
||||||
wantedForkVerison: [4]byte{'A', 'B', 'C', 'F'},
|
wantedForkVersion: [4]byte{'A', 'B', 'C', 'F'},
|
||||||
wantedEpoch: math.MaxUint64,
|
wantedEpoch: math.MaxUint64,
|
||||||
setConfg: func() {
|
setConfg: func() {
|
||||||
cfg = cfg.Copy()
|
cfg = cfg.Copy()
|
||||||
@@ -308,7 +308,7 @@ func TestNextForkData(t *testing.T) {
|
|||||||
{
|
{
|
||||||
name: "altair post fork",
|
name: "altair post fork",
|
||||||
currEpoch: 20,
|
currEpoch: 20,
|
||||||
wantedForkVerison: [4]byte{'A', 'B', 'C', 'F'},
|
wantedForkVersion: [4]byte{'A', 'B', 'C', 'F'},
|
||||||
wantedEpoch: math.MaxUint64,
|
wantedEpoch: math.MaxUint64,
|
||||||
setConfg: func() {
|
setConfg: func() {
|
||||||
cfg = cfg.Copy()
|
cfg = cfg.Copy()
|
||||||
@@ -325,7 +325,7 @@ func TestNextForkData(t *testing.T) {
|
|||||||
{
|
{
|
||||||
name: "3 forks, pre-fork, 1st fork",
|
name: "3 forks, pre-fork, 1st fork",
|
||||||
currEpoch: 5,
|
currEpoch: 5,
|
||||||
wantedForkVerison: [4]byte{'A', 'B', 'C', 'F'},
|
wantedForkVersion: [4]byte{'A', 'B', 'C', 'F'},
|
||||||
wantedEpoch: 10,
|
wantedEpoch: 10,
|
||||||
setConfg: func() {
|
setConfg: func() {
|
||||||
cfg = cfg.Copy()
|
cfg = cfg.Copy()
|
||||||
@@ -341,7 +341,7 @@ func TestNextForkData(t *testing.T) {
|
|||||||
{
|
{
|
||||||
name: "3 forks, pre-fork, 2nd fork",
|
name: "3 forks, pre-fork, 2nd fork",
|
||||||
currEpoch: 50,
|
currEpoch: 50,
|
||||||
wantedForkVerison: [4]byte{'A', 'B', 'C', 'Z'},
|
wantedForkVersion: [4]byte{'A', 'B', 'C', 'Z'},
|
||||||
wantedEpoch: 100,
|
wantedEpoch: 100,
|
||||||
setConfg: func() {
|
setConfg: func() {
|
||||||
cfg = cfg.Copy()
|
cfg = cfg.Copy()
|
||||||
@@ -357,7 +357,7 @@ func TestNextForkData(t *testing.T) {
|
|||||||
{
|
{
|
||||||
name: "3 forks, on fork",
|
name: "3 forks, on fork",
|
||||||
currEpoch: 100,
|
currEpoch: 100,
|
||||||
wantedForkVerison: [4]byte{'A', 'B', 'C', 'Z'},
|
wantedForkVersion: [4]byte{'A', 'B', 'C', 'Z'},
|
||||||
wantedEpoch: math.MaxUint64,
|
wantedEpoch: math.MaxUint64,
|
||||||
setConfg: func() {
|
setConfg: func() {
|
||||||
cfg = cfg.Copy()
|
cfg = cfg.Copy()
|
||||||
@@ -376,8 +376,8 @@ func TestNextForkData(t *testing.T) {
|
|||||||
tt.setConfg()
|
tt.setConfg()
|
||||||
fVersion, fEpoch, err := NextForkData(tt.currEpoch)
|
fVersion, fEpoch, err := NextForkData(tt.currEpoch)
|
||||||
assert.NoError(t, err)
|
assert.NoError(t, err)
|
||||||
if fVersion != tt.wantedForkVerison {
|
if fVersion != tt.wantedForkVersion {
|
||||||
t.Errorf("NextForkData() fork version = %v, want %v", fVersion, tt.wantedForkVerison)
|
t.Errorf("NextForkData() fork version = %v, want %v", fVersion, tt.wantedForkVersion)
|
||||||
}
|
}
|
||||||
if fEpoch != tt.wantedEpoch {
|
if fEpoch != tt.wantedEpoch {
|
||||||
t.Errorf("NextForkData() fork epoch = %v, want %v", fEpoch, tt.wantedEpoch)
|
t.Errorf("NextForkData() fork epoch = %v, want %v", fEpoch, tt.wantedEpoch)
|
||||||
|
|||||||
@@ -23,7 +23,7 @@ const (
|
|||||||
|
|
||||||
// We test that using a '25th word' mnemonic passphrase leads to different
|
// We test that using a '25th word' mnemonic passphrase leads to different
|
||||||
// public keys derived than not specifying the passphrase.
|
// public keys derived than not specifying the passphrase.
|
||||||
func TestDerivedKeymanager_MnemnonicPassphrase_DifferentResults(t *testing.T) {
|
func TestDerivedKeymanager_MnemonicPassphrase_DifferentResults(t *testing.T) {
|
||||||
ctx := context.Background()
|
ctx := context.Background()
|
||||||
wallet := &mock.Wallet{
|
wallet := &mock.Wallet{
|
||||||
Files: make(map[string]map[string][]byte),
|
Files: make(map[string]map[string][]byte),
|
||||||
|
|||||||
Reference in New Issue
Block a user