Replies: 1 comment 3 replies
-
This happens because pytest reacts to warning. Consider switching to new BuilderAPI for brokers. Before, we used to pass result backends as parameters to brokers, but now we use builder pattern to configure parameters that are not related to brokers. So this broker = MyBroker(result_backend=MyResBackend()) Should become this: broker = MyBroker().with_result_backend(MyResBackend()) Also, I'm creating a repo with example projects to show all possible pitfalls with different frameworks. |
Beta Was this translation helpful? Give feedback.
3 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
We build most of our applications using FastAPI and TaskIQ works beautifully with the integration. We also use the recommend method for testing FastAPI applications where we provide a test client as a
fixture
:and then each test is able to use it to call the endpoints:
the quoted example spins off a TaskIQ based job to send a verification email. However when the handler gets to that portion, we get the following error:
I assume this is because of the way FastAPI's test client executes the API endpoints when testing which would bypass the TaskIQ bootstrapping process. I am wondering what the solution could be where the test suite can invoke the TaskIQ jobs to achieve a wholistic test suite.
Any thoughts on this will be very welcome.
Beta Was this translation helpful? Give feedback.
All reactions