Closed rehmsen closed 1 year ago
Thanks for taking a look Suzy. What would it take to get this merged?
Thanks for taking a look Suzy. What would it take to get this merged?
Would you mind pulling in the latest commits from tip? There is a fix to the CI and I would like to see the tests run against this change. Thank you!
I'll finish reviewing the code as well.
@rehmsen Looks like just a couple of test cases need to be fixed up! They appear to all be intentional differences in behavior from this change that just need to be reflected in the tests located in cmd/mockserver/server_test.go.
Weird, it took a while to run. I was not able to run them locally completely (failed to install staticcheck I think), but the part that ran I fixed. Will it automatically rerun to check if they are all fixed now?
This is needed so that unset JSON values get initialized to
nil
in Go instead of the zero struct. The zero struct is indistinguishable from an explicitly set struct with zero values, and will get serialized despite "omitempty".nil
on the other hand will be dropped, as expected.Fixes #72.