Kevin Bond
Kevin Bond
> But it could be more friendly i think. Absolutely! I'm thinking about how the API for this should work though. I'm trying to think where the `assertStamps(Not)Contains()` assertions should...
Currently, it's difficult to get the exact envelope/message you want if there are multiple messages sent with the same message class. Perhaps #3 could help but instead of returning `Envelope`...
The "queue_name" is an option that not all transports have, isn't it? The `AmqpStamp` is specific to the `AmpqTransport` so it just wouldn't be there when using the test transport.
For the stamp assertions, I was thinking these would only be applicable for "user-defined" stamps (ie `DelayStamp`).
> Just check it, yes this works fine for stamps my bad i didn't see I'm not seeing how [this](https://github.com/zenstruck/messenger-test/issues/5#issuecomment-818739393) code snipped works? How is the AmpqStamp being added when...
> I'm not seeing how this code snipped works? Forget this - I see now you're adding it (it's user defined). I thought it was something the AmpqTransport added....
So to summarize my understanding here, I'm seeing two separate features: 1. Easy access to and assertions on envelope stamps. Could an api like this work? ```php $this->messenger('my_transport')->queue()->first(MyMessage::class)->assertHasStamp(AmpqStamp::class); ``` 2....
> Some library/bundles can apply specific stamps based on annotations in the application What I meant is we can't make assertions on the stamps different "transports" add.
Can you not do? ```yaml # config/packages/test/messenger.yaml framework: messenger: transports: async: dsn: test:// serializer: App\Messenger\ExternalJsonMessageSerializer ``` The `TestTransportFactory` should create the `TestTransport` with your configured serializer. _Admittedly, this advanced messenger...
The purpose of this library as I see it, is a hybrid of the in-memory/sync transports. It's use is to assert your app is sending the correct message to your...