File: ProcessAcceptanceTest.php

package info (click to toggle)
libphp-swiftmailer 6.3.0-8
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 4,164 kB
  • sloc: php: 27,203; sh: 36; makefile: 16
file content (46 lines) | stat: -rw-r--r-- 1,301 bytes parent folder | download
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
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
<?php

use PHPUnit\Framework\Attributes\DoesNotPerformAssertions;

class Swift_Transport_StreamBuffer_ProcessAcceptanceTest extends Swift_Transport_StreamBuffer_AbstractStreamBufferAcceptanceTestCase
{
    protected function setUp(): void
    {
        if (!\defined('SWIFT_SENDMAIL_PATH')) {
            $this->markTestSkipped(
                'Cannot run test without a path to sendmail (define '.
                'SWIFT_SENDMAIL_PATH in tests/acceptance.conf.php if you wish to run this test)'
            );
        }

        parent::setUp();
    }

    #[DoesNotPerformAssertions]
    public function testReadLine()
    {
        if (true == getenv('GITHUB_ACTIONS')) {
            $this->markTestSkipped(
                'Cannot run test on CI due to unknown PCRE pattern failure'
            );
        }
    }

    #[DoesNotPerformAssertions]
    public function testWrite()
    {
        if (true == getenv('GITHUB_ACTIONS')) {
            $this->markTestSkipped(
                'Cannot run test on CI due to unknown PCRE pattern failure'
            );
        }
    }

    protected function initializeBuffer()
    {
        $this->buffer->initialize([
            'type' => Swift_Transport_IoBuffer::TYPE_PROCESS,
            'command' => SWIFT_SENDMAIL_PATH.' -bs',
        ]);
    }
}