Should KubernetesMockServer.reset()
also reset DefaultMockServer.lastRequest*
#6750
Labels
KubernetesMockServer.reset()
also reset DefaultMockServer.lastRequest*
#6750
Is your enhancement related to a problem? Please describe
In
kubernetes-client/junit/kubernetes-server-mock/src/main/java/io/fabric8/kubernetes/client/server/mock/KubernetesMockServer.java
Lines 230 to 237 in 5fd904c
DefaultMockServer
and especially these three:kubernetes-client/junit/mockwebserver/src/main/java/io/fabric8/mockwebserver/DefaultMockServer.java
Lines 40 to 42 in 5fd904c
It can be problematic when you actually try to check that no request have been sent with
getLastRequest()
after areset()
and some operations and you end up with the request sent pre-reset()
.Describe the solution you'd like
Ideally, I would like
DefaultMockServer
to be reset whenKubernetesMockServer
is reset.Describe alternatives you've considered
No response
Additional context
It looks like it comes out of the blue but I noticed it while doing some enhancements on sbomer and it got in the way.
The text was updated successfully, but these errors were encountered: