Commit 720bb0c2 authored by Mitchell Hashimoto's avatar Mitchell Hashimoto

Better comments

parent 03ff35d6
......@@ -15,11 +15,12 @@ func addrPort(address net.Addr) string {
func Test_netListenerInRange(t *testing.T) {
assert := asserts.NewTestingAsserts(t, true)
// Verify it selects an open port
// Open up port 10000 so that we take up a port
L1000, err := net.Listen("tcp", ":10000")
defer L1000.Close()
assert.Nil(err, "should be able to bind to port 10000")
// Verify it selects an open port
L := netListenerInRange(10000, 10005)
assert.NotNil(L, "should have a listener")
assert.Equal(addrPort(L.Addr()), "10001", "should bind to open port")
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment