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

Feature request: Graceful handling of error conditions when listing test cases #247

Open
kevemueller opened this issue Dec 23, 2024 · 1 comment

Comments

@kevemueller
Copy link

kyua fails hard when it receives output on stderr or a non-zero exit code when listing test-cases (-l).
This may happen in environments in which sanitizers are added to the code under test and they trigger non-zero exit code e.g. due to memory leaks and emit traces on stderr.

Ideally kyua should be agnostic to such condititions. I propose two alternate ways to handle such cases:

  • Treat the -l run as a pre-test with the condition stderr empty, 0 exit-code. In case of condition failure, emit the usual diagnostics to the log (stderr output, exit code).
  • Ignore issues during the -l run. Record the stderr output and prepend it to the stderr output of the actual test, ignore the exit code, so the actual test can run.

Both approaches have their merits and either one s better than the current behaviour of bailing without any diagnostic output.

The problem is coming from a discussion around running atf with sanitizers: freebsd/atf#78

@ngie-eign
Copy link
Contributor

ngie-eign commented Dec 26, 2024

I don't honestly think this should be worked around, because it would make scraping testcase data more difficult and error prone. The ASAN/UBSAN related issues need to be resolved.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants