Search Options

Results per page
Sort
Preferred Languages
Advance

Results 51 - 60 of 66 for Failure (0.53 sec)

  1. src/os/exec/exec_test.go

    	if n != len(buf) || err != nil || string(buf) != "O:hi\n" {
    		t.Fatalf("ReadFull = %d, %v, %q", n, err, buf[:n])
    	}
    	go cancel()
    
    	if err := c.Wait(); err == nil {
    		t.Fatal("expected Wait failure")
    	}
    }
    
    func TestContextCancel(t *testing.T) {
    	if runtime.GOOS == "netbsd" && runtime.GOARCH == "arm64" {
    		maySkipHelperCommand("cat")
    		testenv.SkipFlaky(t, 42061)
    	}
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri Jun 07 20:13:53 UTC 2024
    - 48.4K bytes
    - Viewed (0)
  2. src/cmd/go/internal/toolchain/select.go

    	// and reinvoking the current binary.
    	// The special cases =loop and =mismatch skip the
    	// setting of TESTGO_VERSION so that it looks like we
    	// accidentally invoked the wrong toolchain,
    	// to test detection of that failure mode.
    	switch TestVersionSwitch {
    	case "switch":
    		os.Setenv("TESTGO_VERSION", gotoolchain)
    		fallthrough
    	case "loop", "mismatch":
    		exe, err := os.Executable()
    		if err != nil {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue May 07 17:25:05 UTC 2024
    - 23.4K bytes
    - Viewed (0)
  3. src/testing/fuzz.go

    			}
    			return nil
    		}); err != nil {
    			// Internal errors are marked with f.Fail; user code may call this too, before F.Fuzz.
    			// The worker will exit with fuzzWorkerExitCode, indicating this is a failure
    			// (and 'go test' should exit non-zero) but a failing input should not be recorded.
    			f.Errorf("communicating with fuzzing coordinator: %v", err)
    		}
    
    	default:
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri Apr 26 22:55:25 UTC 2024
    - 22.9K bytes
    - Viewed (0)
  4. src/os/file.go

    // If the file does not exist, WriteFile creates it with permissions perm (before umask);
    // otherwise WriteFile truncates it before writing, without changing permissions.
    // Since WriteFile requires multiple system calls to complete, a failure mid-operation
    // can leave the file in a partially written state.
    func WriteFile(name string, data []byte, perm FileMode) error {
    	f, err := OpenFile(name, O_WRONLY|O_CREATE|O_TRUNC, perm)
    	if err != nil {
    		return err
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri Apr 26 23:07:37 UTC 2024
    - 25.4K bytes
    - Viewed (0)
  5. src/runtime/map_test.go

    				break
    			}
    		}
    	}
    }
    
    // Issue 8410
    func TestMapSparseIterOrder(t *testing.T) {
    	// Run several rounds to increase the probability
    	// of failure. One is not enough.
    NextRound:
    	for round := 0; round < 10; round++ {
    		m := make(map[int]bool)
    		// Add 1000 items, remove 980.
    		for i := 0; i < 1000; i++ {
    			m[i] = true
    		}
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 23 01:00:11 UTC 2024
    - 33.5K bytes
    - Viewed (0)
  6. src/time/tick_test.go

    	// Using After(10ms) but waiting for 500ms to read the channel
    	// should produce a time from start+10ms, not start+500ms.
    	// Make sure it does.
    	// To avoid flakes due to very long scheduling delays,
    	// require 10 failures in a row before deciding something is wrong.
    	for range 10 {
    		start := Now()
    		c := After(10 * Millisecond)
    		Sleep(500 * Millisecond)
    		dt := (<-c).Sub(start)
    		if dt < 400*Millisecond {
    			return
    		}
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Jun 11 17:10:37 UTC 2024
    - 14.7K bytes
    - Viewed (0)
  7. src/internal/testenv/testenv.go

    	}
    }
    
    func SkipFlakyNet(t testing.TB) {
    	t.Helper()
    	if v, _ := strconv.ParseBool(os.Getenv("GO_BUILDER_FLAKY_NET")); v {
    		t.Skip("skipping test on builder known to have frequent network failures")
    	}
    }
    
    // CPUIsSlow reports whether the CPU running the test is suspected to be slow.
    func CPUIsSlow() bool {
    	switch runtime.GOARCH {
    	case "arm", "mips", "mipsle", "mips64", "mips64le", "wasm":
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri May 03 16:41:38 UTC 2024
    - 15.7K bytes
    - Viewed (0)
  8. src/index/suffixarray/suffixarray_test.go

    		for x[i] = 1; x[i] <= byte(max); x[i]++ {
    			testRec(t, x, i+1, max, numFail, build)
    		}
    		return
    	}
    
    	if !testSA(t, x, build) {
    		*numFail++
    		if *numFail >= 10 {
    			t.Errorf("stopping after %d failures", *numFail)
    			t.FailNow()
    		}
    	}
    }
    
    // testSA tests the suffix array build function on the input x.
    // It constructs the suffix array and then checks that it is correct.
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 23 01:00:11 UTC 2024
    - 14.1K bytes
    - Viewed (0)
  9. src/cmd/compile/internal/types2/resolver.go

    				if i := strings.LastIndex(name, "/"); i >= 0 {
    					name = name[i+1:]
    				}
    				imp = NewPackage(path, name)
    			}
    			// continue to use the package as best as we can
    			imp.fake = true // avoid follow-up lookup failures
    		}
    	}
    
    	// package should be complete or marked fake, but be cautious
    	if imp.complete || imp.fake {
    		check.impMap[key] = imp
    		// Once we've formatted an error message, keep the pkgPathMap
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Apr 18 14:10:44 UTC 2024
    - 26.3K bytes
    - Viewed (0)
  10. src/go/types/resolver.go

    				if i := strings.LastIndex(name, "/"); i >= 0 {
    					name = name[i+1:]
    				}
    				imp = NewPackage(path, name)
    			}
    			// continue to use the package as best as we can
    			imp.fake = true // avoid follow-up lookup failures
    		}
    	}
    
    	// package should be complete or marked fake, but be cautious
    	if imp.complete || imp.fake {
    		check.impMap[key] = imp
    		// Once we've formatted an error message, keep the pkgPathMap
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri May 17 16:22:59 UTC 2024
    - 26.1K bytes
    - Viewed (0)
Back to top