-
Notifications
You must be signed in to change notification settings - Fork 421
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
SttpMockServerClient drops null values #2175
Conversation
.thenError(sampleErrorOut, statusCode = StatusCode.BadRequest) | ||
|
||
expectations should have size 1 | ||
println(expectations.head.httpRequest.path) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
println - probably to remove
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
true
} | ||
|
||
it should "match json body with drop null" in { | ||
import TapirJsonCirceWithDropNull._ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
is this ever used?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I wanted to make it explicit for these two cases that they are using different configurations related to this drop option.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
but are they? are you using the jsonBody
method defined by these objects anywhere?
@@ -537,6 +544,252 @@ class MockServerSpec extends AnyFlatSpec with Matchers { | |||
) | |||
} | |||
|
|||
it should "match json body without drop null" in { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
these tests are enormous. Is there a way to somehow deduplicate them, so that it would be visible what's the difference in the null handling, and where the nulls are in the first palce (or not)?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
OK, I'm on it
Can you rebase? The examples are now moved to dedicated directories |
eadaac4
to
71b154f
Compare
84c5bbc
to
baae091
Compare
Closes #2128