File tree Expand file tree Collapse file tree 1 file changed +4
-8
lines changed Expand file tree Collapse file tree 1 file changed +4
-8
lines changed Original file line number Diff line number Diff line change @@ -229,7 +229,6 @@ fn check_exercises(info_file: &InfoFile, cmd_runner: &CmdRunner) -> Result<()> {
229
229
230
230
enum SolutionCheck {
231
231
Success { sol_path : String } ,
232
- MissingRequired ,
233
232
MissingOptional ,
234
233
RunFailure { output : Vec < u8 > } ,
235
234
Err ( Error ) ,
@@ -252,7 +251,10 @@ fn check_solutions(
252
251
let sol_path = exercise_info. sol_path ( ) ;
253
252
if !Path :: new ( & sol_path) . exists ( ) {
254
253
if require_solutions {
255
- return SolutionCheck :: MissingRequired ;
254
+ return SolutionCheck :: Err ( anyhow ! (
255
+ "The solution of the exercise {} is missing" ,
256
+ exercise_info. name,
257
+ ) ) ;
256
258
}
257
259
258
260
return SolutionCheck :: MissingOptional ;
@@ -296,12 +298,6 @@ fn check_solutions(
296
298
fmt_cmd. arg ( & sol_path) ;
297
299
sol_paths. insert ( PathBuf :: from ( sol_path) ) ;
298
300
}
299
- SolutionCheck :: MissingRequired => {
300
- bail ! (
301
- "The solution of the exercise {} is missing" ,
302
- exercise_info. name,
303
- ) ;
304
- }
305
301
SolutionCheck :: MissingOptional => ( ) ,
306
302
SolutionCheck :: RunFailure { output } => {
307
303
stdout. write_all ( b"\n \n " ) ?;
You can’t perform that action at this time.
0 commit comments