From 5ba70580395702a61c92760f2db59eb3ac321aa1 Mon Sep 17 00:00:00 2001 From: Lunny Xiao Date: Thu, 15 Jan 2026 11:34:08 -0800 Subject: [PATCH] fix test --- tests/integration/repo_webhook_test.go | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/tests/integration/repo_webhook_test.go b/tests/integration/repo_webhook_test.go index 5272073046..a278bddd62 100644 --- a/tests/integration/repo_webhook_test.go +++ b/tests/integration/repo_webhook_test.go @@ -469,7 +469,6 @@ func Test_WebhookPushBranchPatternGlob(t *testing.T) { } for _, tc := range testCases { - tc := tc t.Run(tc.name, func(t *testing.T) { var payloads []api.PushPayload var triggeredEvent string @@ -497,7 +496,7 @@ func Test_WebhookPushBranchPatternGlob(t *testing.T) { payloads = nil triggeredEvent = "" nonMatchFile := fmt.Sprintf("test_webhook_push_glob_%s_nonmatch.md", slug) - testCreateFile(t, session, "user2", "repo1", tc.nonMatchBranch, "", nonMatchFile, fmt.Sprintf("# push filtered by glob %s", tc.name)) + testCreateFile(t, session, "user2", "repo1", tc.nonMatchBranch, "", nonMatchFile, "# push filtered by glob "+tc.name) assert.Empty(t, triggeredEvent) assert.Empty(t, payloads) } @@ -520,7 +519,7 @@ func Test_WebhookPushBranchPatternGlob(t *testing.T) { assert.NoError(t, err) } - testCreateFile(t, session, "user2", "repo1", tc.matchBranch, "", matchFile, fmt.Sprintf("# push allowed by glob %s", tc.name)) + testCreateFile(t, session, "user2", "repo1", tc.matchBranch, "", matchFile, "# push allowed by glob "+tc.name) var afterCommitID string if tc.verifyCommits {