(t *testing.T)
| 35 | |
| 36 | } |
| 37 | func TestNewP2PServer(t *testing.T) { |
| 38 | fmt.Println("Start test new p2pserver...") |
| 39 | |
| 40 | p2p := NewServer() |
| 41 | |
| 42 | if p2p.GetVersion() != common.PROTOCOL_VERSION { |
| 43 | t.Error("TestNewP2PServer p2p version error", p2p.GetVersion()) |
| 44 | } |
| 45 | |
| 46 | if p2p.GetVersion() != common.PROTOCOL_VERSION { |
| 47 | t.Error("TestNewP2PServer p2p version error") |
| 48 | } |
| 49 | sync := p2p.GetPort() |
| 50 | if sync != 20338 { |
| 51 | t.Error("TestNewP2PServer sync port error") |
| 52 | } |
| 53 | } |
nothing calls this directly
no test coverage detected