I have a link with a specific attribute on my page. Using Rspec + Capybara how can I check for the existence of this link?
<a href="#" id="text" data-content="This is a discrete bar chart.">Foo</a>
Does not work:
page.find(:css, 'a[data-content="This is a discrete bar chart."]')
Works:
page.find(:css, 'a#test')