feat(cli): allow test subcommand to include/exclude by corpus test file names
This commit is contained in:
parent
1695e454a7
commit
f47319212b
2 changed files with 44 additions and 21 deletions
|
|
@ -250,6 +250,9 @@ struct Test {
|
|||
/// Only run corpus test cases whose name does not match the given regex
|
||||
#[arg(long, short)]
|
||||
pub exclude: Option<Regex>,
|
||||
/// Only run corpus test cases from from a given filename
|
||||
#[arg(long)]
|
||||
pub file_name: Option<String>,
|
||||
/// Update all syntax trees in corpus files with current parser output
|
||||
#[arg(long, short)]
|
||||
pub update: bool,
|
||||
|
|
@ -1044,6 +1047,7 @@ impl Test {
|
|||
debug_graph: self.debug_graph,
|
||||
include: self.include,
|
||||
exclude: self.exclude,
|
||||
file_name: self.file_name,
|
||||
update: self.update,
|
||||
open_log: self.open_log,
|
||||
languages: languages.iter().map(|(l, n)| (n.as_str(), l)).collect(),
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue