We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
Hello guys I need help with testing PermissionsDependency.
My current code is :
api_router.include_router( article_deviation.router, prefix="{Confidential information}", tags=["{confidential information}"], dependencies=[ Depends(azure_scheme), Depends(PermissionsDependency([QCPermission])), ], )
In the test I override azure_scheme as :
api_client = TestClient(app) app.dependency_overrides[azure_scheme] = {"Authorized": "Yes"}
but with
api_client = TestClient(app) app.dependency_overrides[PermissionsDependency([QCPermission])] = True
It does not work.
Thank you in advance! Wish you all best!
The text was updated successfully, but these errors were encountered:
No branches or pull requests
Description
Hello guys I need help with testing PermissionsDependency.
What I Did
My current code is :
In the test I override azure_scheme as :
but with
It does not work.
Thank you in advance! Wish you all best!
The text was updated successfully, but these errors were encountered: