Feature: After Hooks

  After hooks can be used to clean up any state you've altered during your
  scenario, or to check the status of the scenario and act accordingly.

  You can ask a scenario whether it has failed, for example.

  Mind you, even if it hasn't failed yet, you can still make the scenario
  fail if your After hook throws an error.

  Background:
    Given the standard step definitions

  Scenario: Check the failed status of a scenario in a hook
    Given a file named "features/support/debug_hook.rb" with:
      """
      After do |scenario|
        if scenario.failed?
          puts "eek"
        end
      end
      """
    And a file named "features/fail.feature" with:
      """
      Feature:
        Scenario:
          Given this step fails
      """
    When I run `cucumber -f progress`
    Then the output should contain:
      """
      eek
      """

  Scenario: Make a scenario fail from an After hook
    Given a file named "features/support/bad_hook.rb" with:
      """
      After do
        fail 'yikes'
      end
      """
    And a file named "features/pass.feature" with:
      """
      Feature:
        Scenario:
          Given this step passes
      """
    When I run `cucumber -f pretty`
    Then it should fail with:
      """
        Scenario:                # features/pass.feature:2
          Given this step passes # features/step_definitions/steps.rb:1
            yikes (RuntimeError)
            ./features/support/bad_hook.rb:2:in `After'
      """


Add a couple of scenarios to document After hooks
Add a couple of scenarios to document After hooks

@willbryant I did this to try and reproduce the error you mentioned in
https://github.com/cucumber/cucumber/commit/1ac1f8abb473f9fca52eeb8534880dda12f7e608#commitcomment-7695454
but it's passing.

I guess there must be something particular about your scenario that's
causing it. Can you help me make a test case to reproduce the problem?
