Open adjenks opened 4 years ago
Running another test:
test.js:
var run = require('browser-run');
var browser = run();
browser.pipe(process.stdout);
browser.end('console.log(location); window.close()');
process.stdout.write('hi');// Check to see if console output is working
bash:
$ node test/test.js
hi
It should also output the location but does not. No errors are reported.
I tried to run electron
on my console but it said I was missing a library. Perhaps browser-run fails to detect when electron fails to run.
error while loading shared libraries: libffmpeg.so
Have you installed browser-run globally?
@ashnur I just ran it using a global installation, same results. Before it was not --global
.
Weird.
echo "console.log('Hey from ' + location); window.close()" | browser-run
WFM on linux
maybe try with a different browser or try the development version (cloning this repo and try running the tests locally).
Also, if you share more information about the context, I am sure more people will likely to chime in with suggestions.
The thing is, I understand that electron will not run. So that's probably the hangup. I would like to know however why it doesn't output any error message. How can I get more debug info from browser-run?
This method does the actual spawning:
I guess we could read from stderr
here to detect failures like this? Or we could make it so it throws an error if no "message"
was received before the "exit"
, which is a more general solution.
I'm having the same issue, using browser-run indirectly through tape-run. Electron fails to start (in my case due to libgconf-2.so.4: cannot open shared object file: No such file or directory
) when I'm executing it directly, but browser-run provides no output.
When I run the example
echo "console.log('Hey from ' + location); window.close()" | browser-run
I get no output, but also no error message. How can I debug this?