jnicklas/capybara — Issue #642: Support :count option on has_content
Author: sobrinho
Created: 2012-02-17 13:00:33+00:00
State: open

I would to be able to do that:

``` ruby
page.should have_content '01/01/2011', :count => 3
```

My assertion should guarantee I have 3 rows in a table on my index page having the same date.

What you think about :count option on has_content?

Have another way to do that?

Currently I'm using:

``` ruby
page.all('td', :text => '01/01/2011').count == 3
```

But seems fragile...