mirror of
https://github.com/coder/coder.git
synced 2026-09-24 15:04:27 +08:00
test: rename ExpectMatchContext to ExpectMatch (#25998)
Cleans the last few instances of ExpectMatch that didn't use the new `(ctx, ...)` variant, then deletes the deprecated method and renames `ExpectMatchContext` to drop the `Context` suffix.
This commit is contained in:
@@ -157,7 +157,7 @@ func Test_TaskSend(t *testing.T) {
|
||||
// Wait for the command to observe the initializing state and
|
||||
// start watching the workspace build. This ensures the command
|
||||
// has entered the waiting code path.
|
||||
stdout.ExpectMatchContext(ctx, "Queued")
|
||||
stdout.ExpectMatch(ctx, "Queued")
|
||||
|
||||
// Connect a new agent so the task can transition to active.
|
||||
agentClient := agentsdk.New(setup.userClient.URL, agentsdk.WithFixedToken(setup.agentToken))
|
||||
@@ -208,7 +208,7 @@ func Test_TaskSend(t *testing.T) {
|
||||
|
||||
// Wait for the command to observe the paused state, trigger
|
||||
// a resume, and start watching the workspace build.
|
||||
stdout.ExpectMatchContext(ctx, "Queued")
|
||||
stdout.ExpectMatch(ctx, "Queued")
|
||||
|
||||
// Connect a new agent so the task can transition to active.
|
||||
agentClient := agentsdk.New(setup.userClient.URL, agentsdk.WithFixedToken(setup.agentToken))
|
||||
@@ -265,7 +265,7 @@ func Test_TaskSend(t *testing.T) {
|
||||
|
||||
// Wait for the command to enter the build-watching phase
|
||||
// of waitForTaskIdle.
|
||||
stdout.ExpectMatchContext(ctx, "Waiting for task to become idle")
|
||||
stdout.ExpectMatch(ctx, "Waiting for task to become idle")
|
||||
|
||||
// Wait for ticker creation and release it.
|
||||
tickCall := tickTrap.MustWait(ctx)
|
||||
|
||||
Reference in New Issue
Block a user