-
Notifications
You must be signed in to change notification settings - Fork 242
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
console.log not printed to stdout when using capybara-webkit #428
Comments
You'll need to run the webserver via |
If this isn't working it should probably be -- if for nothing other than parity. If there's any time available we'll look into it.. thanks for the heads up. |
+1 |
Please try that branch and report back. I have only tested it on the latest capybara-webkit (1.10.1 as of writing) and it appears to work -- no idea about previous versions.
|
@jejacks0n Thanks for taking a look. I've tried using the above branch, but now it looks like not running the specs and just exits. Will try to take a closer look, but for your information, this is all I got now:
|
Thanks @starsirius, that's likely because of the capybara-webkit version (I think).. can you make sure you're using 1.10.1 for me as a follow up? That layer changed a lot between versions of capybara-webkit, and so I expected some hassles there. Please provide the version you're using, and what the results are with 1.10.1 if you have the time. |
@jejacks0n Confirmed that using capybara-webkit 1.10.1 works. It's running the tests and outputting the
However, it seems like I can only get at most 2 outputs and the result is not reliable. For example, given the following test it 'outputs console.log', ->
console.log 777
console.log 'string'
console.log { a: 1, b: 2 }
console.log [{ a: 1, b: 2 }]
fixture.set("<h2>Another Title</h2>") It sometimes outputs
sometimes
|
The timing of them is a bit odd as well. So I don't fully understand why capybara-webkit has it setup the way they do, but I'm using it as best as seems possible at that layer and it 1. doesn't behave as expected, 2. seems to be an area of heavy flux and probably isn't worth trying to maintain compatibility (at least for me -- keeping up with sprockets breakage is hard enough). So I'll close the issue without complete resolution, but will leave the branch so someone else can potentially dive into it further and see if they can make more sense of how capybara-webkit wants a library like teaspoon to handle that. |
Decided I'd check with the capybara-webkit team before closing it entirely. |
Thanks, @jejacks0n! |
I am kind of like in a similar situation. Running on a remote machine with 'bundle exec rake teaspoon' and the log is lost and it is useful for some debugging. I can not go to localhost:XXXX/teaspoon on the remote machine and console.log(), console.info(), console.error() do not output anything to teaspoon. |
is this possible this answer here #524 is exactly what this issue is about ? |
using the capybara-webkit driver I was not able to see any output from console.log statements in my javascript on the stdout. switching to phantomjs showed the output immediately.
my configuration is the default:
config.suppress_log = false
from my Gemfile.lock:
capybara-webkit (1.7.1)
teaspoon (1.1.1)
teaspoon-jasmine (2.3.4)
The text was updated successfully, but these errors were encountered: