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

fix: treat response schemas with an items field as arrays #99

Merged
merged 1 commit into from
Aug 27, 2019

Conversation

dpopp07
Copy link
Member

@dpopp07 dpopp07 commented Aug 19, 2019

If there is no type field specifying that the response schema is an array but there is an items field, treat the response schema as an array and flag it as a problem.

Resolves #98

@dpopp07 dpopp07 requested a review from mkistler August 19, 2019 15:36
@codecov
Copy link

codecov bot commented Aug 19, 2019

Codecov Report

Merging #99 into master will increase coverage by <.01%.
The diff coverage is 100%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master      #99      +/-   ##
==========================================
+ Coverage   92.03%   92.04%   +<.01%     
==========================================
  Files          52       52              
  Lines        1871     1873       +2     
==========================================
+ Hits         1722     1724       +2     
  Misses        149      149
Impacted Files Coverage Δ
...ion/2and3/semantic-validators/operations-shared.js 98.57% <100%> (+0.04%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 8a2102a...a284836. Read the comment docs.

Copy link
Contributor

@mkistler mkistler left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good! 👍

@dpopp07 dpopp07 merged commit 3383114 into master Aug 27, 2019
@dpopp07 dpopp07 deleted the treat-schema-with-items-as-array branch August 27, 2019 13:51
dpopp07 pushed a commit that referenced this pull request Aug 27, 2019
## [0.13.4](v0.13.3...v0.13.4) (2019-08-27)

### Bug Fixes

* treat response schemas with an `items` field as arrays, even if there is no `type` ([#99](#99)) ([3383114](3383114))
@dpopp07
Copy link
Member Author

dpopp07 commented Aug 27, 2019

🎉 This PR is included in version 0.13.4 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

File unexpectedly passes validation - should complain about arrays in response or undefined type
2 participants