@@ -172,7 +172,6 @@ func TestPullCreate_EmptyChangesWithSameCommits(t *testing.T) {
172
172
173
173
func TestPullStatusDelayCheck (t * testing.T ) {
174
174
onGiteaRun (t , func (t * testing.T , u * url.URL ) {
175
- defer test .MockVariableValue (& setting .IsProd )()
176
175
defer test .MockVariableValue (& setting .Repository .PullRequest .DelayCheckForInactiveDays , 1 )()
177
176
defer test .MockVariableValue (& pull .AddPullRequestToCheckQueue )()
178
177
@@ -203,11 +202,11 @@ func TestPullStatusDelayCheck(t *testing.T) {
203
202
issue3 , checkedPrID := run (t , func (t * testing.T ) {})
204
203
assert .Equal (t , issues .PullRequestStatusMergeable , issue3 .PullRequest .Status )
205
204
assert .Zero (t , checkedPrID )
206
- setting .IsProd = true
207
205
assertReloadingInterval (t , "" ) // the PR is mergeable, so no need to reload the merge box
208
- setting .IsProd = false
209
- assertReloadingInterval (t , "1" ) // make sure dev mode always do merge box reloading, to make sure the UI logic won't break
210
- setting .IsProd = true
206
+
207
+ // setting.IsProd = false // it would cause data-race because the queue handlers might be running and reading its value
208
+ // assertReloadingInterval(t, "1") // make sure dev mode always do merge box reloading, to make sure the UI logic won't break
209
+ // setting.IsProd = true
211
210
212
211
// when base branch changes, PR status should be updated, but it is inactive for long time, so no real check
213
212
issue3 , checkedPrID = run (t , func (t * testing.T ) {
0 commit comments