AsMonologProcessorTest.php 984 B

123456789101112131415161718192021222324252627282930313233
  1. <?php declare(strict_types=1);
  2. /*
  3. * This file is part of the Monolog package.
  4. *
  5. * (c) Jordi Boggiano <j.boggiano@seld.be>
  6. *
  7. * For the full copyright and license information, please view the LICENSE
  8. * file that was distributed with this source code.
  9. */
  10. namespace Monolog\Attribute;
  11. use PHPUnit\Framework\TestCase;
  12. /**
  13. * @requires PHP 8.0
  14. */
  15. final class AsMonologProcessorTest extends TestCase
  16. {
  17. public function test(): void
  18. {
  19. $asMonologProcessor = new AsMonologProcessor('channel', 'handler', 'method');
  20. $this->assertSame('channel', $asMonologProcessor->channel);
  21. $this->assertSame('handler', $asMonologProcessor->handler);
  22. $this->assertSame('method', $asMonologProcessor->method);
  23. $asMonologProcessor = new AsMonologProcessor(null, null, null);
  24. $this->assertNull($asMonologProcessor->channel);
  25. $this->assertNull($asMonologProcessor->handler);
  26. $this->assertNull($asMonologProcessor->method);
  27. }
  28. }