diff --git a/tests/Monolog/Handler/AmqpExchangeMock.php b/tests/Monolog/Handler/AmqpExchangeMock.php new file mode 100644 index 00000000..690ba078 --- /dev/null +++ b/tests/Monolog/Handler/AmqpExchangeMock.php @@ -0,0 +1,28 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace Monolog\Handler; + +class MockAMQPExchange extends \AMQPExchange +{ +public function __construct() +{ +} + +public function publish($message, $routing_key, $params = 0, $attributes = array()) +{ +return true; +} + +public function setName($name) +{ +return true; +} +} \ No newline at end of file diff --git a/tests/Monolog/Handler/AmqpHandlerTest.php b/tests/Monolog/Handler/AmqpHandlerTest.php index 780624da..201da5cc 100644 --- a/tests/Monolog/Handler/AmqpHandlerTest.php +++ b/tests/Monolog/Handler/AmqpHandlerTest.php @@ -13,6 +13,7 @@ namespace Monolog\Handler; use Monolog\TestCase; use Monolog\Logger; +use Monolog\Handler\MockAMQPExchange; /** * @covers Monolog\Handler\RotatingFileHandler @@ -57,21 +58,4 @@ class AmqpHandlerTest extends TestCase */ return new MockAMQPExchange(); } -} - -class MockAMQPExchange extends \AMQPExchange -{ - public function __construct() - { - } - - public function publish($message, $routing_key, $params = 0, $attributes = array()) - { - return true; - } - - public function setName($name) - { - return true; - } } \ No newline at end of file