Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 6 of 6 for wantOut (0.12 sec)

  1. src/go/types/api_test.go

    		if sel.Indirect() {
    			direct = "->"
    		}
    		got := [2]string{
    			sel.String(),
    			fmt.Sprintf("%s%v", direct, sel.Index()),
    		}
    		want := wantOut[syntax]
    		if want != got {
    			t.Errorf("%s: got %q; want %q", syntax, got, want)
    		}
    		delete(wantOut, syntax)
    
    		// We must explicitly assert properties of the
    		// Signature's receiver since it doesn't participate
    		// in Identical() or String().
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 23 01:00:11 UTC 2024
    - 94.2K bytes
    - Viewed (0)
  2. src/cmd/compile/internal/types2/api_test.go

    		if sel.Indirect() {
    			direct = "->"
    		}
    		got := [2]string{
    			sel.String(),
    			fmt.Sprintf("%s%v", direct, sel.Index()),
    		}
    		want := wantOut[segment]
    		if want != got {
    			t.Errorf("%s: got %q; want %q", segment, got, want)
    		}
    		delete(wantOut, segment)
    
    		// We must explicitly assert properties of the
    		// Signature's receiver since it doesn't participate
    		// in Identical() or String().
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue May 07 20:08:23 UTC 2024
    - 93.3K bytes
    - Viewed (0)
  3. src/cmd/internal/testdir/testdir_test.go

    // It consists of pairs: full path to source file and its base name.
    func (t test) errorCheck(outStr string, wantAuto bool, fullshort ...string) (err error) {
    	defer func() {
    		if testing.Verbose() && err != nil {
    			t.Logf("gc output:\n%s", outStr)
    		}
    	}()
    	var errs []error
    	out := splitOutput(outStr, wantAuto)
    
    	// Cut directory name.
    	for i := range out {
    		for j := 0; j < len(fullshort); j += 2 {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Mar 21 20:08:06 UTC 2024
    - 57.5K bytes
    - Viewed (0)
  4. src/net/url/url_test.go

    	}
    }
    
    func TestInvalidUserPassword(t *testing.T) {
    	_, err := Parse("http://user^:passwo^******@****.***/")
    	if got, wantsub := fmt.Sprint(err), "net/url: invalid userinfo"; !strings.Contains(got, wantsub) {
    		t.Errorf("error = %q; want substring %q", got, wantsub)
    	}
    }
    
    func TestRejectControlCharacters(t *testing.T) {
    	tests := []string{
    		"http://foo.com/?foo\nbar",
    		"http\r://foo.com/",
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed May 22 22:52:38 UTC 2024
    - 52.1K bytes
    - Viewed (0)
  5. src/os/os_test.go

    	io.WriteString(f, data)
    
    	f.Seek(0, 0)
    	b := make([]byte, 5)
    
    	n, err := f.ReadAt(b, -10)
    
    	const wantsub = "negative offset"
    	if !strings.Contains(fmt.Sprint(err), wantsub) || n != 0 {
    		t.Errorf("ReadAt(-10) = %v, %v; want 0, ...%q...", n, err, wantsub)
    	}
    }
    
    func TestWriteAt(t *testing.T) {
    	t.Parallel()
    
    	f := newFile("TestWriteAt", t)
    	defer Remove(f.Name())
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 23 01:00:11 UTC 2024
    - 83.1K bytes
    - Viewed (0)
  6. src/encoding/json/decode_test.go

    		F1 string `json:"F1,string"`
    	}
    	wantT := T{"aaa\tbbb"}
    
    	b, err := Marshal(wantT)
    	if err != nil {
    		t.Fatalf("Marshal error: %v", err)
    	}
    	var gotT T
    	if err := Unmarshal(b, &gotT); err != nil {
    		t.Fatalf("Unmarshal error: %v", err)
    	}
    	if gotT != wantT {
    		t.Errorf("Marshal/Unmarshal roundtrip:\n\tgot:  %q\n\twant: %q", gotT, wantT)
    	}
    
    	// See golang.org/issues/39555.
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Apr 11 16:40:14 UTC 2024
    - 67.6K bytes
    - Viewed (0)
Back to top