Skip to content

Commit

Permalink
chore: add more test cases for custom protocol testing
Browse files Browse the repository at this point in the history
  • Loading branch information
panjf2000 committed Jan 13, 2023
1 parent 4b6dfdc commit deea03f
Showing 1 changed file with 9 additions and 6 deletions.
15 changes: 9 additions & 6 deletions gnet_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -1427,14 +1427,17 @@ func TestSimServer(t *testing.T) {
t.Run("packet-size=1024,batch=20", func(t *testing.T) {
testSimServer(t, ":7203", 10, 1024, 20)
})
t.Run("packet-size=64*1024,batch=5", func(t *testing.T) {
testSimServer(t, ":7204", 10, 64*1024, 5)
t.Run("packet-size=64*1024,batch=10", func(t *testing.T) {
testSimServer(t, ":7204", 10, 64*1024, 10)
})
t.Run("packet-size=128*1024,batch=3", func(t *testing.T) {
testSimServer(t, ":7205", 10, 128*1024, 3)
t.Run("packet-size=128*1024,batch=5", func(t *testing.T) {
testSimServer(t, ":7205", 10, 128*1024, 5)
})
t.Run("packet-size=1024*1024,batch=1", func(t *testing.T) {
testSimServer(t, ":7206", 10, 1024*1024, 1)
t.Run("packet-size=512*1024,batch=3", func(t *testing.T) {
testSimServer(t, ":7206", 10, 512*1024, 3)
})
t.Run("packet-size=1024*1024,batch=2", func(t *testing.T) {
testSimServer(t, ":7207", 10, 1024*1024, 2)
})
}

Expand Down

0 comments on commit deea03f

Please sign in to comment.