title: Counting elements in a table
body: <p>I have a page with a table, say:</p>
  
  <pre><code>&lt;table&gt; 
  &lt;tr&gt;&lt;td&gt;Element1&lt;/td&gt;&lt;/tr&gt;
  &lt;tr&gt;&lt;td&gt;Element2&lt;/td&gt;&lt;/tr&gt;
  &lt;/table&gt;
  </code></pre>
  
  <p>I am trying to make tests with cucumber and capybara. How can I get the number of table rows in a step definition (it is the only table on the page)?</p>