File tree Expand file tree Collapse file tree 1 file changed +4
-8
lines changed
Tests/Transport/Smtp/Stream Expand file tree Collapse file tree 1 file changed +4
-8
lines changed Original file line number Diff line number Diff line change 16
16
17
17
class SocketStreamTest extends TestCase
18
18
{
19
- /**
20
- * @expectedException \Symfony\Component\Mailer\Exception\TransportException
21
- * @expectedExceptionMessageRegExp /Connection refused|unable to connect/
22
- */
23
19
public function testSocketErrorNoConnection ()
24
20
{
21
+ $ this ->expectException ('Symfony\Component\Mailer\Exception\TransportException ' );
22
+ $ this ->expectExceptionMessageRegExp ('/Connection refused|unable to connect/ ' );
25
23
$ s = new SocketStream ();
26
24
$ s ->setTimeout (0.1 );
27
25
$ s ->setPort (9999 );
28
26
$ s ->initialize ();
29
27
}
30
28
31
- /**
32
- * @expectedException \Symfony\Component\Mailer\Exception\TransportException
33
- * @expectedExceptionMessageRegExp /no valid certs found cafile stream|Unable to find the socket transport "ssl"/
34
- */
35
29
public function testSocketErrorBeforeConnectError ()
36
30
{
31
+ $ this ->expectException ('Symfony\Component\Mailer\Exception\TransportException ' );
32
+ $ this ->expectExceptionMessageRegExp ('/no valid certs found cafile stream|Unable to find the socket transport "ssl"/ ' );
37
33
$ s = new SocketStream ();
38
34
$ s ->setStreamOptions ([
39
35
'ssl ' => [
You can’t perform that action at this time.
0 commit comments