prysm-pulse/runtime/version/fork_test.go

30 lines
480 B
Go
Raw Normal View History

2021-10-09 13:27:34 +00:00
package version
import "testing"
func TestVersionString(t *testing.T) {
tests := []struct {
name string
version int
want string
}{
{
name: "phase0",
version: Phase0,
want: "phase0",
},
{
name: "altair",
version: Altair,
want: "altair",
},
}
for _, tt := range tests {
t.Run(tt.name, func(t *testing.T) {
if got := String(tt.version); got != tt.want {
t.Errorf("String() = %v, want %v", got, tt.want)
}
})
}
}