diff --git a/backend/tests/job_token_scopes.rs b/backend/tests/job_token_scopes.rs index f4f57baba4..63762eb86e 100644 --- a/backend/tests/job_token_scopes.rs +++ b/backend/tests/job_token_scopes.rs @@ -394,8 +394,7 @@ async fn test_oidc_claim_carries_the_presented_scopes(db: Pool) -> any .execute(&db) .await?; sqlx::query( - "INSERT INTO v2_job_queue (id, workspace_id, running, scheduled_for, tag) - SELECT id, workspace_id, true, now(), tag FROM v2_job WHERE id = ANY($1)", + "UPDATE v2_job_queue q SET tag = j.tag FROM v2_job j WHERE q.id = j.id AND q.id = ANY($1)", ) .bind([Uuid::parse_str(OIDC_JOB)?, Uuid::parse_str(OPEN_JOB)?]) .execute(&db)