run test_tag in 'tree-sitter test' when tags test dir exists
This commit is contained in:
parent
7df82c825f
commit
067f742ad3
2 changed files with 8 additions and 1 deletions
|
|
@ -8,6 +8,7 @@ pub mod query_testing;
|
|||
pub mod tags;
|
||||
pub mod test;
|
||||
pub mod test_highlight;
|
||||
pub mod test_tags;
|
||||
pub mod util;
|
||||
pub mod wasm;
|
||||
|
||||
|
|
|
|||
|
|
@ -4,7 +4,8 @@ use glob::glob;
|
|||
use std::path::Path;
|
||||
use std::{env, fs, u64};
|
||||
use tree_sitter_cli::{
|
||||
generate, highlight, logger, parse, playground, query, tags, test, test_highlight, util, wasm,
|
||||
generate, highlight, logger, parse, playground, query, tags, test, test_highlight, test_tags,
|
||||
util, wasm,
|
||||
};
|
||||
use tree_sitter_config::Config;
|
||||
use tree_sitter_loader as loader;
|
||||
|
|
@ -316,6 +317,11 @@ fn run() -> Result<()> {
|
|||
if test_highlight_dir.is_dir() {
|
||||
test_highlight::test_highlights(&loader, &test_highlight_dir)?;
|
||||
}
|
||||
|
||||
let test_tag_dir = test_dir.join("tags");
|
||||
if test_tag_dir.is_dir() {
|
||||
test_tags::test_tags(&loader, &test_tag_dir)?;
|
||||
}
|
||||
}
|
||||
|
||||
("parse", Some(matches)) => {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue