reset and resetToDefault are doing the same thing
Nobody has claimed this yet.
- Dominant language
- Java
- Stars
- 7.4k
- Forks
- 1.5k
- Avg merge
- 13h 10m
- Merged PRs (30d)
- 16
Description
According to the documentation at http://wiremock.org/docs/stubbing/ reset and resetToDefault should do different things.
reset: The WireMock server can be reset at any time, removing all stub mappings and deleting the request logresetToDefault: If you’ve created some file based stub mappings to be loaded at startup and you don’t want these to disappear when you do a reset you can callWireMock.resetToDefault()instead
However as far as I can tell both calls are doing the same thing.
I can even see it in the code in com.github.tomakehurst.wiremock.core.WireMockApp#resetAll:
@Override
public void resetAll() {
resetToDefaultMappings();
}
I noticed this behavior in WireMock 2.18.0.
Are there any plans for changing this behavior?
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the documented reset and resetToDefault behavior, then inspect com.github.tomakehurst.wiremock.core.WireMockApp#resetAll and the related resetToDefaultMappings path. Verify how file-based stub mappings and the request log are handled, and confirm that the two public operations produce the distinct outcomes described in the issue.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java
- Domain
- api
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100