test: fix flaky test-debug-prompt
Be sure to send .exit
only once to avoid spurious EPIPE and possibly
other errors.
Fixes: https://github.com/nodejs/node/issues/21724
Checklist
-
make -j4 test
(UNIX), orvcbuild test
(Windows) passes -
commit message follows commit guidelines