forked from TrueCloudLab/frostfs-node
[#74] Update test of netmap.UpdateState
event parser
Signed-off-by: Alex Vanin <alexey@nspcc.ru>
This commit is contained in:
parent
fec5c81823
commit
b5aef1011b
1 changed files with 7 additions and 7 deletions
|
@ -30,7 +30,7 @@ func TestParseUpdatePeer(t *testing.T) {
|
|||
t.Run("wrong first parameter type", func(t *testing.T) {
|
||||
_, err := ParseUpdatePeer([]smartcontract.Parameter{
|
||||
{
|
||||
Type: smartcontract.ByteArrayType,
|
||||
Type: smartcontract.ArrayType,
|
||||
},
|
||||
})
|
||||
|
||||
|
@ -40,8 +40,8 @@ func TestParseUpdatePeer(t *testing.T) {
|
|||
t.Run("wrong second parameter type", func(t *testing.T) {
|
||||
_, err := ParseUpdatePeer([]smartcontract.Parameter{
|
||||
{
|
||||
Type: smartcontract.ByteArrayType,
|
||||
Value: crypto.MarshalPublicKey(publicKey),
|
||||
Type: smartcontract.IntegerType,
|
||||
Value: state,
|
||||
},
|
||||
{
|
||||
Type: smartcontract.ArrayType,
|
||||
|
@ -53,14 +53,14 @@ func TestParseUpdatePeer(t *testing.T) {
|
|||
|
||||
t.Run("correct behavior", func(t *testing.T) {
|
||||
ev, err := ParseUpdatePeer([]smartcontract.Parameter{
|
||||
{
|
||||
Type: smartcontract.ByteArrayType,
|
||||
Value: crypto.MarshalPublicKey(publicKey),
|
||||
},
|
||||
{
|
||||
Type: smartcontract.IntegerType,
|
||||
Value: state,
|
||||
},
|
||||
{
|
||||
Type: smartcontract.ByteArrayType,
|
||||
Value: crypto.MarshalPublicKey(publicKey),
|
||||
},
|
||||
})
|
||||
require.NoError(t, err)
|
||||
|
||||
|
|
Loading…
Reference in a new issue