Search Options

Results per page
Sort
Preferred Languages
Advance

Results 11 - 20 of 1,535 for Comparer (0.46 sec)

  1. src/cmd/compile/internal/types2/predicates.go

    }
    
    // An ifacePair is a node in a stack of interface type pairs compared for identity.
    type ifacePair struct {
    	x, y *Interface
    	prev *ifacePair
    }
    
    func (p *ifacePair) identical(q *ifacePair) bool {
    	return p.x == q.x && p.y == q.y || p.x == q.y && p.y == q.x
    }
    
    // A comparer is used to compare types.
    type comparer struct {
    	ignoreTags     bool // if set, identical ignores struct tags
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 23 03:01:18 UTC 2024
    - 17.5K bytes
    - Viewed (0)
  2. pkg/test/util/assert/assert.go

    var cmpOpts = []cmp.Option{protocmp.Transform(), cmpopts.EquateEmpty(), compareErrors}
    
    // Compare compares two objects and returns and error if they are not the same.
    func Compare[T any](a, b T) error {
    	if !cmp.Equal(a, b, opts(a)...) {
    		return fmt.Errorf("found diff: %v\nLeft: %v\nRight: %v", cmp.Diff(a, b, opts(a)...), a, b)
    	}
    	return nil
    }
    
    // Equal compares two objects and fails if they are not the same.
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Mon Dec 18 17:21:50 UTC 2023
    - 4.4K bytes
    - Viewed (0)
  3. pkg/controller/certificates/authority/authority_test.go

    					"Version",
    					"MaxPathLen",
    				),
    				diff.IgnoreUnset(),
    				cmp.Transformer("RoundTime", func(x time.Time) time.Time {
    					return x.Truncate(time.Second)
    				}),
    				cmp.Comparer(func(x, y *url.URL) bool {
    					return ((x == nil) && (y == nil)) || x.String() == y.String()
    				}),
    			}
    			if !cmp.Equal(*cert, test.want, opts) {
    				t.Errorf("unexpected diff: %v", cmp.Diff(*cert, test.want, opts))
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Wed Jun 23 19:36:11 UTC 2021
    - 7.3K bytes
    - Viewed (0)
  4. pkg/serviceaccount/openidmetadata_test.go

    			}
    
    			ks := &jose.JSONWebKeySet{}
    			if err := json.NewDecoder(resp.Body).Decode(ks); err != nil {
    				t.Fatalf("Decode(_) = %v, want: <nil>", err)
    			}
    
    			bigIntComparer := cmp.Comparer(
    				func(x, y *big.Int) bool {
    					return x.Cmp(y) == 0
    				})
    			if !cmp.Equal(tt.WantKeys, ks.Keys, bigIntComparer) {
    				t.Errorf("unexpected diff in JWKS keys (-want, +got): %v",
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Thu Mar 02 01:53:17 UTC 2023
    - 14.8K bytes
    - Viewed (0)
  5. staging/src/k8s.io/apiextensions-apiserver/pkg/controller/openapi/v2/conversion_test.go

    				if equal := reflect.DeepEqual(*out, *test.expected); !equal && !test.expectDiff {
    					t.Errorf("unexpected result:\n  want=%v\n   got=%v\n\n%s", *test.expected, *out, cmp.Diff(*test.expected, *out, cmp.Comparer(refEqual)))
    				} else if equal && test.expectDiff {
    					t.Errorf("expected diff, but didn't get any")
    				}
    			}
    		})
    	}
    }
    
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Fri Jun 02 14:34:26 UTC 2023
    - 23.2K bytes
    - Viewed (0)
  6. staging/src/k8s.io/apiserver/pkg/server/options/encryptionconfig/config_test.go

    			if tt.kmsv1 != kmsUsed.v1Used {
    				t.Errorf("incorrect kms v1 detection: want=%v got=%v", tt.kmsv1, kmsUsed.v1Used)
    			}
    
    			if d := cmp.Diff(tt.want, got,
    				cmp.Comparer(func(a, b *kmsPluginProbe) bool {
    					return *a == *b
    				}),
    				cmp.Comparer(func(a, b *kmsv2PluginProbe) bool {
    					return *a == *b
    				}),
    			); d != "" {
    				t.Fatalf("HealthzConfig mismatch (-want +got):\n%s", d)
    			}
    		})
    	}
    }
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Thu May 16 16:56:39 UTC 2024
    - 72.3K bytes
    - Viewed (0)
  7. docs/fr/docs/async.md

    Mais toutes ces fonctionnalités d'utilisation de code asynchrone avec `async` et `await` sont souvent résumées comme l'utilisation des *coroutines*. On peut comparer cela à la principale fonctionnalité clé de Go, les "Goroutines".
    
    ## Conclusion
    
    Reprenons la phrase du début de la page :
    
    Registered: Mon Jun 17 08:32:26 UTC 2024
    - Last Modified: Sun Mar 31 23:52:53 UTC 2024
    - 24K bytes
    - Viewed (0)
  8. docs/fr/docs/alternatives.md

        Pour plus de détails, consultez la section [Déploiement](deployment/index.md){.internal-link target=_blank}.
    
    ## Benchmarks et vitesse
    
    Registered: Mon Jun 17 08:32:26 UTC 2024
    - Last Modified: Fri Mar 22 01:42:11 UTC 2024
    - 27.5K bytes
    - Viewed (0)
  9. pilot/pkg/model/telemetry.go

    	return class == networking.ListenerClassSidecarInbound || class == networking.ListenerClassGateway
    }
    
    // Equal compares two computedTelemetries for equality. This was created to help with testing. Because of the nature of the structs being compared,
    // it is safer to use cmp.Equal as opposed to reflect.DeepEqual. Also, because of the way the structs are generated, it is not possible to use
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Wed May 15 18:14:09 UTC 2024
    - 35.2K bytes
    - Viewed (0)
  10. pilot/pkg/model/service.go

    	return p.f(ep, proxy)
    }
    
    func (p *endpointDiscoverabilityPolicyImpl) String() string {
    	return p.name
    }
    
    var endpointDiscoverabilityPolicyImplCmpOpt = cmp.Comparer(func(x, y endpointDiscoverabilityPolicyImpl) bool {
    	return x.String() == y.String()
    })
    
    func (p *endpointDiscoverabilityPolicyImpl) CmpOpts() []cmp.Option {
    	return []cmp.Option{endpointDiscoverabilityPolicyImplCmpOpt}
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Wed May 29 02:03:58 UTC 2024
    - 46.3K bytes
    - Viewed (0)
Back to top