Search Options

Results per page
Sort
Preferred Languages
Advance

Results 31 - 40 of 153 for alice (0.13 sec)

  1. cmd/erasure-decode_test.go

    		return
    	}
    	disks := setup.disks
    	erasure, err := NewErasure(context.Background(), dataBlocks, parityBlocks, blockSize)
    	if err != nil {
    		t.Fatalf("failed to create ErasureStorage: %v", err)
    	}
    	// Prepare a slice of 5MiB with random data.
    	data := make([]byte, 5*humanize.MiByte)
    	length := int64(len(data))
    	_, err = rand.Read(data)
    	if err != nil {
    		t.Fatal(err)
    	}
    
    	writers := make([]io.Writer, len(disks))
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Tue Jan 30 20:43:25 GMT 2024
    - 21.1K bytes
    - Viewed (1)
  2. src/bytes/example_test.go

    	if bytes.Equal(a, b) {
    		// a equal b
    	}
    	if !bytes.Equal(a, b) {
    		// a not equal b
    	}
    }
    
    func ExampleCompare_search() {
    	// Binary search to find a matching byte slice.
    	var needle []byte
    	var haystack [][]byte // Assume sorted
    	i := sort.Search(len(haystack), func(i int) bool {
    		// Return haystack[i] >= needle.
    		return bytes.Compare(haystack[i], needle) >= 0
    	})
    Go
    - Registered: Tue Apr 30 11:13:12 GMT 2024
    - Last Modified: Mon Mar 04 15:54:40 GMT 2024
    - 15K bytes
    - Viewed (1)
  3. cmd/peer-rest-client.go

    			}
    		}
    	}()
    }
    
    // newPeerRestClients creates new peer clients.
    // The two slices will point to the same clients,
    // but 'all' will contain nil entry for local client.
    // The 'all' slice will be in the same order across the cluster.
    func newPeerRestClients(endpoints EndpointServerPools) (remote, all []*peerRESTClient) {
    	if !globalIsDistErasure {
    		// Only useful in distributed setups
    		return nil, nil
    	}
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Thu Apr 04 12:04:40 GMT 2024
    - 25.8K bytes
    - Viewed (0)
  4. src/archive/zip/reader.go

    				} else {
    					entry := fileListEntry{
    						name:  dir,
    						file:  nil,
    						isDir: true,
    					}
    					r.fileList = append(r.fileList, entry)
    				}
    			}
    		}
    
    		sort.Slice(r.fileList, func(i, j int) bool { return fileEntryLess(r.fileList[i].name, r.fileList[j].name) })
    	})
    }
    
    func fileEntryLess(x, y string) bool {
    	xdir, xelem, _ := split(x)
    	ydir, yelem, _ := split(y)
    Go
    - Registered: Tue Apr 30 11:13:12 GMT 2024
    - Last Modified: Fri Oct 13 18:36:46 GMT 2023
    - 27.7K bytes
    - Viewed (0)
  5. src/cmd/asm/internal/arch/arch.go

    	}
    	for i, s := range ppc64.Anames {
    		if obj.As(i) >= obj.A_ARCHSPECIFIC {
    			instructions[s] = obj.As(i) + obj.ABasePPC64
    		}
    	}
    	// The opcodes generated by x/arch's ppc64map are listed in
    	// a separate slice, add them too.
    	for i, s := range ppc64.GenAnames {
    		instructions[s] = obj.As(i) + ppc64.AFIRSTGEN
    	}
    	// Annoying aliases.
    	instructions["BR"] = ppc64.ABR
    	instructions["BL"] = ppc64.ABL
    
    	return &Arch{
    Go
    - Registered: Tue Apr 30 11:13:12 GMT 2024
    - Last Modified: Tue Mar 21 06:51:28 GMT 2023
    - 21.3K bytes
    - Viewed (0)
  6. cmd/test-utils_test.go

    	queryValue["prefix"] = prefixes
    	queryValue["suffix"] = suffixes
    	queryValue["events"] = events
    	return makeTestTargetURL(endPoint, bucketName, "", queryValue)
    }
    
    // getRandomDisks - Creates a slice of N random disks, each of the form - minio-XXX
    func getRandomDisks(n int) ([]string, error) {
    	var erasureDisks []string
    	for i := 0; i < n; i++ {
    		path, err := os.MkdirTemp(globalTestTmpDir, "minio-")
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Fri May 03 17:26:51 GMT 2024
    - 76.2K bytes
    - Viewed (0)
  7. tests/associations_has_many_test.go

    		&Pet{Name: "pet-slice-append-1"},
    		[]*Pet{{Name: "pet-slice-append-2-1"}, {Name: "pet-slice-append-2-2"}},
    		&Pet{Name: "pet-slice-append-3"},
    	)
    
    	AssertAssociationCount(t, users, "Pets", 10, "After Append")
    
    	// Replace -> same as append
    	DB.Model(&users).Association("Pets").Replace(
    		[]*Pet{{Name: "pet-slice-replace-1-1"}, {Name: "pet-slice-replace-1-2"}},
    Go
    - Registered: Sun May 05 09:35:13 GMT 2024
    - Last Modified: Fri Dec 15 08:36:08 GMT 2023
    - 15.6K bytes
    - Viewed (0)
  8. tests/create_test.go

    		CheckPet(t, pet2, pet)
    	})
    
    	t.Run("Slice", func(t *testing.T) {
    		pets := []Pet{{
    			Name: "PolymorphicHasOne-Slice-1",
    			Toy:  Toy{Name: "Toy-PolymorphicHasOne-Slice-1"},
    		}, {
    			Name: "PolymorphicHasOne-Slice-2",
    			Toy:  Toy{Name: "Toy-PolymorphicHasOne-Slice-2"},
    		}, {
    			Name: "PolymorphicHasOne-Slice-3",
    			Toy:  Toy{Name: "Toy-PolymorphicHasOne-Slice-3"},
    		}}
    
    Go
    - Registered: Sun May 05 09:35:13 GMT 2024
    - Last Modified: Tue Mar 19 03:50:28 GMT 2024
    - 26.4K bytes
    - Viewed (0)
  9. callbacks/helper_test.go

    		expect clause.Values
    	}{
    		{
    			name: "Test convert slice of string value",
    			input: []map[string]interface{}{
    				{"name": "my name"},
    			},
    			expect: clause.Values{
    				Columns: []clause.Column{{Name: "name"}},
    				Values:  [][]interface{}{{"my name"}},
    			},
    		},
    		{
    			name: "Test convert slice of int value",
    			input: []map[string]interface{}{
    				{"age": 18},
    			},
    Go
    - Registered: Sun May 05 09:35:13 GMT 2024
    - Last Modified: Tue Mar 05 02:22:57 GMT 2024
    - 3.4K bytes
    - Viewed (0)
  10. tests/joins_test.go

    	}
    
    	CheckUser(t, user2, user)
    }
    
    func TestJoinsForSlice(t *testing.T) {
    	users := []User{
    		*GetUser("slice-joins-1", Config{Company: true, Manager: true, Account: true}),
    		*GetUser("slice-joins-2", Config{Company: true, Manager: true, Account: true}),
    		*GetUser("slice-joins-3", Config{Company: true, Manager: true, Account: true}),
    	}
    
    	DB.Create(&users)
    
    	var userIDs []uint
    Go
    - Registered: Sun May 05 09:35:13 GMT 2024
    - Last Modified: Wed Apr 26 14:19:32 GMT 2023
    - 13.5K bytes
    - Viewed (1)
Back to top