MCPcopy
hub / github.com/tailscale/tailscale / buildTestWrapper

Function buildTestWrapper

cmd/testwrapper/testwrapper_test.go:43–53  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

41}
42
43func buildTestWrapper() (string, error) {
44 dir, err := os.MkdirTemp("", "testwrapper")
45 if err != nil {
46 return "", fmt.Errorf("making temp dir: %w", err)
47 }
48 _, err = exec.Command("go", "build", "-o", dir, ".").Output()
49 if err != nil {
50 return "", fmt.Errorf("go build: %w", err)
51 }
52 return filepath.Join(dir, "testwrapper"), nil
53}
54
55// TestRetry covers a Mark()'d test that fails on the first attempt and passes
56// on retry: the wrapper must exit 0, emit a flakytest failures JSON line with

Callers 1

cmdTestwrapperFunction · 0.85

Calls 2

ErrorfMethod · 0.65
OutputMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…