smocker icon indicating copy to clipboard operation
smocker copied to clipboard

Request Body matcher is saved incorrectly in mocks.yml

Open graeme-verticalscope opened this issue 3 years ago • 0 comments

Summary

Smocker appears to add an extra | character when saving a request-body matcher to the mocks.yml file.

Smocker Version

0.18.2 (using latest version of docker thiht/smocker:latest)

Steps to Reproduce

  1. In the UI, add a new POST mock. Configure the request body with Default -> ShouldContainSubstring matcher Screen Shot 2022-06-06 at 4 20 27 PM

  2. Open mocks.yml

Expected: body matcher is defined with yaml keys

- request:
    body:
        matcher: ShouldContainSubstring
        value: test-substring

Actual: body matcher has extra | character, which starts a multi-line string

- request:
    body: |
        matcher: ShouldContainSubstring
        value: test-substring

graeme-verticalscope avatar Jun 06 '22 20:06 graeme-verticalscope