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

Api specs fixes #1898

Merged
merged 8 commits into from Sep 28, 2018

Conversation

Projects
None yet
2 participants
@noirbizarre
Copy link
Member

commented Sep 27, 2018

This PR fixes a lot of swagger.json API specs bugs allowing it to validate and so being able to use swagger tools that weren't working (like the new version of Swagger UI).

Some fixes are on the flask-restplus side so it has been updated with it

@noirbizarre noirbizarre added this to the 1.6.0 milestone Sep 27, 2018

@noirbizarre noirbizarre requested a review from opendatateam/etalab Sep 27, 2018

@noirbizarre noirbizarre force-pushed the noirbizarre:api-specs-fixes branch from 42b6bb2 to 2537ab8 Sep 27, 2018

@abulte

abulte approved these changes Sep 27, 2018

Copy link
Member

left a comment

Should we automate specs validation in a test?

@noirbizarre

This comment has been minimized.

Copy link
Member Author

commented Sep 27, 2018

I think we should. In this PR or another ?

@abulte

This comment has been minimized.

Copy link
Member

commented Sep 27, 2018

@noirbizarre in this PR if you have time I think it's OK

@noirbizarre noirbizarre force-pushed the noirbizarre:api-specs-fixes branch from 2537ab8 to 3ad7546 Sep 28, 2018

@noirbizarre

This comment has been minimized.

Copy link
Member Author

commented Sep 28, 2018

Added validation testing. (flask-restplus now provide schemas and validation support)

@noirbizarre noirbizarre force-pushed the noirbizarre:api-specs-fixes branch from 3ad7546 to f923c23 Sep 28, 2018

@abulte

abulte approved these changes Sep 28, 2018

schema = json.loads(json.dumps(api.__schema__))
try:
schemas.validate(schema)
success('API specificationsare valid')

This comment has been minimized.

Copy link
@abulte

abulte Sep 28, 2018

Member

s/specificationsare/specifications are/

@noirbizarre noirbizarre force-pushed the noirbizarre:api-specs-fixes branch from fb4efc4 to d5ac255 Sep 28, 2018

@noirbizarre noirbizarre merged commit d965fa9 into opendatateam:master Sep 28, 2018

3 checks passed

ci/circleci: assets Your tests passed on CircleCI!
Details
ci/circleci: dist Your tests passed on CircleCI!
Details
ci/circleci: python Your tests passed on CircleCI!
Details

@noirbizarre noirbizarre deleted the noirbizarre:api-specs-fixes branch Sep 28, 2018

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.