Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>It seems Pan is going to help you find the answer to your issue.</p> <p>However I'd like to add my two cents here. As it has been recommended by many people, including Dan North [1], Ben Mabey [2], Jonas Nicklas [3] and even Aslask Hellesøy recommending you to remove web_steps.rb [4], you should try not to write cucumber scenarios with steps surfacing implementation details.</p> <pre><code>When I fill in "Name" with "Cardiology" </code></pre> <p>This is about filling an HTML form input based on its label or ID or whatever... This is implementation.</p> <p>I guess you could go with steps such as:</p> <pre><code>When I create a department called "Cardiology" And I create a department called "Radiology" </code></pre> <p>Dan North even recommends having only one "event" [5] (a "When" step):</p> <pre><code>When I create departments called "Cardiology" and "Radiology" </code></pre> <p>All the form/html handling is then encapsulated within a single step definition. And of course, there you can apply the XPath expression Pan suggested above.</p> <ul> <li>[1] <a href="http://dannorth.net/2011/01/31/whose-domain-is-it-anyway/" rel="nofollow">http://dannorth.net/2011/01/31/whose-domain-is-it-anyway/</a></li> <li>[2] <a href="http://benmabey.com/2008/05/19/imperative-vs-declarative-scenarios-in-user-stories.html" rel="nofollow">http://benmabey.com/2008/05/19/imperative-vs-declarative-scenarios-in-user-stories.html</a></li> <li>[3] <a href="http://elabs.se/blog/15-you-re-cuking-it-wrong" rel="nofollow">http://elabs.se/blog/15-you-re-cuking-it-wrong</a></li> <li>[4] <a href="https://github.com/aslakhellesoy/cucumber-rails/commit/e8d8ddb504b11452a0dc8946316faecc26915f17" rel="nofollow">https://github.com/aslakhellesoy/cucumber-rails/commit/e8d8ddb504b11452a0dc8946316faecc26915f17</a></li> <li>[5] <a href="http://dannorth.net/whats-in-a-story/" rel="nofollow">http://dannorth.net/whats-in-a-story/</a></li> </ul>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload