mirror of
https://github.com/XTLS/Xray-core.git
synced 2025-07-23 18:34:14 +00:00
Update session_test.go
This commit is contained in:
parent
f14c548451
commit
67f5e24453
1 changed files with 3 additions and 3 deletions
|
@ -9,7 +9,7 @@ import (
|
||||||
func TestSessionManagerAdd(t *testing.T) {
|
func TestSessionManagerAdd(t *testing.T) {
|
||||||
m := NewSessionManager()
|
m := NewSessionManager()
|
||||||
|
|
||||||
s := m.Allocate(0)
|
s := m.Allocate(ClientStrategy{})
|
||||||
if s.ID != 1 {
|
if s.ID != 1 {
|
||||||
t.Error("id: ", s.ID)
|
t.Error("id: ", s.ID)
|
||||||
}
|
}
|
||||||
|
@ -17,7 +17,7 @@ func TestSessionManagerAdd(t *testing.T) {
|
||||||
t.Error("size: ", m.Size())
|
t.Error("size: ", m.Size())
|
||||||
}
|
}
|
||||||
|
|
||||||
s = m.Allocate(0)
|
s = m.Allocate(ClientStrategy{})
|
||||||
if s.ID != 2 {
|
if s.ID != 2 {
|
||||||
t.Error("id: ", s.ID)
|
t.Error("id: ", s.ID)
|
||||||
}
|
}
|
||||||
|
@ -39,7 +39,7 @@ func TestSessionManagerAdd(t *testing.T) {
|
||||||
|
|
||||||
func TestSessionManagerClose(t *testing.T) {
|
func TestSessionManagerClose(t *testing.T) {
|
||||||
m := NewSessionManager()
|
m := NewSessionManager()
|
||||||
s := m.Allocate(0)
|
s := m.Allocate(ClientStrategy{})
|
||||||
|
|
||||||
if m.CloseIfNoSession() {
|
if m.CloseIfNoSession() {
|
||||||
t.Error("able to close")
|
t.Error("able to close")
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue