mirror of
				https://github.com/go-gitea/gitea.git
				synced 2025-10-26 12:27:06 +00:00 
			
		
		
		
	Skip known flaky queue tests on CI environment (#24443)
				
					
				
			Backport of https://github.com/go-gitea/gitea/pull/24419 to 1.19.
This commit is contained in:
		| @@ -4,6 +4,7 @@ | ||||
| package queue | ||||
|  | ||||
| import ( | ||||
| 	"os" | ||||
| 	"sync" | ||||
| 	"testing" | ||||
| 	"time" | ||||
| @@ -101,6 +102,9 @@ func TestChannelQueue_Batch(t *testing.T) { | ||||
| } | ||||
|  | ||||
| func TestChannelQueue_Pause(t *testing.T) { | ||||
| 	if os.Getenv("CI") != "" { | ||||
| 		t.Skip("Skipping because test is flaky on CI") | ||||
| 	} | ||||
| 	lock := sync.Mutex{} | ||||
| 	var queue Queue | ||||
| 	var err error | ||||
|   | ||||
| @@ -5,6 +5,7 @@ package queue | ||||
|  | ||||
| import ( | ||||
| 	"fmt" | ||||
| 	"os" | ||||
| 	"strconv" | ||||
| 	"sync" | ||||
| 	"testing" | ||||
| @@ -16,6 +17,9 @@ import ( | ||||
| ) | ||||
|  | ||||
| func TestPersistableChannelUniqueQueue(t *testing.T) { | ||||
| 	if os.Getenv("CI") != "" { | ||||
| 		t.Skip("Skipping because test is flaky on CI") | ||||
| 	} | ||||
| 	tmpDir := t.TempDir() | ||||
| 	fmt.Printf("TempDir %s\n", tmpDir) | ||||
| 	_ = log.NewLogger(1000, "console", "console", `{"level":"warn","stacktracelevel":"NONE","stderr":true}`) | ||||
|   | ||||
		Reference in New Issue
	
	Block a user
	 silverwind
					silverwind