Search Options

Results per page
Sort
Preferred Languages
Advance

Results 101 - 110 of 137 for roundTrip (0.14 sec)

  1. staging/src/k8s.io/apimachinery/pkg/runtime/serializer/versioning/versioning.go

    		// to give it a chance to convert the list items if needed.
    		if _, ok := obj.(*unstructured.UnstructuredList); !ok {
    			// avoid conversion roundtrip if GVK is the right one already or is empty (yes, this is a hack, but the old behaviour we rely on in kubectl)
    			objGVK := obj.GetObjectKind().GroupVersionKind()
    			if len(objGVK.Version) == 0 {
    				return encodeFn(obj, w)
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Fri Mar 03 06:51:04 UTC 2023
    - 9.8K bytes
    - Viewed (0)
  2. staging/src/k8s.io/apimachinery/pkg/util/proxy/upgradeaware_test.go

    				t.Errorf("Unexpected proxy handler error: %v", responder.err)
    			}
    		}()
    	}
    }
    
    type RoundTripperFunc func(req *http.Request) (*http.Response, error)
    
    func (fn RoundTripperFunc) RoundTrip(req *http.Request) (*http.Response, error) {
    	return fn(req)
    }
    
    func TestProxyUpgrade(t *testing.T) {
    
    	localhostPool := x509.NewCertPool()
    	if !localhostPool.AppendCertsFromPEM(localhostCert) {
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Wed May 10 07:29:34 UTC 2023
    - 39.4K bytes
    - Viewed (0)
  3. pkg/apis/flowcontrol/validation/validation.go

    	allErrs := apivalidation.ValidateObjectMeta(&pl.ObjectMeta, false, ValidatePriorityLevelConfigurationName, field.NewPath("metadata"))
    
    	// the roundtrip annotation is only for use in v1beta3, and after
    	// conversion, the internal object should not have the roundtrip
    	// annotation, so we should forbid it, if it's set.
    	if _, ok := pl.ObjectMeta.Annotations[flowcontrolv1beta3.PriorityLevelPreserveZeroConcurrencySharesKey]; ok {
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Mon Oct 30 22:22:51 UTC 2023
    - 26.7K bytes
    - Viewed (0)
  4. staging/src/k8s.io/apiserver/plugin/pkg/authenticator/token/oidc/oidc.go

    	urlToRewrite string
    }
    
    func (t *discoveryURLRoundTripper) RoundTrip(req *http.Request) (*http.Response, error) {
    	if req.Method == http.MethodGet && req.URL.String() == t.urlToRewrite {
    		clone := req.Clone(req.Context())
    		clone.Host = ""
    		clone.URL = t.discoveryURL
    		return t.base.RoundTrip(clone)
    	}
    	return t.base.RoundTrip(req)
    }
    
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Sat Mar 09 19:29:33 UTC 2024
    - 37.9K bytes
    - Viewed (0)
  5. staging/src/k8s.io/apimachinery/pkg/util/managedfields/internal/managedfields_test.go

    	}
    	if _, err := DecodeManagedFields(unmarshaled); err == nil {
    		t.Fatal("Expect decoding error but got none")
    	}
    }
    
    // TestRoundTripManagedFields will roundtrip ManagedFields from the wire format
    // (api format) to the format used by sigs.k8s.io/structured-merge-diff and back
    func TestRoundTripManagedFields(t *testing.T) {
    	tests := []string{
    		`null
    `,
    		`- apiVersion: v1
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Wed Mar 08 21:44:00 UTC 2023
    - 16.9K bytes
    - Viewed (0)
  6. cmd/metacache-server-pool.go

    				return entries, io.EOF
    			}
    			if c.status == scanStateError || c.status == scanStateNone {
    				o.ID = ""
    				o.Create = false
    				o.debugln("scan status", c.status, " - waiting a roundtrip to create")
    			} else {
    				// Continue listing
    				o.ID = c.id
    				go func(meta metacache) {
    					// Continuously update while we wait.
    					t := time.NewTicker(metacacheMaxClientWait / 10)
    Registered: Sun Jun 16 00:44:34 UTC 2024
    - Last Modified: Thu May 23 01:12:23 UTC 2024
    - 12.9K bytes
    - Viewed (0)
  7. src/crypto/internal/edwards25519/field/fe_test.go

    		},
    	}
    
    	for _, tt := range tests {
    		b := tt.fe.Bytes()
    		fe, _ := new(Element).SetBytes(tt.b)
    		if !bytes.Equal(b, tt.b) || fe.Equal(&tt.fe) != 1 {
    			t.Errorf("Failed fixed roundtrip: %v", tt)
    		}
    	}
    }
    
    func swapEndianness(buf []byte) []byte {
    	for i := 0; i < len(buf)/2; i++ {
    		buf[i], buf[len(buf)-i-1] = buf[len(buf)-i-1], buf[i]
    	}
    	return buf
    }
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Aug 28 17:26:17 UTC 2023
    - 13.9K bytes
    - Viewed (0)
  8. staging/src/k8s.io/apimachinery/pkg/util/proxy/transport_test.go

    		if err != nil {
    			t.Errorf("%v: Unexpected error: %v", name, err)
    			return
    		}
    		if item.reqHost != "" {
    			req.Host = item.reqHost
    		}
    		resp, err := item.transport.RoundTrip(req)
    		if err != nil {
    			t.Errorf("%v: Unexpected error: %v", name, err)
    			return
    		}
    		if item.redirect != "" {
    			// Check that redirect URLs get rewritten properly.
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Wed May 10 07:29:34 UTC 2023
    - 13.8K bytes
    - Viewed (0)
  9. src/encoding/json/encode_test.go

    	NumberStr  Number  `json:",string"`
    }
    
    func TestRoundtripStringTag(t *testing.T) {
    	tests := []struct {
    		CaseName
    		in   StringTag
    		want string // empty to just test that we roundtrip
    	}{{
    		CaseName: Name("AllTypes"),
    		in: StringTag{
    			BoolStr:    true,
    			IntStr:     42,
    			UintptrStr: 44,
    			StrStr:     "xzbit",
    			NumberStr:  "46",
    		},
    		want: `{
    	"BoolStr": "true",
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 23 18:42:28 UTC 2024
    - 29.4K bytes
    - Viewed (0)
  10. staging/src/k8s.io/apimachinery/pkg/api/apitesting/roundtrip/compatibility.go

    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    See the License for the specific language governing permissions and
    limitations under the License.
    */
    
    package roundtrip
    
    import (
    	"bytes"
    	gojson "encoding/json"
    	"io/ioutil"
    	"os"
    	"os/exec"
    	"path/filepath"
    	"reflect"
    	"sort"
    	"strings"
    	"testing"
    
    	"github.com/google/go-cmp/cmp"
    
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Wed Mar 08 16:38:32 UTC 2023
    - 17.8K bytes
    - Viewed (0)
Back to top