Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 7 of 7 for tt (0.17 sec)

  1. src/cmd/api/api_test.go

    		},
    	}
    	for _, tt := range tests {
    		buf := new(strings.Builder)
    		gotOK := compareAPI(buf, tt.features, tt.required, tt.exception)
    		if gotOK != tt.ok {
    			t.Errorf("%s: ok = %v; want %v", tt.name, gotOK, tt.ok)
    		}
    		if got := buf.String(); got != tt.out {
    			t.Errorf("%s: output differs\nGOT:\n%s\nWANT:\n%s", tt.name, got, tt.out)
    		}
    	}
    }
    
    Go
    - Registered: Tue Apr 30 11:13:12 GMT 2024
    - Last Modified: Thu Jan 04 17:31:12 GMT 2024
    - 7.1K bytes
    - Viewed (0)
  2. src/bufio/bufio_test.go

    		},
    	}
    	for _, tt := range tests {
    		br := NewReaderSize(tt.r, tt.bufSize)
    		if tt.peekSize > 0 {
    			peekBuf, err := br.Peek(tt.peekSize)
    			if err != nil {
    				t.Errorf("%s: Peek(%d): %v", tt.name, tt.peekSize, err)
    				continue
    			}
    			if len(peekBuf) != tt.peekSize {
    				t.Errorf("%s: len(Peek(%d)) = %v; want %v", tt.name, tt.peekSize, len(peekBuf), tt.peekSize)
    				continue
    			}
    		}
    Go
    - Registered: Tue Apr 30 11:13:12 GMT 2024
    - Last Modified: Fri Feb 10 18:56:01 GMT 2023
    - 51.5K bytes
    - Viewed (0)
  3. src/bytes/reader_test.go

    	}
    
    	for i, tt := range tests {
    		pos, err := r.Seek(tt.off, tt.seek)
    		if err == nil && tt.seekerr != "" {
    			t.Errorf("%d. want seek error %q", i, tt.seekerr)
    			continue
    		}
    		if err != nil && err.Error() != tt.seekerr {
    			t.Errorf("%d. seek error = %q; want %q", i, err.Error(), tt.seekerr)
    			continue
    		}
    		if tt.wantpos != 0 && tt.wantpos != pos {
    Go
    - Registered: Tue Apr 30 11:13:12 GMT 2024
    - Last Modified: Mon Dec 13 18:45:54 GMT 2021
    - 8K bytes
    - Viewed (0)
  4. src/bytes/bytes_test.go

    			t.Errorf("last appended result was %s; want %s", x, want)
    		}
    
    		s := Join(a, nil)
    		if string(s) != tt.s {
    			t.Errorf(`Join(Split(%q, %q, %d), %q) = %q`, tt.s, tt.sep, tt.n, tt.sep, s)
    		}
    		if tt.n < 0 {
    			b := SplitAfter([]byte(tt.s), []byte(tt.sep))
    			if !reflect.DeepEqual(a, b) {
    Go
    - Registered: Tue Apr 30 11:13:12 GMT 2024
    - Last Modified: Wed Jan 24 16:07:25 GMT 2024
    - 56.2K bytes
    - Viewed (0)
  5. src/cmd/cgo/gcc.go

    			if t.C.Empty() {
    				t.C.Set(csyntax)
    			}
    			t.Align = align
    			tt := *t
    			if tag != "" {
    				tt.C = &TypeRepr{"struct %s", []interface{}{tag}}
    			}
    			tt.Go = g
    			if c.incompleteStructs[tag] {
    				tt.Go = c.Ident(incomplete)
    			}
    			typedef[name.Name] = &tt
    		}
    
    	case *dwarf.TypedefType:
    		// Record typedef for printing.
    		if dt.Name == "_GoString_" {
    Go
    - Registered: Tue Apr 30 11:13:12 GMT 2024
    - Last Modified: Thu Nov 02 16:43:23 GMT 2023
    - 97K bytes
    - Viewed (0)
  6. src/bytes/compare_test.go

    }
    
    func TestCompare(t *testing.T) {
    	for _, tt := range compareTests {
    		numShifts := 16
    		buffer := make([]byte, len(tt.b)+numShifts)
    		// vary the input alignment of tt.b
    		for offset := 0; offset <= numShifts; offset++ {
    			shiftedB := buffer[offset : len(tt.b)+offset]
    			copy(shiftedB, tt.b)
    			cmp := Compare(tt.a, shiftedB)
    			if cmp != tt.i {
    Go
    - Registered: Tue Apr 30 11:13:12 GMT 2024
    - Last Modified: Thu Jul 13 23:11:42 GMT 2023
    - 6.8K bytes
    - Viewed (0)
  7. src/arena/arena_test.go

    import (
    	"arena"
    	"testing"
    )
    
    type T1 struct {
    	n int
    }
    type T2 [1 << 20]byte // 1MiB
    
    func TestSmoke(t *testing.T) {
    	a := arena.NewArena()
    	defer a.Free()
    
    	tt := arena.New[T1](a)
    	tt.n = 1
    
    	ts := arena.MakeSlice[T1](a, 99, 100)
    	if len(ts) != 99 {
    		t.Errorf("Slice() len = %d, want 99", len(ts))
    	}
    	if cap(ts) != 100 {
    		t.Errorf("Slice() cap = %d, want 100", cap(ts))
    	}
    Go
    - Registered: Tue Apr 30 11:13:12 GMT 2024
    - Last Modified: Wed Oct 12 20:23:36 GMT 2022
    - 742 bytes
    - Viewed (0)
Back to top