Corrected unit tests and integration tests

This commit is contained in:
hopleus 2024-10-17 14:24:54 +03:00
parent ed1042076a
commit a446f63744
2 changed files with 3 additions and 4 deletions

View file

@ -202,8 +202,7 @@ func (s *Suite) TestListPeersWithoutNonAuthorized(c *check.C) {
} }
node := types.Node{ node := types.Node{
// nolint:G115 ID: types.NodeID(uint64(index)), // nolint:G115
ID: types.NodeID(uint64(index)),
MachineKey: machineKey.Public(), MachineKey: machineKey.Public(),
NodeKey: nodeKey.Public(), NodeKey: nodeKey.Public(),
Hostname: "testnode" + strconv.Itoa(index), Hostname: "testnode" + strconv.Itoa(index),

View file

@ -1303,7 +1303,7 @@ func TestNodeApproveCommand(t *testing.T) {
strconv.FormatUint(listAll[idx].GetId(), 10), strconv.FormatUint(listAll[idx].GetId(), 10),
}, },
) )
assert.NoError(t, err) assertNoErr(t, err)
} }
var listAllAfterApprove []v1.Node var listAllAfterApprove []v1.Node
@ -1318,7 +1318,7 @@ func TestNodeApproveCommand(t *testing.T) {
}, },
&listAllAfterApprove, &listAllAfterApprove,
) )
assert.NoError(t, err) assertNoErr(t, err)
assert.Len(t, listAllAfterApprove, 5) assert.Len(t, listAllAfterApprove, 5)