Skip to content

Add APIClient type to test cases #24

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

Merged
merged 2 commits into from
Aug 12, 2019
Merged

Add APIClient type to test cases #24

merged 2 commits into from
Aug 12, 2019

Conversation

MarcinWieczorek
Copy link
Contributor

client_class is explicitly set to APIClient in rest_framework/test.py, but I suppose that the client is created dynamically, thus drf-stubs have no idea that it should be an APIClient and not a Client warning me about response.data and client.force_authenticate.

@MarcinWieczorek
Copy link
Contributor Author

Any comment on this?

@sobolevn
Copy link
Member

@MarcinWieczorek can you please trigger the build once again? CI is failing for some reason right now.

@MarcinWieczorek
Copy link
Contributor Author

How? CI doesn't even recognize the project now, I guess it won't be any better.

@sobolevn
Copy link
Member

@mkurnikov we need your help with the CI 🙂

@sobolevn sobolevn requested a review from mkurnikov August 12, 2019 16:43
@MarcinWieczorek
Copy link
Contributor Author

It's the README that is wrong, it points to https://travis-ci.org/mkurnikov/djangorestframework-stubs.svg?branch=master and I guess we're at typeddjango now. Mind if I correct that on this branch to trigger the build?

@sobolevn
Copy link
Member

@MarcinWieczorek sure

@sobolevn sobolevn merged commit 9284cc4 into typeddjango:master Aug 12, 2019
@sobolevn
Copy link
Member

Thanks!

@MarcinWieczorek MarcinWieczorek deleted the patch-testclient branch August 13, 2019 08:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

2 participants