Skip to content

testscript: interrupted background process should not cause a test to fail #260

Closed
@rogpeppe

Description

@rogpeppe

It is usual and expected for processes to return a non-zero exit code when they
are terminated with a signal. At the end of a test, testscript kills all background
processes and then fails if any of them terminate with a non-zero exit code.
This doesn't seem right. (It's even more wrong that it panics with an error code
that should be internal-only - see issue #228).

Instead, at the end of a test, testscript should check if any background processes
have already exited with a non-zero exit code and fail then, but otherwise
it should interrupt them and ignore any non-zero exit codes from processes
killed as a result.

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions