diff options
author | Lunny Xiao <xiaolunwen@gmail.com> | 2025-01-09 08:15:47 +0100 |
---|---|---|
committer | Earl Warren <contact@earl-warren.org> | 2025-01-12 09:02:47 +0100 |
commit | d09b8ba9cf190821ee20ec55898625f12d29febe (patch) | |
tree | cf2ba9ce7e2a4d38cf27e4667f8f0a9e895a301f | |
parent | Support the new exit code for `git remote` subcommands for git version >=2.30... (diff) | |
download | forgejo-d09b8ba9cf190821ee20ec55898625f12d29febe.tar.xz forgejo-d09b8ba9cf190821ee20ec55898625f12d29febe.zip |
Fix fuzz test (#33156)
(cherry picked from commit ba5e3a5161a497aa8c73827774870fb94676e68b)
-rw-r--r-- | tests/fuzz/fuzz_test.go | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/tests/fuzz/fuzz_test.go b/tests/fuzz/fuzz_test.go index 25a6ed8213..d16f26c085 100644 --- a/tests/fuzz/fuzz_test.go +++ b/tests/fuzz/fuzz_test.go @@ -27,6 +27,7 @@ var renderContext = markup.RenderContext{ func FuzzMarkdownRenderRaw(f *testing.F) { f.Fuzz(func(t *testing.T, data []byte) { + setting.IsInTesting = true setting.AppURL = "http://localhost:3000/" markdown.RenderRaw(&renderContext, bytes.NewReader(data), io.Discard) }) @@ -34,6 +35,7 @@ func FuzzMarkdownRenderRaw(f *testing.F) { func FuzzMarkupPostProcess(f *testing.F) { f.Fuzz(func(t *testing.T, data []byte) { + setting.IsInTesting = true setting.AppURL = "http://localhost:3000/" markup.PostProcess(&renderContext, bytes.NewReader(data), io.Discard) }) |