Skip to content

Conversation

@dkniffin
Copy link

@dkniffin dkniffin commented Oct 28, 2015

This fixed a bug I was having where I believe angular wasn't completely loaded, but capybara was still trying to do things:



<br />Error: [ng:test] no injector found for element argument to getTestability <br />http://errors.angularjs.org/1.3.13/ng/test <br /> at http://localhost:9000/bower_components/angular/angular.js:1509 in getTestability <br /> at phantomjs://webpage.evaluate():5 <br /> at phantomjs://webpage.evaluate():12 <br /> at phantomjs://webpage.evaluate():12 (Capybara::Poltergeist::JavascriptError) <br />

@wrozka
Copy link
Owner

wrozka commented Oct 28, 2015

Thanks, idea looks good to me, but please use jqLite ready instead:
angular.element(document).ready(...)

@dkniffin
Copy link
Author

@wrozka I tried that, and I don't think it worked. I'm a little out of my depth here, but I think the problem I was running into was that angular wasn't fully loaded, so I thought it'd be safer to use my own document ready function, rather than rely on angular's.

@inkstak
Copy link

inkstak commented Aug 29, 2016

Same problem, I currently use @dkniffin's fork.
This request is ready to be merged, isn't it ?

@avegancafe
Copy link

Any reason this isn't merged @wrozka ?

@jrochkind
Copy link

I am also having problems with ReferenceError: angular is not defined (Selenium::WebDriver::Error::JavascriptError), which may be related?

@jrochkind
Copy link

When I try @dkniffin's fork, my intermittent error changes to timeout while waiting for angular (Timeout::Error). So I dunno.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants