MCPcopy Create free account
hub / github.com/devfeel/dotweb / TestNewHttpServer

Function TestNewHttpServer

server_test.go:11–24  ·  view source on GitHub ↗

check httpServer

(t *testing.T)

Source from the content-addressed store, hash-verified

9
10// check httpServer
11func TestNewHttpServer(t *testing.T) {
12 server := NewHttpServer()
13
14 test.NotNil(t, server.router)
15 test.NotNil(t, server.stdServer)
16 test.NotNil(t, server.ServerConfig)
17 test.NotNil(t, server.SessionConfig)
18 test.NotNil(t, server.lock_session)
19 test.NotNil(t, server.binder)
20 // Skip pool checks to avoid sync.Pool copy warning
21 test.Equal(t, false, server.IsOffline())
22
23 // t.Log("is offline:",server.IsOffline())
24}
25
26func TestSesionConfig(t *testing.T) {
27 server := NewHttpServer()

Callers

nothing calls this directly

Calls 4

IsOfflineMethod · 0.95
NotNilFunction · 0.92
EqualFunction · 0.92
NewHttpServerFunction · 0.85

Tested by

no test coverage detected