Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 1 of 1 for TestParsePort (0.23 sec)

  1. pilot/pkg/model/context_test.go

    	if err != nil {
    		return nil, err
    	}
    
    	pbs := &structpb.Struct{}
    	if err := protomarshal.Unmarshal(b, pbs); err != nil {
    		return nil, err
    	}
    
    	return pbs, nil
    }
    
    func TestParsePort(t *testing.T) {
    	if port := model.ParsePort("localhost:3000"); port != 3000 {
    		t.Errorf("ParsePort(localhost:3000) => Got %d, want 3000", port)
    	}
    	if port := model.ParsePort("localhost"); port != 0 {
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Fri Apr 05 23:51:52 UTC 2024
    - 11.2K bytes
    - Viewed (0)
Back to top