mirror of
https://github.com/tailscale/tailscale.git
synced 2025-08-11 05:07:33 +00:00
cmd/testwrapper/flakytest: clearly describe why TestFlakeRun fails
Fixes #8474 Signed-off-by: Maisem Ali <maisem@tailscale.com>
This commit is contained in:
@@ -28,6 +28,9 @@ func TestIssueFormat(t *testing.T) {
|
||||
}
|
||||
}
|
||||
|
||||
// TestFlakeRun is a test that fails when run in the testwrapper
|
||||
// for the first time, but succeeds on the second run.
|
||||
// It's used to test whether the testwrapper retries flaky tests.
|
||||
func TestFlakeRun(t *testing.T) {
|
||||
Mark(t, "https://github.com/tailscale/tailscale/issues/0") // random issue
|
||||
e := os.Getenv(FlakeAttemptEnv)
|
||||
@@ -35,6 +38,6 @@ func TestFlakeRun(t *testing.T) {
|
||||
t.Skip("not running in testwrapper")
|
||||
}
|
||||
if e == "1" {
|
||||
t.Fatal("failing on purpose")
|
||||
t.Fatal("First run in testwrapper, failing so that test is retried. This is expected.")
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user