Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 118 for Equals (0.17 sec)

  1. cmd/iam.go

    			// check if the policy mappings are equal, if they are we don't need
    			// to return an error.
    			policiesDiffer := false
    			firstMappedPolicies := policyMap[origKeys[0]].policySet()
    			for i := 1; i < len(origKeys); i++ {
    				otherMappedPolicies := policyMap[origKeys[i]].policySet()
    				if !firstMappedPolicies.Equals(otherMappedPolicies) {
    					policiesDiffer = true
    					break
    				}
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Thu Apr 25 21:28:16 GMT 2024
    - 71.1K bytes
    - Viewed (1)
  2. cmd/erasure-metadata.go

    	for k, v := range m {
    		switch {
    		case equals(k, ReservedMetadataPrefixLower+ReplicationTimestamp):
    			d.ReplicaTimeStamp, _ = amztime.ParseReplicationTS(v)
    		case equals(k, ReservedMetadataPrefixLower+ReplicaTimestamp):
    			d.ReplicaTimeStamp, _ = amztime.ParseReplicationTS(v)
    		case equals(k, ReservedMetadataPrefixLower+ReplicaStatus):
    			d.ReplicaStatus = replication.StatusType(v)
    		case equals(k, ReservedMetadataPrefixLower+ReplicationStatus):
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Sun Apr 28 17:53:50 GMT 2024
    - 19.2K bytes
    - Viewed (1)
  3. internal/s3select/sql/value_test.go

    				wantOk: a.IsNull() && b.IsNull() && i == 0 && j == 0,
    			})
    		}
    	}
    	for _, tt := range tests {
    		t.Run(tt.name, func(t *testing.T) {
    			if gotOk := tt.fields.a.Equals(tt.fields.b); gotOk != tt.wantOk {
    				t.Errorf("Equals() = %v, want %v", gotOk, tt.wantOk)
    			}
    		})
    	}
    }
    
    func TestValue_CSVString(t *testing.T) {
    	type test struct {
    		name    string
    		want    string
    		wantAlt string
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Mon Mar 06 16:56:10 GMT 2023
    - 12.5K bytes
    - Viewed (0)
  4. cmd/server_test.go

    			c.Errorf("Expected key %s missing from %v", k, res.Header)
    		} else {
    			expectedSet := set.CreateStringSet(expectedMap[k]...)
    			gotSet := set.CreateStringSet(strings.Split(v[0], ", ")...)
    			if !expectedSet.Equals(gotSet) {
    				c.Errorf("Expected value %v, got %v", strings.Join(expectedMap[k], ", "), v)
    			}
    		}
    	}
    }
    
    func (s *TestSuiteCommon) TestObjectDir(c *check) {
    	bucketName := getRandomBucketName()
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Thu Feb 22 06:26:06 GMT 2024
    - 108K bytes
    - Viewed (0)
  5. cmd/sts-handlers_test.go

    		if !(b.Access.Read && b.Access.Write) {
    			c.Fatalf("root user should have read and write access to bucket: %v", b.Name)
    		}
    	}
    	shouldHaveBuckets := set.CreateStringSet(bucket2, bucket)
    	if !gotBuckets.Equals(shouldHaveBuckets) {
    		c.Fatalf("root user should have access to all buckets")
    	}
    
    	// This must fail.
    	if err := userAdmClient.AddUser(ctx, globalActiveCred.AccessKey, globalActiveCred.SecretKey); err == nil {
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Thu Apr 25 15:50:16 GMT 2024
    - 85.7K bytes
    - Viewed (0)
  6. cmd/storage-datatypes.go

    func (fi FileInfo) ReadQuorum(dquorum int) int {
    	if fi.Deleted {
    		return dquorum
    	}
    	return fi.Erasure.DataBlocks
    }
    
    // Equals checks if fi(FileInfo) matches ofi(FileInfo)
    func (fi FileInfo) Equals(ofi FileInfo) (ok bool) {
    	typ1, ok1 := crypto.IsEncrypted(fi.Metadata)
    	typ2, ok2 := crypto.IsEncrypted(ofi.Metadata)
    	if ok1 != ok2 {
    		return false
    	}
    	if typ1 != typ2 {
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Tue Apr 23 17:15:52 GMT 2024
    - 15.3K bytes
    - Viewed (0)
  7. internal/crypto/metadata_test.go

    		}
    		if !bytes.Equal(sealedKey.Key[:], test.SealedKey.Key[:]) {
    			t.Errorf("Test %d: got sealed key '%v' - want sealed key '%v'", i, sealedKey.Key, test.SealedKey.Key)
    		}
    		if !bytes.Equal(sealedKey.IV[:], test.SealedKey.IV[:]) {
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Fri Feb 02 00:13:57 GMT 2024
    - 18.7K bytes
    - Viewed (0)
  8. internal/kms/single-key_test.go

    	if err != nil {
    		t.Fatalf("Failed to generate key: %v", err)
    	}
    	plaintext, err := KMS.DecryptKey(key.KeyID, key.Ciphertext, Context{})
    	if err != nil {
    		t.Fatalf("Failed to decrypt key: %v", err)
    	}
    	if !bytes.Equal(key.Plaintext, plaintext) {
    		t.Fatalf("Decrypted key does not match generated one: got %x - want %x", key.Plaintext, plaintext)
    	}
    }
    
    func TestDecryptKey(t *testing.T) {
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Tue Jul 19 01:54:27 GMT 2022
    - 3K bytes
    - Viewed (0)
  9. cmd/data-usage_test.go

    		}
    	}
    }
    
    // equalAsJSON returns whether the values are equal when encoded as JSON.
    func equalAsJSON(a, b interface{}) bool {
    	aj, err := json.Marshal(a)
    	if err != nil {
    		panic(err)
    	}
    	bj, err := json.Marshal(b)
    	if err != nil {
    		panic(err)
    	}
    	return bytes.Equal(aj, bj)
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Wed Mar 27 15:10:40 GMT 2024
    - 14.1K bytes
    - Viewed (0)
  10. internal/hash/reader_test.go

    	if err != nil {
    		t.Fatal(err)
    	}
    	if !bytes.Equal(r.MD5Current(), expectedMD5) {
    		t.Errorf("Expected md5hex \"e2fc714c4727ee9395f324cd2e7f331f\", got %s", hex.EncodeToString(r.MD5Current()))
    	}
    	expectedSHA256, err := hex.DecodeString("88d4266fd4e6338d13b845fcf289579d209c897823b9217da3e161936f031589")
    	if err != nil {
    		t.Fatal(err)
    	}
    	if !bytes.Equal(r.SHA256(), expectedSHA256) {
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Mon Sep 18 17:00:54 GMT 2023
    - 10.3K bytes
    - Viewed (0)
Back to top