mirror of
https://github.com/astral-sh/ruff.git
synced 2025-10-01 06:11:21 +00:00
Add test coverage for non-Python globs (#13430)
This commit is contained in:
parent
0bbc138037
commit
7579a792c7
1 changed files with 5 additions and 2 deletions
|
@ -226,13 +226,14 @@ fn globs() -> Result<()> {
|
||||||
|
|
||||||
root.child("ruff.toml").write_str(indoc::indoc! {r#"
|
root.child("ruff.toml").write_str(indoc::indoc! {r#"
|
||||||
[analyze]
|
[analyze]
|
||||||
include-dependencies = { "ruff/a.py" = ["ruff/b.py"], "ruff/b.py" = ["ruff/*.py"] }
|
include-dependencies = { "ruff/a.py" = ["ruff/b.py"], "ruff/b.py" = ["ruff/*.py"], "ruff/c.py" = ["*.json"] }
|
||||||
"#})?;
|
"#})?;
|
||||||
|
|
||||||
root.child("ruff").child("__init__.py").write_str("")?;
|
root.child("ruff").child("__init__.py").write_str("")?;
|
||||||
root.child("ruff").child("a.py").write_str("")?;
|
root.child("ruff").child("a.py").write_str("")?;
|
||||||
root.child("ruff").child("b.py").write_str("")?;
|
root.child("ruff").child("b.py").write_str("")?;
|
||||||
root.child("ruff").child("c.py").write_str("")?;
|
root.child("ruff").child("c.py").write_str("")?;
|
||||||
|
root.child("ruff").child("d.json").write_str("")?;
|
||||||
|
|
||||||
insta::with_settings!({
|
insta::with_settings!({
|
||||||
filters => INSTA_FILTERS.to_vec(),
|
filters => INSTA_FILTERS.to_vec(),
|
||||||
|
@ -252,7 +253,9 @@ fn globs() -> Result<()> {
|
||||||
"ruff/b.py",
|
"ruff/b.py",
|
||||||
"ruff/c.py"
|
"ruff/c.py"
|
||||||
],
|
],
|
||||||
"ruff/c.py": []
|
"ruff/c.py": [
|
||||||
|
"ruff/d.json"
|
||||||
|
]
|
||||||
}
|
}
|
||||||
|
|
||||||
----- stderr -----
|
----- stderr -----
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue