omissis / go-jsonschema

A tool to generate Go data types from JSON Schema definitions.
MIT License
582 stars 93 forks source link

Adds enforcing integer type for enum values #103

Closed ksysoev closed 1 year ago

ksysoev commented 1 year ago

Addressing the issue https://github.com/omissis/go-jsonschema/issues/102

Enforcing int type for Enum values in case primitive type is set to integer

codecov[bot] commented 1 year ago

Codecov Report

Patch coverage: 71.42% and project coverage change: -0.04% :warning:

Comparison is base (ba1f866) 78.14% compared to head (212b986) 78.11%.

Additional details and impacted files ```diff @@ Coverage Diff @@ ## main #103 +/- ## ========================================== - Coverage 78.14% 78.11% -0.04% ========================================== Files 10 10 Lines 1446 1453 +7 ========================================== + Hits 1130 1135 +5 - Misses 244 246 +2 Partials 72 72 ``` | [Files Changed](https://app.codecov.io/gh/omissis/go-jsonschema/pull/103?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Claudio+Beatrice) | Coverage Δ | | |---|---|---| | [pkg/generator/generate.go](https://app.codecov.io/gh/omissis/go-jsonschema/pull/103?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Claudio+Beatrice#diff-cGtnL2dlbmVyYXRvci9nZW5lcmF0ZS5nbw==) | `75.65% <71.42%> (-0.04%)` | :arrow_down: |

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

omissis commented 1 year ago

This PR was replaced by #126 (I simply rebased it and fixed an issue coming from main`). Thanks for your contribution! 🙏