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

Add Integration tests for responses #42

Merged
merged 1 commit into from
Jul 10, 2019
Merged

Conversation

cortinico
Copy link
Collaborator

This commit introduces multiple JUnit tests for sending and receiving
responses using the Swagger Codegen generated models.

Tests are running using the OkHttp MockWebServer and mock responses
have been inlined in the body of the tests.

This commit introduces multiple JUnit tests for sending and receiving
responses using the Swagger Codegen generated models.

Tests are running using the OkHttp MockWebServer and mock responses
have been inlined in the body of the tests.
@cortinico cortinico added the enhancement New feature or request label Jul 10, 2019
@cortinico cortinico added this to the 1.2.0 milestone Jul 10, 2019
@cortinico cortinico self-assigned this Jul 10, 2019
Copy link
Collaborator

@macisamuele macisamuele left a comment

Choose a reason for hiding this comment

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

Overall the changes looks good.
I would like to ask, if do-able, to have assertions on how the mock server is actually called.
The tests do check that the decoding of the response is working as expected but we're not doing much with respect to encoding of the request. Eventually doing it in a follow-up would be great considering the extent of the current PR.

@cortinico
Copy link
Collaborator Author

The tests do check that the decoding of the response is working as expected but we're not doing much with respect to encoding of the request. Eventually doing it in a follow-up would be great considering the extent of the current PR.

Agree, I'd rather keep it outside of this PR anyway as it's already pretty big.
I can extend every test to make sure that the requests received by the MockWebServer are properly encoded.

@macisamuele
Copy link
Collaborator

Feel free to merge as is and eventually follow up with requests received by the MockWebServer are properly encoded

@cortinico cortinico changed the title Add Integration tests for multiple scenarios Add Integration tests for responses Jul 10, 2019
@cortinico cortinico merged commit 49822a4 into master Jul 10, 2019
@cortinico cortinico deleted the add-integration-tests branch July 10, 2019 20:13
@cortinico cortinico mentioned this pull request Aug 2, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants