minor #39731 fix code style (xabbuh)
This PR was merged into the 5.3-dev branch.
Discussion
----------
fix code style
| Q | A
| ------------- | ---
| Branch? | 5.x
| Bug fix? | no
| New feature? | no
| Deprecations? | no
| Tickets |
| License | MIT
| Doc PR |
Commits
-------
70ab0848ba
fix code style
This commit is contained in:
commit
9e47d90019
@ -5,6 +5,6 @@ $container->loadFromExtension('framework', [
|
|||||||
'log' => [
|
'log' => [
|
||||||
\E_NOTICE => \Psr\Log\LogLevel::ERROR,
|
\E_NOTICE => \Psr\Log\LogLevel::ERROR,
|
||||||
\E_WARNING => \Psr\Log\LogLevel::ERROR,
|
\E_WARNING => \Psr\Log\LogLevel::ERROR,
|
||||||
]
|
],
|
||||||
],
|
],
|
||||||
]);
|
]);
|
||||||
|
@ -12,7 +12,6 @@
|
|||||||
namespace Symfony\Component\Console\Tests\Input;
|
namespace Symfony\Component\Console\Tests\Input;
|
||||||
|
|
||||||
use PHPUnit\Framework\TestCase;
|
use PHPUnit\Framework\TestCase;
|
||||||
use Symfony\Component\Console\Exception\InvalidOptionException;
|
|
||||||
use Symfony\Component\Console\Input\ArrayInput;
|
use Symfony\Component\Console\Input\ArrayInput;
|
||||||
use Symfony\Component\Console\Input\InputArgument;
|
use Symfony\Component\Console\Input\InputArgument;
|
||||||
use Symfony\Component\Console\Input\InputDefinition;
|
use Symfony\Component\Console\Input\InputDefinition;
|
||||||
|
@ -96,48 +96,48 @@ class AmazonSqsTransportTest extends TestCase
|
|||||||
$this->assertInstanceOf(MessageCountAwareInterface::class, $transport);
|
$this->assertInstanceOf(MessageCountAwareInterface::class, $transport);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function testItCanGetMessagesViaTheReceiver(): void
|
public function testItCanGetMessagesViaTheReceiver()
|
||||||
{
|
{
|
||||||
$envelopes = [new Envelope(new \stdClass()), new Envelope(new \stdClass())];
|
$envelopes = [new Envelope(new \stdClass()), new Envelope(new \stdClass())];
|
||||||
$this->receiver->expects($this->once())->method('get')->willReturn($envelopes);
|
$this->receiver->expects($this->once())->method('get')->willReturn($envelopes);
|
||||||
$this->assertSame($envelopes, $this->transport->get());
|
$this->assertSame($envelopes, $this->transport->get());
|
||||||
}
|
}
|
||||||
|
|
||||||
public function testItCanAcknowledgeAMessageViaTheReceiver(): void
|
public function testItCanAcknowledgeAMessageViaTheReceiver()
|
||||||
{
|
{
|
||||||
$envelope = new Envelope(new \stdClass());
|
$envelope = new Envelope(new \stdClass());
|
||||||
$this->receiver->expects($this->once())->method('ack')->with($envelope);
|
$this->receiver->expects($this->once())->method('ack')->with($envelope);
|
||||||
$this->transport->ack($envelope);
|
$this->transport->ack($envelope);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function testItCanRejectAMessageViaTheReceiver(): void
|
public function testItCanRejectAMessageViaTheReceiver()
|
||||||
{
|
{
|
||||||
$envelope = new Envelope(new \stdClass());
|
$envelope = new Envelope(new \stdClass());
|
||||||
$this->receiver->expects($this->once())->method('reject')->with($envelope);
|
$this->receiver->expects($this->once())->method('reject')->with($envelope);
|
||||||
$this->transport->reject($envelope);
|
$this->transport->reject($envelope);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function testItCanGetMessageCountViaTheReceiver(): void
|
public function testItCanGetMessageCountViaTheReceiver()
|
||||||
{
|
{
|
||||||
$messageCount = 15;
|
$messageCount = 15;
|
||||||
$this->receiver->expects($this->once())->method('getMessageCount')->willReturn($messageCount);
|
$this->receiver->expects($this->once())->method('getMessageCount')->willReturn($messageCount);
|
||||||
$this->assertSame($messageCount, $this->transport->getMessageCount());
|
$this->assertSame($messageCount, $this->transport->getMessageCount());
|
||||||
}
|
}
|
||||||
|
|
||||||
public function testItCanSendAMessageViaTheSender(): void
|
public function testItCanSendAMessageViaTheSender()
|
||||||
{
|
{
|
||||||
$envelope = new Envelope(new \stdClass());
|
$envelope = new Envelope(new \stdClass());
|
||||||
$this->sender->expects($this->once())->method('send')->with($envelope)->willReturn($envelope);
|
$this->sender->expects($this->once())->method('send')->with($envelope)->willReturn($envelope);
|
||||||
$this->assertSame($envelope, $this->transport->send($envelope));
|
$this->assertSame($envelope, $this->transport->send($envelope));
|
||||||
}
|
}
|
||||||
|
|
||||||
public function testItCanSetUpTheConnection(): void
|
public function testItCanSetUpTheConnection()
|
||||||
{
|
{
|
||||||
$this->connection->expects($this->once())->method('setup');
|
$this->connection->expects($this->once())->method('setup');
|
||||||
$this->transport->setup();
|
$this->transport->setup();
|
||||||
}
|
}
|
||||||
|
|
||||||
public function testItConvertsHttpExceptionDuringSetupIntoTransportException(): void
|
public function testItConvertsHttpExceptionDuringSetupIntoTransportException()
|
||||||
{
|
{
|
||||||
$this->connection
|
$this->connection
|
||||||
->expects($this->once())
|
->expects($this->once())
|
||||||
@ -149,13 +149,13 @@ class AmazonSqsTransportTest extends TestCase
|
|||||||
$this->transport->setup();
|
$this->transport->setup();
|
||||||
}
|
}
|
||||||
|
|
||||||
public function testItCanResetTheConnection(): void
|
public function testItCanResetTheConnection()
|
||||||
{
|
{
|
||||||
$this->connection->expects($this->once())->method('reset');
|
$this->connection->expects($this->once())->method('reset');
|
||||||
$this->transport->reset();
|
$this->transport->reset();
|
||||||
}
|
}
|
||||||
|
|
||||||
public function testItConvertsHttpExceptionDuringResetIntoTransportException(): void
|
public function testItConvertsHttpExceptionDuringResetIntoTransportException()
|
||||||
{
|
{
|
||||||
$this->connection
|
$this->connection
|
||||||
->expects($this->once())
|
->expects($this->once())
|
||||||
|
@ -12,7 +12,6 @@
|
|||||||
namespace Symfony\Component\Notifier\Transport;
|
namespace Symfony\Component\Notifier\Transport;
|
||||||
|
|
||||||
use Symfony\Component\Notifier\Exception\TransportExceptionInterface;
|
use Symfony\Component\Notifier\Exception\TransportExceptionInterface;
|
||||||
use Symfony\Component\Notifier\Exception\UnsupportedMessageTypeException;
|
|
||||||
use Symfony\Component\Notifier\Message\MessageInterface;
|
use Symfony\Component\Notifier\Message\MessageInterface;
|
||||||
use Symfony\Component\Notifier\Message\SentMessage;
|
use Symfony\Component\Notifier\Message\SentMessage;
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user