Function resymgen::run_checks
source · pub fn run_checks<P: AsRef<Path>>(
input_file: P,
checks: &[Check],
recursive: bool
) -> Result<Vec<(PathBuf, CheckResult)>, Box<dyn Error>>
Expand description
Validates a given input_file
under the specified checks
.
In recursive
mode, subregion files are also validated.
Returns a Vec<(PathBuf, CheckResult)>
with the results of all checks on all the files
validated, if all checks were run without encountering any fatal errors.
Examples
ⓘ
let results = run_checks(
"/path/to/symbols.yml",
&[
Check::ExplicitVersions,
Check::FunctionNames(NamingConvention::SnakeCase),
],
true,
)
.expect("Fatal error occurred");