File: MailRoundRobinTransportTest.php

package info (click to toggle)
php-laravel-framework 10.48.29%2Bdfsg-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 19,188 kB
  • sloc: php: 232,347; sh: 167; makefile: 46
file content (27 lines) | stat: -rw-r--r-- 1,020 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
<?php

namespace Illuminate\Tests\Integration\Mail;

use Orchestra\Testbench\Attributes\WithConfig;
use Orchestra\Testbench\TestCase;
use Symfony\Component\Mailer\Transport\RoundRobinTransport;

class MailRoundRobinTransportTest extends TestCase
{
    #[WithConfig('mail.default', 'roundrobin')]
    #[WithConfig('mail.mailers.roundrobin', ['transport' => 'roundrobin', 'mailers' => ['sendmail', 'array']])]
    public function testGetRoundRobinTransportWithConfiguredTransports()
    {
        $transport = app('mailer')->getSymfonyTransport();
        $this->assertInstanceOf(RoundRobinTransport::class, $transport);
    }

    #[WithConfig('mail.driver', 'roundrobin')]
    #[WithConfig('mail.mailers', ['sendmail', 'array'])]
    #[WithConfig('mail.sendmail', '/usr/sbin/sendmail -bs')]
    public function testGetRoundRobinTransportWithLaravel6StyleMailConfiguration()
    {
        $transport = app('mailer')->getSymfonyTransport();
        $this->assertInstanceOf(RoundRobinTransport::class, $transport);
    }
}