dropbox / dropbox-sdk-rust

Dropbox SDK for Rust
Apache License 2.0
76 stars 18 forks source link

generated tests: emit assertions for implicit default values #137

Closed wfraser closed 1 year ago

wfraser commented 1 year ago

When generating the OnlyRequiredFields tests, we need to check that the implicit defaults (the omitted fields in the JSON) were deserialized to the expected value, whether None or an other specified default value.

This means we have to still generate TestField instances for these fields, since that's what's responsible for emitting the assertions.

Checklist

General Contributing

Validation

This is an improvement to the tests.