Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit5b799e8

Browse files
committed
reword comments
1 parentf193567 commit5b799e8

File tree

1 file changed

+6
-8
lines changed

1 file changed

+6
-8
lines changed

‎coderd/workspaceapps/apptest/apptest.go‎

Lines changed: 6 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1566,14 +1566,13 @@ func testReconnectingPTY(ctx context.Context, t *testing.T, client *codersdk.Cli
15661566
}
15671567

15681568
// Accessing an app should update the workspace's LastUsedAt.
1569-
// Despite our efforts with the flush channel, this is inherently racy.
1570-
// Retry a few times to ensure that the stats collection pipeline has flushed.
1569+
// NOTE: Despite our efforts with the flush channel, this is inherently racy.
15711570
funcassertWorkspaceLastUsedAtUpdated(t testing.TB,details*Details) {
15721571
t.Helper()
15731572

1574-
<-time.After(testutil.IntervalMedium)
1573+
<-time.After(testutil.IntervalMedium)// Wait for Bicopy to finish.
15751574
details.FlushStats()
1576-
<-time.After(testutil.IntervalMedium)
1575+
// Wait for stats to fully flush.
15771576
require.Eventually(t,func()bool {
15781577
ws,err:=details.SDKClient.Workspace(context.Background(),details.Workspace.ID)
15791578
assert.NoError(t,err)
@@ -1582,14 +1581,13 @@ func assertWorkspaceLastUsedAtUpdated(t testing.TB, details *Details) {
15821581
}
15831582

15841583
// Except when it sometimes shouldn't (e.g. no access)
1585-
// Despite our efforts with the flush channel, this is inherently racy.
1586-
// Wait for a short time to ensure that the stats collection pipeline has flushed.
1584+
// NOTE: Despite our efforts with the flush channel, this is inherently racy.
15871585
funcassertWorkspaceLastUsedAtNotUpdated(t testing.TB,details*Details) {
15881586
t.Helper()
15891587

1590-
<-time.After(testutil.IntervalMedium)//wait forconnections toclose
1588+
<-time.After(testutil.IntervalMedium)//Wait forBicopy tofinish.
15911589
details.FlushStats()
1592-
<-time.After(testutil.IntervalMedium)
1590+
<-time.After(testutil.IntervalMedium)// Wait for stats to fully flush.
15931591
ws,err:=details.SDKClient.Workspace(context.Background(),details.Workspace.ID)
15941592
require.NoError(t,err)
15951593
require.Equal(t,ws.LastUsedAt,details.Workspace.LastUsedAt,"workspace LastUsedAt updated when it should not have been")

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp