aboutsummaryrefslogtreecommitdiff
path: root/hotline/transaction_handlers_test.go
diff options
context:
space:
mode:
authorjhalter <868228+jhalter@users.noreply.github.com>2022-05-26 18:25:57 -0700
committerGitHub <noreply@github.com>2022-05-26 18:25:57 -0700
commitc697d13aac49ede1258762b4cf41d9bdcabb4b27 (patch)
tree315487896b2e350d2af183d0662b3ccd7487bbdf /hotline/transaction_handlers_test.go
parent301990cbc43d93dddb3ba308c490a55ac03fa915 (diff)
parentbd1ce11306527514218acbe0d12f7bcc23114239 (diff)
Merge pull request #13 from jhalter/fix_ghost_user_bug
Fix multiple issues with v1.8+ login sequence
Diffstat (limited to 'hotline/transaction_handlers_test.go')
-rw-r--r--hotline/transaction_handlers_test.go14
1 files changed, 10 insertions, 4 deletions
diff --git a/hotline/transaction_handlers_test.go b/hotline/transaction_handlers_test.go
index 56968a1..7c5ee43 100644
--- a/hotline/transaction_handlers_test.go
+++ b/hotline/transaction_handlers_test.go
@@ -5,7 +5,6 @@ import (
"io/fs"
"math/rand"
"os"
- "reflect"
"testing"
)
@@ -227,12 +226,21 @@ func TestHandleGetUserNameList(t *testing.T) {
Icon: &[]byte{0, 2},
Flags: &[]byte{0, 3},
UserName: []byte{0, 4},
+ Agreed: true,
},
uint16(2): {
ID: &[]byte{0, 2},
Icon: &[]byte{0, 2},
Flags: &[]byte{0, 3},
UserName: []byte{0, 4},
+ Agreed: true,
+ },
+ uint16(3): {
+ ID: &[]byte{0, 3},
+ Icon: &[]byte{0, 2},
+ Flags: &[]byte{0, 3},
+ UserName: []byte{0, 4},
+ Agreed: false,
},
},
},
@@ -272,9 +280,7 @@ func TestHandleGetUserNameList(t *testing.T) {
t.Errorf("HandleGetUserNameList() error = %v, wantErr %v", err, tt.wantErr)
return
}
- if !reflect.DeepEqual(got, tt.want) {
- t.Errorf("HandleGetUserNameList() got = %v, want %v", got, tt.want)
- }
+ assert.Equal(t, tt.want, got)
})
}
}