Sha256: 44793e389c029d56205defba4236838a4b9c1488118cce8d0dabc41d9a70fb03

Contents?: true

Size: 1.12 KB

Versions: 6

Compression:

Stored size: 1.12 KB

Contents

Feature: If you want to see the content of a particular response without triggering then it can be peeked instead.
  To do this, the responses unique id is required to identify it
    

  #TODO should return headers as well
  Scenario: Peeking a text based response
    Given I send PUT to 'http://localhost:7001/mirage/templates/xml' with body '<xml></xml>' and headers:
      | content-type | text/xml |

    When I send GET to 'http://localhost:7001/mirage/templates/1'
    Then '<xml></xml>' should be returned
    And the response 'content-type' should be 'text/xml'


  Scenario: Peeking a file based response
    Given the file 'test_file.txt' contains:
    """
    test content
    """
    And I send PUT to 'http://localhost:7001/mirage/templates/some/location/download' with file: test_file.txt and headers:
      | X-mirage-file | true |

    When I send GET to 'http://localhost:7001/mirage/templates/1'
    Then the response should be the same as the content of 'test_file.txt'


  Scenario: Peeking a response that does not exist
    When I send GET to 'http://localhost:7001/mirage/templates/1'
    Then a 404 should be returned


Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
mirage-2.4.2 features/server/templates/get.feature
mirage-2.4.1 features/server/templates/get.feature
mirage-2.4.0 features/server/templates/get.feature
mirage-2.3.0 features/server/templates/get.feature
mirage-2.2.3 features/server/templates/get.feature
mirage-2.2.2 features/server/templates/get.feature