Sha256: 354fd2b0bb0e0ab572c3dac2e0f8a85693eb52da5cddaf642e10f05758c4be4d

Contents?: true

Size: 1.93 KB

Versions: 19

Compression:

Stored size: 1.93 KB

Contents

<% sc = 0 %>
<% @scenario.examples.each_with_index do |example, example_index| %>
  <% example.data.each_with_index do |row, row_index| %>
    <div style="display: none;" class="steps <%= "example#{example_index + 1}-#{row_index +1}" %>">
      <% scenario = @scenario.scenarios[sc] %>
      <% @scenario_outline = @scenario ; @scenario = scenario ; @steps = scenario.steps %>
      <%= erb(:steps) %>
      <% @scenario = @scenario_outline %>
      <% sc += 1 %>
    </div>
  <% end %>
<% end %>


<div class="outline">
  
  <% if @scenario.examples? %>
    
    <% @scenario.examples.each_with_index do |example,example_index| %>
      <div class="keyword">
        <%= h example.keyword %><%= example.name != "" ? ':' : '' %>
      </div>
      <div class="example-group-name"><%= h example.name %></div>
      <br style="clear: both;"/>
      <table>
        <thead>
          <tr>
            <% example.headers.each_with_index do |header,header_index| %>
              <th><%= h(header) %></th>
            <% end %>
          </tr>
        </thead>
        <% unless example.data.empty? %>
          <% example.data.each_with_index do |row,row_index| %>
          <tr class="<%= (row_index + 1) % 2 == 0 ? "even example#{example_index+1}-#{row_index +1}" : "odd example#{example_index+1}-#{row_index +1}" %>">
            <% row.each_with_index do |column,column_index| %>
              <td><%= h(column.to_s.strip) %></td>
            <% end %>
          </tr>
          <% end %>
        <% else %>
          <!-- Scenario Outline example table is empty -->
          <tr class="odd">
            <td colspan="<%= example.headers.length %>" style="text-align: center;">
              No Examples Defined
            </td>
          </tr>
        <% end %>
      </table>
    <% end  %>
    
  <% else %>
  <div class="keyword">No Example Table Defined</div>
  <div class="keyword suggestion developer">[!] Did you mean to create a Scenario?</div>
  <% end %>
</div>

Version data entries

19 entries across 19 versions & 3 rubygems

Version Path
yard-nrser-cucumber-0.1.3 lib/templates/default/feature/html/outline.erb
yard-nrser-cucumber-0.1.2 lib/templates/default/feature/html/outline.erb
yard-nrser-cucumber-0.1.1 lib/templates/default/feature/html/outline.erb
yard-nrser-cucumber-0.1.0 lib/templates/default/feature/html/outline.erb
yard-cucumber-4.0.0 lib/templates/default/feature/html/outline.erb
yard-cucumber-3.1.0 lib/templates/default/feature/html/outline.erb
yard-cucumber-3.0.0 lib/templates/default/feature/html/outline.erb
yard-cucumber2-2.3.4 lib/templates/default/feature/html/outline.erb
yard-cucumber2-2.3.3 lib/templates/default/feature/html/outline.erb
yard-cucumber-2.3.2 lib/templates/default/feature/html/outline.erb
yard-cucumber-2.3.1 lib/templates/default/feature/html/outline.erb
yard-cucumber-2.3.0 lib/templates/default/feature/html/outline.erb
yard-cucumber-2.2.3 lib/templates/default/feature/html/outline.erb
yard-cucumber-2.2.2 lib/templates/default/feature/html/outline.erb
yard-cucumber-2.2.1 lib/templates/default/feature/html/outline.erb
yard-cucumber-2.2.0 lib/templates/default/feature/html/outline.erb
yard-cucumber-2.1.7 lib/templates/default/feature/html/outline.erb
yard-cucumber-2.1.6 lib/templates/default/feature/html/outline.erb
yard-cucumber-2.1.5 lib/templates/default/feature/html/outline.erb