File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -19,6 +19,7 @@ example_files = [
1919]
2020
2121function run_all ()
22+ failed_examples = String[]
2223 for f in example_files
2324 f == " cleanup.jl" && continue
2425 println (" \n " * " =" ^ 60 )
@@ -28,9 +29,15 @@ function run_all()
2829 include (joinpath (@__DIR__ , f))
2930 catch e
3031 @error " Failed: $f " exception= (e, catch_backtrace ())
32+ push! (failed_examples, f)
3133 end
3234 end
33- println (" \n All examples completed." )
35+ if isempty (failed_examples)
36+ println (" \n All examples completed." )
37+ else
38+ failed_list = join (failed_examples, " , " )
39+ throw (ErrorException (" run_all failed for $(length (failed_examples)) example(s): $failed_list " ))
40+ end
3441end
3542
3643function example_menu ()
Original file line number Diff line number Diff line change @@ -23,6 +23,7 @@ example_files = [
2323]
2424
2525function run_all ()
26+ failed_examples = String[]
2627 for f in example_files
2728 f == " cleanup.jl" && continue
2829 println (" \n " * " =" ^ 60 )
@@ -32,9 +33,15 @@ function run_all()
3233 include (joinpath (examples_dir, f))
3334 catch e
3435 @error " Failed: $f " exception= (e, catch_backtrace ())
36+ push! (failed_examples, f)
3537 end
3638 end
37- println (" \n All examples completed." )
39+ if isempty (failed_examples)
40+ println (" \n All examples completed." )
41+ else
42+ failed_list = join (failed_examples, " , " )
43+ throw (ErrorException (" run_all failed for $(length (failed_examples)) example(s): $failed_list " ))
44+ end
3845end
3946
4047function example_menu ()
You can’t perform that action at this time.
0 commit comments