alcotezt: port [lib_stdlib] and [lib_stdlib_unix]
Context
Related to: !6760 (closed) (closed) and #4741 (closed).
This MR applies the Alcotezt wrapper on the tests: src/lib_stdlib/test and src/lib_stdlib/test-unix.
This wraps the tests in a Tezt compatibility layer. In short, this means that the above tests are now executed through Tezt, enabling an improved UI and automated load balancing. For more info on the Alcotezt rationale, see !6760 (closed) (closed).
Practically, this entails and this MR will typically contain:
Modifications manifest/main.ml for the tests in question to use the tezt instead of test registration function, and regenerate dune and opam files.
Extending the compatibility layer tezt/lib_alcotezt
Modifying the tests in question to better fit Alcotezt
Manually testing the MR
Locally
Running the test :
dune exec src/lib_stdlib/test/main.exe -- --info
(passing --info prints individual Alcotest cases executed)
The tests in src/lib_stdlib/test/ no longer register a runtest
alias. Instead, a runtezt alias is registered:
dune build @src/lib_stdlib/test/runtezt
When registered in manifest with the tezt function, the test modules
are automatically linked with the main tezt entrypoint
tezt/tests/main.exe. This means that can also run the tests with:
alias tezt='dune exec tezt/tests/main.exe --'
tezt --list --file Tezos_stdlib
In the CI
As the tests are linked with tezt/tests/main.exe, they run in the CI
in the tezt jobs. The GitLab interface offers little
to find individual test cases in the set of tezt jobs, but you can
download the Tezt records from a pipeline on this MR
and check that they contain the test in
question:
PIPELINE=XXXXXXXX dune exec ./tezt/records/update.exe
cat tezt/records/*.json | jq -c 'map(select(.file=="Tezos_stdlib"))[]'
Checklist
-
Document the interface of any function added or modified (see the coding guidelines) -
Document any change to the user interface, including configuration parameters (see node configuration) -
Provide automatic testing (see the testing guide). -
For new features and bug fixes, add an item in the appropriate changelog ( docs/protocols/alpha.rstfor the protocol and the environment,CHANGES.rstat the root of the repository for everything else). -
Select suitable reviewers using the Reviewersfield below. -
Select as Assigneethe next person who should take action on that MR