use Symfony\Component\Messenger\Envelope;
use Symfony\Component\Messenger\Retry\MultiplierRetryStrategy;
use Symfony\Component\Messenger\Stamp\RedeliveryStamp;
class MultiplierRetryStrategyTest extends TestCase
{ public function testIsRetryable() { $strategy =
new MultiplierRetryStrategy(3
);
$envelope =
new Envelope(new \
stdClass(),
[new RedeliveryStamp(0
)]);
$this->
assertTrue($strategy->
isRetryable($envelope));
} public function testIsNotRetryable() { $strategy =
new MultiplierRetryStrategy(3
);
$envelope =
new Envelope(new \
stdClass(),
[new RedeliveryStamp(3
)]);
$this->
assertFalse($strategy->
isRetryable($envelope));
} public function testIsNotRetryableWithZeroMax() {