mirror of
https://github.com/CatalaLang/catala.git
synced 2024-11-09 22:16:10 +03:00
fix(clerk): add error redirection to the command of the test_scope rule
This commit is contained in:
parent
7b5035173f
commit
8d0c8a4e86
2
Makefile
2
Makefile
@ -10,7 +10,7 @@ export
|
||||
# Dependencies
|
||||
##########################################
|
||||
|
||||
EXECUTABLES = man2html virtualenv python3 colordiff node pygmentize nodejs npm
|
||||
EXECUTABLES = man2html virtualenv python3 colordiff node pygmentize nodejs npm ninja
|
||||
K := $(foreach exec,$(EXECUTABLES),\
|
||||
$(if $(shell which $(exec)),some string,$(warning [WARNING] No "$(exec)" executable found. \
|
||||
Please install this executable for everything to work smoothly)))
|
||||
|
@ -272,7 +272,7 @@ let ninja_start (catala_exe : string) : ninja =
|
||||
Lit "Interpret";
|
||||
Var "tested_file";
|
||||
(* TODO: find a way to add breaks *)
|
||||
Lit "--unstyle | colordiff -u -b";
|
||||
Lit "--unstyled 2>&1 | colordiff -u -b";
|
||||
Var "expected_output";
|
||||
Lit "-";
|
||||
])
|
||||
@ -321,7 +321,12 @@ let collect_all_ninja_build (ninja : ninja) (tested_file : string) (_catala_exe
|
||||
},
|
||||
(* TODO: to refactor to get a list and add '$' if needed when writing. *)
|
||||
test_names ^ " $\n " ^ test_name )
|
||||
| _ -> failwith "TODO: to support all backends")
|
||||
| backend ->
|
||||
catala_backend_to_string backend
|
||||
|> Printf.sprintf "%s: Catala backend '%s' is not yet supported. "
|
||||
expected_output.complete_filename
|
||||
|> Cli.warning_print;
|
||||
(ninja, test_names))
|
||||
(ninja, "") expected_outputs
|
||||
in
|
||||
let test_name = Printf.sprintf "test_file_%s" tested_file |> Nj.Build.unpath in
|
||||
|
Loading…
Reference in New Issue
Block a user