File tree Expand file tree Collapse file tree 1 file changed +5
-2
lines changed Expand file tree Collapse file tree 1 file changed +5
-2
lines changed Original file line number Diff line number Diff line change @@ -2270,12 +2270,15 @@ actual:\n\
2270
2270
2271
2271
if self . config . rustfix_coverage {
2272
2272
// Find out which tests have `MachineApplicable` suggestions but are missing
2273
- // `run-rustfix` or `run-rustfix-only-machine-applicable` headers
2273
+ // `run-rustfix` or `run-rustfix-only-machine-applicable` headers.
2274
+ //
2275
+ // This will return an empty `Vec` in case the executed test file has a
2276
+ // `compile-flags: --error-format=xxxx` header with a value other than `json`.
2274
2277
let suggestions = get_suggestions_from_json (
2275
2278
& proc_res. stderr ,
2276
2279
& HashSet :: new ( ) ,
2277
2280
Filter :: MachineApplicableOnly
2278
- ) . unwrap ( ) ;
2281
+ ) . unwrap_or_default ( ) ;
2279
2282
if suggestions. len ( ) > 0
2280
2283
&& !self . props . run_rustfix
2281
2284
&& !self . props . rustfix_only_machine_applicable {
You can’t perform that action at this time.
0 commit comments