A little ditty that makes it really easy to wait for something Javascripty to happen…like a Javascript dialog to appear that gets populated from an AJAX call.
The has_css? method call will wait until the element shows up and if it doesn’t show up before the Capybara timeout expires then it will return false.
About the Author