Search Options

Results per page
Sort
Preferred Languages
Advance

Results 41 - 50 of 190 for Equals (0.25 sec)

  1. cni/pkg/plugin/plugin_test.go

    	testDoAddRun(t, cniConf, testNSName, pod, ns)
    
    	wasCalled := serverClose()
    	// Pod in namespace with enabled ambient label, should be added to mesh
    	assert.Equal(t, wasCalled, true)
    }
    
    func TestCmdAddAmbientEnabledOnNSServerFails(t *testing.T) {
    	url, serverClose := setupCNIEventClientWithMockServer(true)
    
    	cniConf := buildMockConf(true, url)
    
    Go
    - Registered: Wed May 08 22:53:08 GMT 2024
    - Last Modified: Wed May 08 15:58:51 GMT 2024
    - 17.5K bytes
    - Viewed (0)
  2. cmd/os_unix.go

    				break // EOF
    			}
    		}
    		consumed, name, typ, err := parseDirEnt(buf[boff:nbuf])
    		if err != nil {
    			return err
    		}
    		boff += consumed
    		if len(name) == 0 || bytes.Equal(name, []byte{'.'}) || bytes.Equal(name, []byte{'.', '.'}) {
    			continue
    		}
    
    		// Fallback for filesystems (like old XFS) that don't
    		// support Dirent.Type and have DT_UNKNOWN (0) there
    		// instead.
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Thu Jan 18 07:03:17 GMT 2024
    - 9.3K bytes
    - Viewed (0)
  3. cmd/bitrot.go

    	if algo != HighwayHash256S {
    		h := algo.New()
    		if n, err := io.Copy(h, r); err != nil || n != wantSize {
    			// Premature failure in reading the object, file is corrupt.
    			return errFileCorrupt
    		}
    		if !bytes.Equal(h.Sum(nil), want) {
    			return errFileCorrupt
    		}
    		return nil
    	}
    
    	h := algo.New()
    	hashBuf := make([]byte, h.Size())
    	left := wantSize
    
    	// Calculate the size of the bitrot file and compare
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Tue Jan 30 20:43:25 GMT 2024
    - 7.6K bytes
    - Viewed (0)
  4. cmd/benchmark-utils_test.go

    	bucket := getRandomBucketName()
    	// create bucket.
    	err = obj.MakeBucket(context.Background(), bucket, MakeBucketOptions{})
    	if err != nil {
    		b.Fatal(err)
    	}
    
    	// get text data generated for number of bytes equal to object size.
    	textData := generateBytesData(objSize)
    	// generate md5sum for the generated data.
    	// md5sum of the data to written is required as input for PutObject.
    
    	md5hex := getMD5Hash(textData)
    	sha256hex := ""
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Fri Dec 23 15:46:00 GMT 2022
    - 8.2K bytes
    - Viewed (0)
  5. cmd/post-policy_test.go

    	expirationStr := fmt.Sprintf(`"expiration": "%s"`, expiration.Format(iso8601TimeFormat))
    	// Add the bucket condition, only accept buckets equal to the one passed.
    	bucketConditionStr := fmt.Sprintf(`["eq", "$bucket", "%s"]`, bucketName)
    	// Add the key condition, only accept keys equal to the one passed.
    	keyConditionStr := fmt.Sprintf(`["eq", "$key", "%s/upload.txt"]`, objectKey)
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Fri Apr 19 16:45:54 GMT 2024
    - 29.6K bytes
    - Viewed (0)
  6. tests/update_test.go

    	user.Age = 1
    	if err := DB.Save(user).Error; err != nil {
    		t.Errorf("errors happened when update: %v", err)
    	} else if user.Age != 1 {
    		t.Errorf("Age should equals to 1, but got %v", user.Age)
    	} else if user.Active != false {
    		t.Errorf("Active should equals to false, but got %v", user.Active)
    	}
    	checkUpdatedAtChanged("Save", user.UpdatedAt)
    	checkOtherData("Save")
    
    	var result4 User
    Go
    - Registered: Sun May 05 09:35:13 GMT 2024
    - Last Modified: Mon Dec 04 03:50:58 GMT 2023
    - 30.3K bytes
    - Viewed (0)
  7. internal/mountinfo/mountinfo_linux_test.go

    	}
    }
    
    // Helpers for tests.
    
    // Check if two `mountInfo` are equal.
    func mountPointsEqual(a, b mountInfo) bool {
    	if a.Device != b.Device || a.Path != b.Path || a.FSType != b.FSType || !slicesEqual(a.Options, b.Options) || a.Pass != b.Pass || a.Freq != b.Freq {
    		return false
    	}
    	return true
    }
    
    // Checks if two string slices are equal.
    func slicesEqual(a, b []string) bool {
    	if len(a) != len(b) {
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Thu Jan 18 07:03:17 GMT 2024
    - 7.3K bytes
    - Viewed (0)
  8. internal/s3select/sql/timestampfuncs_test.go

    	}
    	for i, tc := range cases {
    		tval, err := parseSQLTimestamp(tc.s)
    		if err != nil {
    			t.Errorf("Case %d: Unexpected error: %v", i+1, err)
    			continue
    		}
    		if !tval.Equal(tc.t) {
    			t.Errorf("Case %d: Expected %v got %v", i+1, tc.t, tval)
    			continue
    		}
    
    		tstr := FormatSQLTimestamp(tc.t)
    		if tstr != tc.s {
    			t.Errorf("Case %d: Expected %s got %s", i+1, tc.s, tstr)
    			continue
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Tue Jun 01 21:59:40 GMT 2021
    - 2.2K bytes
    - Viewed (0)
  9. cni/test/install_cni.go

    }
    
    // checkResult checks if resultFile is equal to expectedFile at each tick until timeout
    func checkResult(result, expected string) error {
    	resultFile, err := os.ReadFile(result)
    	if err != nil {
    		return fmt.Errorf("couldn't read result: %v", err)
    	}
    	expectedFile, err := os.ReadFile(expected)
    	if err != nil {
    		return fmt.Errorf("couldn't read expected: %v", err)
    	}
    	if !bytes.Equal(resultFile, expectedFile) {
    Go
    - Registered: Wed May 08 22:53:08 GMT 2024
    - Last Modified: Fri Jan 26 20:34:28 GMT 2024
    - 12.5K bytes
    - Viewed (0)
  10. cmd/erasure_test.go

    			if _, err = writeDataBlocks(context.Background(), decodedData, decoded, test.dataBlocks, 0, int64(len(data))); err != nil {
    				t.Errorf("Test %d: failed to write data blocks: %v", i, err)
    			}
    			if !bytes.Equal(decodedData.Bytes(), data) {
    				t.Errorf("Test %d: Decoded data does not match original data: got: %v want: %v", i, decodedData.Bytes(), data)
    			}
    		}
    	}
    }
    
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Mon Jul 25 19:37:26 GMT 2022
    - 4.8K bytes
    - Viewed (0)
Back to top