${keywords.narrative}
<#assign isAlternative=narrative.isAlternative()?string>
<#if isAlternative == "true">
${keywords.asA} ${narrative.asA}
${keywords.iWantTo} ${narrative.iWantTo}
${keywords.soThat} ${narrative.soThat}
<#else>
${keywords.inOrderTo} ${narrative.inOrderTo}
${keywords.asA} ${narrative.asA}
${keywords.iWantTo} ${narrative.iWantTo}
#if>
#macro>
<#macro renderGivenStories givenStories>
${keywords.lifecycle}
<#if !lifecycle.getBeforeSteps().isEmpty()>
${keywords.before}
<#list lifecycle.getBeforeSteps() as step>
${step?html}
#list>
#if>
<#if !lifecycle.getAfterSteps().isEmpty()>
${keywords.after}
<#list lifecycle.getOutcomes() as outcome>
${keywords.outcome} ${outcome}
<#assign metaFilter=lifecycle.getMetaFilter(outcome)>
<#if !metaFilter.isEmpty()><#assign metaFilterAsString=metaFilter.asString()>
${keywords.metaFilter} ${metaFilterAsString}
#if>
<#list lifecycle.getAfterSteps(outcome) as step>
${step?html}
#list>
#list>
#if>
#macro>
<#macro renderTable table>
<#assign rows=table.getRows()>
<#assign headers=table.getHeaders()>
<@renderOutcomes step.getOutcomes()/>
<#if step.getOutcomesFailureCause()??>
${step.outcomesFailureCause?html}
#if>
#if>
#macro>
<#macro renderStepOutcome outcome><#if outcome=="pending"><@renderMultiline story.getDescription()/>
${story.path}
<#if story.getMeta()??><@renderMeta story.getMeta()/>#if>
<#if story.getNarrative()??><@renderNarrative story.getNarrative()/>#if>
<#if story.getLifecycle()??><@renderLifecycle story.getLifecycle()/>#if>
<#assign scenarios = story.getScenarios()>
<#list scenarios as scenario>
${keywords.scenario} <@renderMultiline scenario.getTitle()/>
<#if scenario.getMeta()??><@renderMeta scenario.getMeta()/>#if>
<#if scenario.getGivenStories()??><@renderGivenStories scenario.getGivenStories()/>#if>
<#if scenario.getExamplesTable()??>
${keywords.examplesTable}
<#list scenario.getExamplesSteps() as step>
${step?html}
#list>
<@renderTable scenario.getExamplesTable()/>
<#if scenario.getExamples()??>
<#list scenario.getExamples() as example>
${keywords.examplesTableRow} ${example?html}
<#assign steps = scenario.getStepsByExample(example)>
<#list steps as step>
<@renderStep step/>
#list>
#list>
#if>
<#else>
<#assign steps = scenario.getSteps()>
<#list steps as step>
<@renderStep step/>
#list>
#if>
#list>
<#if story.isCancelled()?string == 'true'>
${keywords.storyCancelled} (${keywords.duration} ${story.storyDuration.durationInSecs} s)
#if>
<#if story.getPendingMethods()??>
<#list story.getPendingMethods() as method>