diff options
author | silverwind <me@silverwind.io> | 2023-04-29 11:53:11 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-04-29 11:53:11 +0200 |
commit | fc62992518158ca6ceb03a57db5b3767c8dc6fc5 (patch) | |
tree | 121323eadabe262b66402baa9bc6065ec65621dc /modules | |
parent | 9cf721e44601382f8086bdcebfdbae9b9107da69 (diff) | |
download | gitea-fc62992518158ca6ceb03a57db5b3767c8dc6fc5.tar.gz gitea-fc62992518158ca6ceb03a57db5b3767c8dc6fc5.zip |
Skip known flaky `queue` tests on CI environment (#24419)
Random CI failures are annoying. It's better to just skip the affected
tests so maintainers can use their valuable time for more productive
topics.
Related: https://github.com/go-gitea/gitea/issues/23608
Related: https://github.com/go-gitea/gitea/issues/23977
Related: https://github.com/go-gitea/gitea/issues/18703
Diffstat (limited to 'modules')
-rw-r--r-- | modules/queue/queue_channel_test.go | 4 | ||||
-rw-r--r-- | modules/queue/unique_queue_disk_channel_test.go | 5 |
2 files changed, 9 insertions, 0 deletions
diff --git a/modules/queue/queue_channel_test.go b/modules/queue/queue_channel_test.go index 9b92398bac..f9dae742e2 100644 --- a/modules/queue/queue_channel_test.go +++ b/modules/queue/queue_channel_test.go @@ -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 diff --git a/modules/queue/unique_queue_disk_channel_test.go b/modules/queue/unique_queue_disk_channel_test.go index f75c69f785..e2fe4aceee 100644 --- a/modules/queue/unique_queue_disk_channel_test.go +++ b/modules/queue/unique_queue_disk_channel_test.go @@ -4,6 +4,7 @@ package queue import ( + "os" "strconv" "sync" "testing" @@ -15,6 +16,10 @@ import ( ) func TestPersistableChannelUniqueQueue(t *testing.T) { + if os.Getenv("CI") != "" { + t.Skip("Skipping because test is flaky on CI") + } + tmpDir := t.TempDir() _ = log.NewLogger(1000, "console", "console", `{"level":"warn","stacktracelevel":"NONE","stderr":true}`) |