MCPcopy
hub / github.com/nats-io/nats.go / RunServerOnPort

Function RunServerOnPort

test/helper_test.go:116–121  ·  view source on GitHub ↗

RunServerOnPort will run a server on the given port.

(port int)

Source from the content-addressed store, hash-verified

114
115// RunServerOnPort will run a server on the given port.
116func RunServerOnPort(port int) *server.Server {
117 opts := natsserver.DefaultTestOptions
118 opts.Port = port
119 opts.Cluster.Name = "testing"
120 return RunServerWithOptions(&opts)
121}
122
123// RunServerWithOptions will run a server with the given options.
124func RunServerWithOptions(opts *server.Options) *server.Server {

Callers 15

TestBasicHeadersFunction · 0.70
TestRequestMsgFunction · 0.70
TestEncBuiltinMarshalIntFunction · 0.70

Calls 1

RunServerWithOptionsFunction · 0.70

Tested by

no test coverage detected