Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Rust: only accept options.yml in QL tests #18003

Merged
merged 2 commits into from
Nov 18, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 1 addition & 7 deletions rust/extractor/src/config.rs
Original file line number Diff line number Diff line change
Expand Up @@ -62,13 +62,7 @@ impl Config {
.ancestors()
// only travel up while we're within the test pack
.take_while_inclusive(|p| !p.join("qlpack.yml").exists())
.flat_map(|p| {
[
p.join("options"),
p.join("options.yml"),
p.join("options.yaml"),
]
})
.map(|p| p.join("options.yml"))
.filter(|p| p.exists())
.collect_vec();
option_files.reverse();
Expand Down
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -5,3 +5,4 @@
| main.rs:0:0:0:0 | main.rs | File successfully extracted. |
| my_macro.rs:0:0:0:0 | my_macro.rs | File successfully extracted. |
| my_struct.rs:0:0:0:0 | my_struct.rs | File successfully extracted. |
| options.yml:0:0:0:0 | options.yml | File successfully extracted. |
Original file line number Diff line number Diff line change
Expand Up @@ -5,3 +5,4 @@
| lib.rs:0:0:0:0 | lib.rs | 5 |
| does_not_compile.rs:0:0:0:0 | does_not_compile.rs | 3 |
| error.rs:0:0:0:0 | error.rs | 3 |
| options.yml:0:0:0:0 | options.yml | 0 |
4 changes: 2 additions & 2 deletions rust/ql/test/query-tests/diagnostics/SummaryStats.expected
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@
| Elements unextracted | 0 |
| Extraction errors | 0 |
| Extraction warnings | 7 |
| Files extracted - total | 7 |
| Files extracted - total | 8 |
| Files extracted - with errors | 2 |
| Files extracted - without errors | 5 |
| Files extracted - without errors | 6 |
| Inconsistencies - AST | 0 |
| Inconsistencies - CFG | 0 |
| Inconsistencies - data flow | 0 |
Expand Down