I am trying to fuzz some of my code but I am struggling with imports.
I have taken the following steps from the documentation:
cargo install cargo-fuzz
cd my_project
cargo fuzz init
but then when I try to import my modules into the file fuzz_target_1.rs I get various errors
If I try extern crate my_project (as in the docs) I get can't find crate
If I try use my_project I get unresolved import and no external crate my_project
Is there some other way I am supposed to access my code from the fuzz target?
cargo fuzz init has automatically included the following in my_project/fuzz/Cargo.toml:
[dependencies.my_project]
path = ".."
(I was under the impression that this means I can do something like use my_project)
If there is a more appropriate place for me to ask this question I am happy to direct it elsewhere
(I would be happy to update documentation myself if necessary once I understand how this works)
I'm sure this might be something really basic that I'm missing, thanks for your help!
I am trying to fuzz some of my code but I am struggling with imports.
I have taken the following steps from the documentation:
cargo install cargo-fuzzcd my_projectcargo fuzz initbut then when I try to import my modules into the file
fuzz_target_1.rsI get various errorsIf I try
extern crate my_project(as in the docs) I getcan't find crateIf I try
use my_projectI getunresolved importandno external crate my_projectIs there some other way I am supposed to access my code from the fuzz target?
cargo fuzz inithas automatically included the following inmy_project/fuzz/Cargo.toml:(I was under the impression that this means I can do something like
use my_project)If there is a more appropriate place for me to ask this question I am happy to direct it elsewhere
(I would be happy to update documentation myself if necessary once I understand how this works)
I'm sure this might be something really basic that I'm missing, thanks for your help!