MCPcopy Index your code
hub / github.com/gopherdata/gophernotes / runTest

Function runTest

kernel_test.go:43–67  ·  view source on GitHub ↗

runTest initializes the environment for the tests and allows for the proper exit if the test fails or succeeds.

(m *testing.M)

Source from the content-addressed store, hash-verified

41// runTest initializes the environment for the tests and allows for
42// the proper exit if the test fails or succeeds.
43func runTest(m *testing.M) int {
44 // Parse the connection info.
45 var connInfo ConnectionInfo
46
47 connData, err := ioutil.ReadFile(connectionFile)
48 if err != nil {
49 log.Fatal(err)
50 }
51
52 if err = json.Unmarshal(connData, &connInfo); err != nil {
53 log.Fatal(err)
54 }
55
56 // Store the connection parameters globally for use by the test client.
57 connectionKey = connInfo.Key
58 transport = connInfo.Transport
59 ip = connInfo.IP
60 shellPort = connInfo.ShellPort
61 iopubPort = connInfo.IOPubPort
62
63 // Start the kernel.
64 go runKernel(connectionFile)
65
66 return m.Run()
67}
68
69//==============================================================================
70

Callers 1

TestMainFunction · 0.85

Calls 1

runKernelFunction · 0.85

Tested by

no test coverage detected