Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add (and use) a runner wrapping every test, to improve error reporting #303

Open
wants to merge 8 commits into
base: main
Choose a base branch
from

Commits on Mar 2, 2023

  1. Add a custom runner for tests

    This custom runner allows to display the result of a test in the same
    way on Unix and Windows (by mapping Windows error codes to their
    equivalent result on Unix)
    It also uses GitHub CI formats when available so that test failures are
    referenced as such at their positions in the logs
    shym committed Mar 2, 2023
    Configuration menu
    Copy the full SHA
    8a5436f View commit details
    Browse the repository at this point in the history
  2. Use the custom runner for the test suite

    Unfortunately, syntax such as `%{dep:%{test}}` is not understood in an
    action, and simply using: `(action (run runner %{test}))` does not add
    the test executable to the dependencies of the action, so dune does not
    build it
    
    We keep the standard runner for the _internal_ tests, as the custom
    runner would bring no benefit there
    shym committed Mar 2, 2023
    Configuration menu
    Copy the full SHA
    b7da2ba View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    cfabed7 View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    fcde317 View commit details
    Browse the repository at this point in the history
  5. Add a rule to display the final times.log

    Also add a rule to build a dummy file in case the TIMELOGDIR was never
    set
    shym committed Mar 2, 2023
    Configuration menu
    Copy the full SHA
    7aa68a6 View commit details
    Browse the repository at this point in the history
  6. Configuration menu
    Copy the full SHA
    2695a8e View commit details
    Browse the repository at this point in the history
  7. Configuration menu
    Copy the full SHA
    724a043 View commit details
    Browse the repository at this point in the history
  8. runner: Use floats for times to be compatible with 32 bits

    Unix.time () does not fit inside a 31-bit int (which must be why it is
    using float in the first place), so use floats for times
    shym committed Mar 2, 2023
    Configuration menu
    Copy the full SHA
    2109996 View commit details
    Browse the repository at this point in the history