Skip to content
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

Improve violation message and code readability #1414

Merged
merged 1 commit into from
Oct 17, 2022

Conversation

vadeg
Copy link
Contributor

@vadeg vadeg commented Oct 16, 2022

  • Update violation message for incorrect usage of well understood status codes
  • Rename functions in tests to have clear meaning
  • Reformat map filters in several rule checks

Fixes #1399

@codecov-commenter
Copy link

codecov-commenter commented Oct 16, 2022

Codecov Report

Base: 75.01% // Head: 76.39% // Increases project coverage by +1.37% 🎉

Coverage data is based on head (6feaf53) compared to base (e2be83e).
Patch coverage: 63.63% of modified lines in pull request are covered.

Additional details and impacted files
@@             Coverage Diff              @@
##               main    #1414      +/-   ##
============================================
+ Coverage     75.01%   76.39%   +1.37%     
+ Complexity      931      721     -210     
============================================
  Files           167      170       +3     
  Lines          2682     2800     +118     
  Branches        492      490       -2     
============================================
+ Hits           2012     2139     +127     
- Misses          410      413       +3     
+ Partials        260      248      -12     
Impacted Files Coverage Δ
.../ruleset/zalando/UseStandardHttpStatusCodesRule.kt 86.20% <63.63%> (+5.43%) ⬆️
...zally/configuration/RulesValidatorConfiguration.kt 60.00% <0.00%> (-40.00%) ⬇️
...do/zally/configuration/RulesConfigConfiguration.kt 66.66% <0.00%> (-33.34%) ⬇️
...do/zally/configuration/RulesPolicyConfiguration.kt 66.66% <0.00%> (-33.34%) ⬇️
...zally/configuration/ContextFactoryConfiguration.kt 66.66% <0.00%> (-33.34%) ⬇️
...r/src/main/kotlin/org/zalando/zally/dto/RuleDTO.kt 85.71% <0.00%> (-14.29%) ⬇️
...lin/org/zalando/zally/dto/ApiDefinitionResponse.kt 85.71% <0.00%> (-14.29%) ⬇️
...n/kotlin/org/zalando/zally/core/AbstractRuleSet.kt 44.44% <0.00%> (-12.70%) ⬇️
...g/zalando/zally/ruleset/zally/PathParameterRule.kt 64.00% <0.00%> (-11.00%) ⬇️
.../main/kotlin/org/zalando/zally/dto/ViolationDTO.kt 90.00% <0.00%> (-10.00%) ⬇️
... and 85 more

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

☔ View full report at Codecov.
📢 Do you have feedback about the report comment? Let us know in this issue.

@vadeg vadeg closed this Oct 17, 2022
@vadeg vadeg reopened this Oct 17, 2022
* Update violation message for incorrect usage of well understood status codes
* Rename functions in tests to have clear meaning
* Reformat map filters in several rule checks
@vadeg vadeg force-pushed the update-standard-http-status-codes-rule branch from 6feaf53 to 791f892 Compare October 17, 2022 18:35
@vadeg
Copy link
Contributor Author

vadeg commented Oct 17, 2022

👍

@vadeg
Copy link
Contributor Author

vadeg commented Oct 17, 2022

@tkrop please review

@tkrop
Copy link
Member

tkrop commented Oct 17, 2022

👍

@tkrop tkrop merged commit 2ef3814 into main Oct 17, 2022
@tkrop tkrop deleted the update-standard-http-status-codes-rule branch October 17, 2022 21:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Better violation message for "wrong status code for this HTTP method"
3 participants