mirror of
https://github.com/apache/datafusion-sqlparser-rs.git
synced 2025-09-26 15:39:12 +00:00
test: add fuzzer
Signed-off-by: Chojan Shang <psiace@outlook.com>
This commit is contained in:
parent
35ef0eee38
commit
1e65984613
4 changed files with 67 additions and 0 deletions
12
fuzz/fuzz_targets/fuzz_parse_sql.rs
Normal file
12
fuzz/fuzz_targets/fuzz_parse_sql.rs
Normal file
|
@ -0,0 +1,12 @@
|
|||
use honggfuzz::fuzz;
|
||||
use sqlparser::dialect::GenericDialect;
|
||||
use sqlparser::parser::Parser;
|
||||
|
||||
fn main() {
|
||||
loop {
|
||||
fuzz!(|data: String| {
|
||||
let dialect = GenericDialect {};
|
||||
let _ = Parser::parse_sql(&dialect, &data);
|
||||
});
|
||||
}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue