-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Add wait_for_message method #2628
Add wait_for_message method #2628
Conversation
Voight Kampff Integration Test Failed (Results) |
Voight Kampff Integration Test Failed (Results) |
c33c151
to
63d8879
Compare
63d8879
to
4707ffc
Compare
Voight Kampff Integration Test Failed (Results) |
Voight Kampff Integration Test Succeeded (Results) |
4707ffc
to
9a71c61
Compare
Voight Kampff Integration Test Succeeded (Results) |
9a71c61
to
511b554
Compare
Voight Kampff Integration Test Failed (Results) |
2 similar comments
Voight Kampff Integration Test Failed (Results) |
Voight Kampff Integration Test Failed (Results) |
- Use nonlocal instead of mutable object. - Set default timeout in method argument
- Refactor message waiting into a MessageWaiter class to be able to use the same code in both wait_for_message and wait_for_response. - Add some basic unittests
511b554
to
2bb9783
Compare
Voight Kampff Integration Test Failed (Results) |
Voight Kampff Integration Test Succeeded (Results) |
Nice one, love the ability to separate construction from executing the wait. Merging. |
when documenting this we should make a note objects can not be reused, since we use self.bus.once we need to create a new object for every call i dont think refactoring to allow this makes sense either, just ensure its documented to avoid head scratches |
Description
Adds
wait_for_message()
method and refactors the common code shared withwait_for_response()
into a separate class.How to test
Make sure integration tests pass and that for example
get_response()
in skills work. and the :skills cli commandContributor license agreement signed?
CLA [ Yes ]