runtime: correct a log message in TestCleanupLost
Updates #76929
diff --git a/src/runtime/mcleanup_test.go b/src/runtime/mcleanup_test.go
index 5afe85e..bbffc31 100644
--- a/src/runtime/mcleanup_test.go
+++ b/src/runtime/mcleanup_test.go
@@ -333,7 +333,7 @@
runtime.GC()
runtime.BlockUntilEmptyCleanupQueue(int64(10 * time.Second))
if got := int(got.Load()); got != want {
- t.Errorf("expected %d cleanups to be executed, got %d", got, want)
+ t.Errorf("expected %d cleanups to be executed, got %d", want, got)
}
}
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
t.Errorf("expected %d cleanups to be executed, got %d", want, got)As long as we're touching this anyhow, why don't we follow https://go.dev/wiki/CodeReviewComments#useful-test-failures and use
```suggestion
t.Errorf("%d cleanups executed, expected %d", got, want)
```
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
Do you think that the result of `runtime.BlockUntilEmptyCleanupQueue` should be checked in case of a timeout and non-empty queue?
t.Errorf("expected %d cleanups to be executed, got %d", want, got)As long as we're touching this anyhow, why don't we follow https://go.dev/wiki/CodeReviewComments#useful-test-failures and use
```suggestion
t.Errorf("%d cleanups executed, expected %d", got, want)
```
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
Do you think that the result of `runtime.BlockUntilEmptyCleanupQueue` should be checked in case of a timeout and non-empty queue?
Acknowledged
t.Errorf("expected %d cleanups to be executed, got %d", want, got)Lin LinAs long as we're touching this anyhow, why don't we follow https://go.dev/wiki/CodeReviewComments#useful-test-failures and use
```suggestion
t.Errorf("%d cleanups executed, expected %d", got, want)
```
Thanks, Ian. I don't know there is such a wiki.
Done
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |