Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Question: Transformer and Delay in Static Mappings? #149

Closed
rangerranger opened this issue Jun 3, 2018 · 2 comments
Closed

Question: Transformer and Delay in Static Mappings? #149

rangerranger opened this issue Jun 3, 2018 · 2 comments
Assignees

Comments

@rangerranger
Copy link

Hi - Do you know if it is possible to add the WithTransformer and WithDelay to already recorded static mappings? Wanted to check if this was already known before running some tests. Thank you.
Aroon

@StefH
Copy link
Collaborator

StefH commented Jun 4, 2018

By static mappings, I think you mean the mappings defined in the .json file which are loaded at startup?

This is possible.

Transformation can be done like:

"UseTransformer": true,
      "StatusCode": 205,
      "BodyAsJson": { "result": "test - {{request.path}}" }

And delay is like:

"Response": {
            "StatusCode": 200,
            "Delay": 100
        }

See also this example https:/WireMock-Net/WireMock.Net/wiki/Admin-API-Reference#post-__adminmappings

@StefH StefH self-assigned this Jun 4, 2018
@StefH StefH changed the title Transformer and Delay in Static Mappings? Question: Transformer and Delay in Static Mappings? Jun 4, 2018
@rangerranger
Copy link
Author

Thank you Stef.

Aroon

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants