Sha256: 35470912fe49b0e0907f3f1a9c6575a9a76621709a53d2ce80d0b2e103d38929

Contents?: true

Size: 1.03 KB

Versions: 13

Compression:

Stored size: 1.03 KB

Contents

Feature: Having set up the Mirage with a number of defaults, your tests may continue to change its state.
  Clearing and resetting all of your responses, potentially hundreds of times, can be time expensive.

  Mirage provides the ability to save of its current state and to revert it back to that state.

  Background: The MockServer has been setup with some default responses
    Given I hit 'http://localhost:7001/mirage/set/greeting' with parameters:
      | response | The default greeting |


  Scenario: Saving Mirage and reverting it
    Given  I hit 'http://localhost:7001/mirage/save'
    And I hit 'http://localhost:7001/mirage/set/leaving' with parameters:
      | response | Goodye |

    And I hit 'http://localhost:7001/mirage/set/greeting' with parameters:
      | response | Changed |

    And I hit 'http://localhost:7001/mirage/revert'

    When I hit 'http://localhost:7001/mirage/get/leaving'
    Then a 404 should be returned

    When I hit 'http://localhost:7001/mirage/get/greeting'
    Then 'The default greeting' should be returned

Version data entries

13 entries across 13 versions & 1 rubygems

Version Path
mirage-1.3.6 features/server/save_and_revert.feature
mirage-1.3.5 features/server/save_and_revert.feature
mirage-1.3.4 features/server/save_and_revert.feature
mirage-1.3.3 features/server/save_and_revert.feature
mirage-1.3.2 features/server/save_and_revert.feature
mirage-1.3.1 features/server/save_and_revert.feature
mirage-1.3.0 features/server/save_and_revert.feature
mirage-1.2.0 features/server/save_and_revert.feature
mirage-1.1.0 features/server/save_and_revert.feature
mirage-1.0.2 features/server/save_and_revert.feature
mirage-1.0.1 features/server/save_and_revert.feature
mirage-1.0.0 features/save_and_revert.feature
mirage-0.1.7 features/save.feature