зеркало из
https://github.com/glebtv/tui-textarea.git
synced 2026-09-07 07:55:50 +03:00
chore(fuzz): upgrade targets, fix false positives, and add invariant assertions (#11)
- Fix insert_delete target using .unwrap() causing false-positive crashes on arbitrary::Error (input exhaustion) - Fix fuzz Cargo.toml referencing wrong package name (tui-textarea vs tui-textarea-2) - Add invariant assertions (cursor bounds, lines non-empty, selection validity) to all targets - Add 4 new fuzz targets: undo_redo, selection, wrap_render, search - Expand existing targets with full delete/insert variant coverage, input_without_shortcuts, set_yank_text, set_max_histories, and clear - Add DummyBackend::resize() for variable-width wrap rendering tests
Этот коммит содержится в:
@@ -11,7 +11,7 @@ cargo-fuzz = true
|
||||
[dependencies]
|
||||
libfuzzer-sys = "0.4"
|
||||
arbitrary = { version = "1", features = ["derive"] }
|
||||
tui-textarea = { path = "..", features = ["search", "arbitrary"] }
|
||||
tui-textarea = { package = "tui-textarea-2", path = "..", features = ["search", "arbitrary"] }
|
||||
tui-textarea-bench = { path = "../bench" }
|
||||
|
||||
# Prevent this from interfering with workspaces
|
||||
@@ -29,3 +29,27 @@ name = "insert_delete"
|
||||
path = "fuzz_targets/insert_delete.rs"
|
||||
test = false
|
||||
doc = false
|
||||
|
||||
[[bin]]
|
||||
name = "undo_redo"
|
||||
path = "fuzz_targets/undo_redo.rs"
|
||||
test = false
|
||||
doc = false
|
||||
|
||||
[[bin]]
|
||||
name = "selection"
|
||||
path = "fuzz_targets/selection.rs"
|
||||
test = false
|
||||
doc = false
|
||||
|
||||
[[bin]]
|
||||
name = "wrap_render"
|
||||
path = "fuzz_targets/wrap_render.rs"
|
||||
test = false
|
||||
doc = false
|
||||
|
||||
[[bin]]
|
||||
name = "search"
|
||||
path = "fuzz_targets/search.rs"
|
||||
test = false
|
||||
doc = false
|
||||
|
||||
Ссылка в новой задаче
Block a user