Open dominictarr opened 6 years ago
I also noticed that if I commented the whole line with kill %1
then the test would wait for me to do ctrl-c before advancing.
@regular
hmm, this seems to only be the case when it's run directly node test/bin.js
and not within a script!
...
Okay I fixed it!
diff --git a/test/bin.js b/test/bin.js
index 3a17f50..c022b84 100644
--- a/test/bin.js
+++ b/test/bin.js
@@ -28,9 +28,10 @@ function sbot(t, argv, opts) {
' & read dummy; echo killing sbot; kill %1; wait %1'
], Object.assign({
env: Object.assign({}, process.env, {ssb_appname: 'test'}),
- stdio: ['pipe', 'inherit', 'inherit']
}, opts))
+ sh.stdout.pipe(process.stdout)
+ sh.stderr.pipe(process.stderr)
return function end() {
console.log('ending ...')
no maybe i didn't fix it... anyway, this seems like a rather fragile way to run this test
my fix is here: https://github.com/ssbc/scuttlebot/pull/566
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.
If test/bin.js fails, it closes the terminal that it's running in! that makes it very difficult to debug...
I'm guessing it's something to do with the
kill %1
thingI was trying to use it to debug my problem here https://github.com/ssbc/multiserver/pull/25#issuecomment-433758596 basically I need to listen on an address that will work for local network and localhost. but the test only covers listening on explicit addresses.