Skip to content

Commit

Permalink
changed test case for getting machines
Browse files Browse the repository at this point in the history
  • Loading branch information
mfdeveloper508 committed Oct 16, 2023
1 parent 7ae611a commit 4dd1d98
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions pkg/server/service_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -54,13 +54,10 @@ func TestService__GetMachine(t *testing.T) {
m := NewMachine(mockBaseDesKey())
s.CreateMachine(m)

s.CreateMachine(NewMachine(mockBaseAesKey()))

machines := s.GetMachines()
require.Equal(t, "042666b49184cfa368de9628d0397bc9", machines[0].TransactionKey)
require.Equal(t, "4f21b565bad9835e112b6465635eae44", machines[1].TransactionKey)
require.Equal(t, 1, len(machines))

machine, err := s.GetMachine(m.InitialKey)
machine, err := s.GetMachine(machines[0].InitialKey)
require.NoError(t, err)
require.Equal(t, "042666b49184cfa368de9628d0397bc9", machine.TransactionKey)
}
Expand Down

0 comments on commit 4dd1d98

Please sign in to comment.