diff --git a/.github/workflows/bechmark.yml b/.github/workflows/benchmark.yml similarity index 98% rename from .github/workflows/bechmark.yml rename to .github/workflows/benchmark.yml index c3421912..129af85e 100644 --- a/.github/workflows/bechmark.yml +++ b/.github/workflows/benchmark.yml @@ -22,7 +22,7 @@ on: - 'psalm.xml' - 'tests/**' -name: bechmark +name: benchmark permissions: contents: read diff --git a/composer.json b/composer.json index 91ca93d6..4c4219f6 100644 --- a/composer.json +++ b/composer.json @@ -6,12 +6,9 @@ "yii", "queue", "async", - "gii", - "db", "redis", "rabbitmq", "beanstalk", - "gearman", "sqs" ], "license": "BSD-3-Clause", diff --git a/src/Exception/MessageFailureException.php b/src/Exception/MessageFailureException.php index 44d5aa99..406c2333 100644 --- a/src/Exception/MessageFailureException.php +++ b/src/Exception/MessageFailureException.php @@ -19,7 +19,7 @@ public function __construct( ) { $messageId = IdEnvelope::fromMessage($queueMessage)->getId(); $exceptionMessage = sprintf( - "Processing of message %s is stopped because of an exception:\n%s.", + "Processing of message %s is stopped because of an exception:\n%s", $messageId === null ? 'without ID' : "#$messageId", $previous->getMessage(), ); diff --git a/tests/Unit/WorkerTest.php b/tests/Unit/WorkerTest.php index adab4e2f..0eea359b 100644 --- a/tests/Unit/WorkerTest.php +++ b/tests/Unit/WorkerTest.php @@ -64,13 +64,13 @@ public function testMessageFailWithDefinitionHandlerException(): void self::fail('Exception was not thrown.'); } catch (MessageFailureException $exception) { self::assertSame($exception::class, MessageFailureException::class); - self::assertSame($exception->getMessage(), "Processing of message without ID is stopped because of an exception:\nTest exception."); + self::assertSame("Processing of message without ID is stopped because of an exception:\nTest exception", $exception->getMessage()); self::assertEquals(['test-data'], $exception->getQueueMessage()->getPayload()); } finally { $messages = $logger->getMessages(); $this->assertNotEmpty($messages); $this->assertStringContainsString( - "Processing of message without ID is stopped because of an exception:\nTest exception.", + "Processing of message without ID is stopped because of an exception:\nTest exception", $messages[1]['message'], ); }