From 0a4e52bf1512e106abbe81387477c764adce966e Mon Sep 17 00:00:00 2001 From: Stefano Zacchiroli Date: Tue, 3 Feb 2004 13:45:52 +0000 Subject: [PATCH] catch exceptions and mark corresponding tests as failed --- helm/gTopLevel/regtest.ml | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/helm/gTopLevel/regtest.ml b/helm/gTopLevel/regtest.ml index a38d5a02b..ed8988bb8 100644 --- a/helm/gTopLevel/regtest.ml +++ b/helm/gTopLevel/regtest.ml @@ -159,12 +159,14 @@ let main () = for i = 1 to argc - 1 do let fname = Sys.argv.(i) in prerr_endline ("# " ^ fname); - let expected = parse_regtest fname in - let actual = test_this expected.term in - if as_expected expected actual then - incr ok - else - nok := fname :: !nok; + try + let expected = parse_regtest fname in + let actual = test_this expected.term in + if as_expected expected actual then + incr ok + else + nok := fname :: !nok; + with e -> nok := fname :: !nok done; print_msg "Regtest completed:"; print_msg (sprintf "Succeeded: %d" !ok); -- 2.39.2