-
Notifications
You must be signed in to change notification settings - Fork 10
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
Local javascript : Connection refused - connect(2) #30
Comments
Little bit more digging and it seems Rails 3 unobtrusive delete functionality is broken
As defined in /public/rails.js , I should also mention i got an error about application.js like the above but this is being loaded fine. The plot thickens :) |
Is this the delete thing a separate issue? If so, can you create a separate issue? As to the connection refused, does capy support subdomains? I can never remember the answer to this ... |
From what i could tell the two issues are related, I'll do some further investigation in the morning to see whats happening . Capybara does support subdomains by changing Capybara.app_host and Capybara.default_host for each subdomain you want. |
As to the host stuff, right, and capy-envjs should follow that. Is it not? I thought the issue might be trying to wildcard the domain in some way, so that more than one host was fed to your app, and I'm not sure if capy handles that. |
I've create some tests on a repo ( http://github.com/charper/envjs-test ) so you can see what Im encountering. subdomain.feature demonstrate the above issue. test.feature contain other items i've came across during investigating this issue this morning. |
Okay. I think the "could not load" is because you are not setting default_host and app_host. Did it now work when you tired that. (I'm not sure it's been tested/works with ports?) The HIDDEN stuff is because, I think, envjs isn't handling CSS styles well enough. The delete stuff is just painful. The event code is pretty crufty. I'm afraid it doesn't handle bubbling correctly and live() requires it. |
Tried changing both default_host and app_host with no difference in result. Does seem strange that it doesnt load the JS when its on a subdomain given it can connect and run through steps fine. The hidden div seems to be a issue with Capybara itself as this also fails within webdriver. I should of checked this before posting here. I had forgotten that I wrote the test after switching to envjs. Ill have a look again on Monday to try and solve the connect and delete issue as I can't describe enough how much I want to move from webdriver and i could never get culerity to work correctly. |
The default_host/app_host stuff should be fixable, as long as you're not trying to change it on the fly and/or use more than one host. Is that right? (It might be fixable anyway, but I'm not sure where there might be assumptions about things not changing). I remember making something with hidden work to make the capy tests run, but I don't remember the details. I do know that in general the CSS stuff is very incomplete, so if that's a big part of what you want to do, there are likely to be issues. The delete stuff ... well, it's fixable with time, but I'm not sure where that time is going to come from on my part. That code really needs to be cleaned. It may be possible to pull the code from the master env.js branch, until we can get the Johnson fork merged (which has no current eta; everybody busy ...) |
Currently moving over from selenium to envjs and liking the massive speed increase so far.
I have noticed however I get the following error when running tests:
The javascript is however working fine as a checkbox toggle hides and shows a div and I find not issues in the logs.
It should probably be noted I'm using http://github.com/thoughtbot/capybara-envjs-fixes as I was unable to get the tests to even run without it, not sure which may be causing the issue.
The text was updated successfully, but these errors were encountered: