Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 1 of 1 for eth0 (0.12 sec)

  1. cmd/net_test.go

    	}{
    		{"localhost", false},
    		{"localhost:9000", false},
    		{"example.com", false},
    		{"http://192.168.1.0", false},
    		{"http://192.168.1.0:9000", false},
    		{"192.168.1.0", true},
    		{"[2001:3984:3989::20%eth0]:9000", true},
    	}
    
    	for _, testCase := range testCases {
    		ret := isHostIP(testCase.args)
    		if testCase.expectedResult != ret {
    			t.Fatalf("expected: %v , got: %v", testCase.expectedResult, ret)
    		}
    	}
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Fri Apr 19 08:43:09 GMT 2024
    - 9.3K bytes
    - Viewed (0)
Back to top