Search Options

Results per page
Sort
Preferred Languages
Advance

Results 91 - 100 of 1,910 for testLang (0.27 sec)

  1. src/math/bits/bits_test.go

    package bits_test
    
    import (
    	. "math/bits"
    	"runtime"
    	"testing"
    	"unsafe"
    )
    
    func TestUintSize(t *testing.T) {
    	var x uint
    	if want := unsafe.Sizeof(x) * 8; UintSize != want {
    		t.Fatalf("UintSize = %d; want %d", UintSize, want)
    	}
    }
    
    func TestLeadingZeros(t *testing.T) {
    	for i := 0; i < 256; i++ {
    		nlz := tab[i].nlz
    		for k := 0; k < 64-8; k++ {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed Apr 22 20:11:06 UTC 2020
    - 32.5K bytes
    - Viewed (0)
  2. src/hash/maphash/smhasher_test.go

    			b[1] = byte(j)
    			h.addB(b[:2])
    			if !testing.Short() {
    				for k := 0; k < 256; k++ {
    					b[2] = byte(k)
    					h.addB(b[:3])
    				}
    			}
    		}
    	}
    	h.check(t)
    }
    
    // Different length strings of all zeros have distinct hashes.
    func TestSmhasherZeros(t *testing.T) {
    	t.Parallel()
    	N := 256 * 1024
    	if testing.Short() {
    		N = 1024
    	}
    	h := newHashSet()
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri May 03 16:41:38 UTC 2024
    - 11K bytes
    - Viewed (0)
  3. src/expvar/expvar_test.go

    	}
    }
    
    func BenchmarkIntAdd(b *testing.B) {
    	var v Int
    
    	b.RunParallel(func(pb *testing.PB) {
    		for pb.Next() {
    			v.Add(1)
    		}
    	})
    }
    
    func BenchmarkIntSet(b *testing.B) {
    	var v Int
    
    	b.RunParallel(func(pb *testing.PB) {
    		for pb.Next() {
    			v.Set(1)
    		}
    	})
    }
    
    func TestFloat(t *testing.T) {
    	RemoveAll()
    	reqs := NewFloat("requests-float")
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Apr 04 14:46:19 UTC 2024
    - 13.4K bytes
    - Viewed (0)
  4. staging/src/k8s.io/apimachinery/pkg/apis/meta/v1/validation/validation_test.go

    limitations under the License.
    */
    
    package validation
    
    import (
    	"fmt"
    	"strings"
    	"testing"
    
    	metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
    	"k8s.io/apimachinery/pkg/types"
    	"k8s.io/apimachinery/pkg/util/validation/field"
    )
    
    func TestValidateLabels(t *testing.T) {
    	successCases := []map[string]string{
    		{"simple": "bar"},
    		{"now-with-dashes": "bar"},
    		{"1-starts-with-num": "bar"},
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Tue May 02 07:48:42 UTC 2023
    - 15.2K bytes
    - Viewed (0)
  5. src/runtime/callers_test.go

    	return 1 + callersInlined1(b, n-1)
    }
    func callersInlined1(b *testing.B, n int) int { return callersInlined2(b, n) }
    func callersInlined2(b *testing.B, n int) int { return callersInlined3(b, n) }
    func callersInlined3(b *testing.B, n int) int { return callersInlined4(b, n) }
    func callersInlined4(b *testing.B, n int) int { return callersInlined(b, n) }
    
    func callersNoCache(b *testing.B, n int) int {
    	if n <= 0 {
    		pcs := make([]uintptr, 32)
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Aug 28 21:36:31 UTC 2023
    - 12.1K bytes
    - Viewed (0)
  6. src/internal/coverage/cfile/emitdata_test.go

    	// Sub-tests for each API we want to inspect, plus
    	// extras for error testing.
    	t.Run("emitToDir", func(t *testing.T) {
    		t.Parallel()
    		testEmitToDir(t, atomicHarnessPath, dir)
    	})
    	t.Run("emitToWriter", func(t *testing.T) {
    		t.Parallel()
    		testEmitToWriter(t, atomicHarnessPath, dir)
    	})
    	t.Run("emitToNonexistentDir", func(t *testing.T) {
    		t.Parallel()
    		testEmitToNonexistentDir(t, atomicHarnessPath, dir)
    	})
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 23 18:42:28 UTC 2024
    - 16.3K bytes
    - Viewed (0)
  7. pkg/config/validation/agent/extensionprovider_test.go

    // See the License for the specific language governing permissions and
    // limitations under the License.
    
    package agent
    
    import (
    	"testing"
    
    	meshconfig "istio.io/api/mesh/v1alpha1"
    )
    
    func TestValidateExtensionProviderService(t *testing.T) {
    	tests := []struct {
    		service string
    		valid   bool
    		name    string
    	}{
    		{
    			service: "127.0.0.1",
    			valid:   true,
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Wed Apr 17 20:06:41 UTC 2024
    - 13.3K bytes
    - Viewed (0)
  8. pkg/kubelet/cm/cpumanager/state/state_checkpoint_test.go

    import (
    	"os"
    	"reflect"
    	"strings"
    	"testing"
    
    	"github.com/stretchr/testify/require"
    	"k8s.io/kubernetes/pkg/kubelet/checkpointmanager"
    	"k8s.io/kubernetes/pkg/kubelet/cm/containermap"
    	testutil "k8s.io/kubernetes/pkg/kubelet/cm/cpumanager/state/testing"
    	"k8s.io/utils/cpuset"
    )
    
    const testingCheckpoint = "cpumanager_checkpoint_test"
    
    func TestCheckpointStateRestore(t *testing.T) {
    	testCases := []struct {
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Wed May 03 16:26:09 UTC 2023
    - 10.9K bytes
    - Viewed (0)
  9. staging/src/k8s.io/apiserver/pkg/storage/etcd3/watcher_test.go

    	storagetesting "k8s.io/apiserver/pkg/storage/testing"
    	utilfeature "k8s.io/apiserver/pkg/util/feature"
    	featuregatetesting "k8s.io/component-base/featuregate/testing"
    	"k8s.io/utils/ptr"
    )
    
    func TestWatch(t *testing.T) {
    	ctx, store, _ := testSetup(t)
    	storagetesting.RunTestWatch(ctx, t, store)
    }
    
    func TestClusterScopedWatch(t *testing.T) {
    	ctx, store, _ := testSetup(t)
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Wed Apr 24 18:25:29 UTC 2024
    - 12.3K bytes
    - Viewed (1)
  10. src/runtime/mpallocbits_test.go

    }
    
    // Ensures that PallocBits.AllocRange works, which is a fundamental
    // method used for testing and initialization since it's used by
    // makePallocBits.
    func TestPallocBitsAllocRange(t *testing.T) {
    	test := func(t *testing.T, i, n uint, want *PallocBits) {
    		checkPallocBits(t, makePallocBits([]BitRange{{i, n}}), want)
    	}
    	t.Run("OneLow", func(t *testing.T) {
    		want := new(PallocBits)
    		want[0] = 0x1
    		test(t, 0, 1, want)
    	})
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Aug 17 22:00:17 UTC 2020
    - 13.7K bytes
    - Viewed (0)
Back to top