Skip to content

Commit

Permalink
[ci] dump & upload errors
Browse files Browse the repository at this point in the history
  • Loading branch information
strub committed Apr 22, 2024
1 parent 00cb1a4 commit 07be3af
Show file tree
Hide file tree
Showing 4 changed files with 15 additions and 1 deletion.
7 changes: 6 additions & 1 deletion .github/workflows/ci.yml
Expand Up @@ -147,15 +147,20 @@ jobs:
working-directory: project/${{ matrix.target.name }}/${{ matrix.target.subdir }}
run: |
opam exec -- easycrypt runtest \
-report report.log \
${{ matrix.target.options }} \
${{ matrix.target.config }} \
${{ matrix.target.scenario }}
- name: Compute real-path to report.log
if: always()
run: |
echo "report=$(realpath project/${{ matrix.target.name }}/${{ matrix.target.subdir }})/report.log" >> $GITHUB_ENV
- uses: actions/upload-artifact@v4
name: Upload report.log
if: always()
with:
name: report.log (${{ matrix.target.name }})
path: report.log
path: ${{ env.report }}
if-no-files-found: ignore

external-status:
Expand Down
5 changes: 5 additions & 0 deletions src/ec.ml
Expand Up @@ -291,6 +291,11 @@ let main () =
"runtest";
Format.sprintf "--bin=%s" Sys.executable_name;
]
@ Option.to_list (
Option.map
(Format.sprintf "--report=%s")
input.runo_report
)
@ List.map (Format.sprintf "--bin-args=%s") ecargs
@ [input.runo_input]
@ input.runo_scenarios
Expand Down
3 changes: 3 additions & 0 deletions src/ecOptions.ml
Expand Up @@ -33,6 +33,7 @@ and cli_option = {
and run_option = {
runo_input : string;
runo_scenarios : string list;
runo_report : string option;
runo_provers : prv_options;
}

Expand Down Expand Up @@ -348,6 +349,7 @@ let specs = {
("runtest", "Run a test-suite", [
`Group "loader";
`Group "provers";
`Spec ("report", `String, "dump result to <report>");
]);

("why3config", "Configure why3", []);
Expand Down Expand Up @@ -503,6 +505,7 @@ let cmp_options_of_values ini values input =
let runtest_options_of_values ini values (input, scenarios) =
{ runo_input = input;
runo_scenarios = scenarios;
runo_report = get_string "report" values;
runo_provers = prv_options_of_values ini values; }

(* -------------------------------------------------------------------- *)
Expand Down
1 change: 1 addition & 0 deletions src/ecOptions.mli
Expand Up @@ -29,6 +29,7 @@ and cli_option = {
and run_option = {
runo_input : string;
runo_scenarios : string list;
runo_report : string option;
runo_provers : prv_options;
}

Expand Down

0 comments on commit 07be3af

Please sign in to comment.