Skip to content

Commit

Permalink
Fix fuzz test (#33156)
Browse files Browse the repository at this point in the history
  • Loading branch information
lunny authored Jan 9, 2025
1 parent 2a02734 commit ba5e3a5
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions tests/fuzz/fuzz_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -19,13 +19,15 @@ func newFuzzRenderContext() *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(newFuzzRenderContext(), bytes.NewReader(data), io.Discard)
})
}

func FuzzMarkupPostProcess(f *testing.F) {
f.Fuzz(func(t *testing.T, data []byte) {
setting.IsInTesting = true
setting.AppURL = "http://localhost:3000/"
markup.PostProcessDefault(newFuzzRenderContext(), bytes.NewReader(data), io.Discard)
})
Expand Down

0 comments on commit ba5e3a5

Please sign in to comment.