PHP  
 PHP_7_1
downloads | QA | documentation | faq | getting help | mailing lists | reporting bugs | php.net sites | links | my php.net 
 

Test Failure Report for ext/sockets/tests/socket_bind.phpt ('ext/sockets - socket_bind - basic test')

Script

1: <?php
2:     $rand 
rand(1,999);
3:     
$s_c     socket_create(AF_INETSOCK_STREAMSOL_TCP);
4:     
$s_bind  socket_bind($s_c'0.0.0.0'31330+$rand);
5:     
var_dump($s_bind);
6:     
7:     
// Connect to destination address
8:     
$s_conn  socket_connect($s_c'www.php.net'80);
9:     
var_dump($s_conn);
10:     
11:     
// Write
12:     
$request 'GET / HTTP/1.1' "\r\n";
13:     
$s_write socket_write($s_c$request);
14:     
var_dump($s_write);
15:
16:     
// Close
17:     
$s_close socket_close($s_c);
18:     
var_dump($s_close);
19:
?>
20:

21:

Expected

bool(true)
bool(true)
int(16)
NULL

Output

bool(true)

Warning: socket_connect(): unable to connect [110]: Connection timed out in /var/php_gcov/PHP_7_1/ext/sockets/tests/socket_bind.php on line 8
bool(false)

Warning: socket_write(): unable to write to socket [32]: Broken pipe in /var/php_gcov/PHP_7_1/ext/sockets/tests/socket_bind.php on line 13
bool(false)
NULL

Diff

002+ 
003+ Warning: socket_connect(): unable to connect [110]: Connection timed out in /var/php_gcov/PHP_7_1/ext/sockets/tests/socket_bind.php on line 8
004+ bool(false)
005+ 
006+ Warning: socket_write(): unable to write to socket [32]: Broken pipe in /var/php_gcov/PHP_7_1/ext/sockets/tests/socket_bind.php on line 13
007+ bool(false)
002- bool(true)
003- int(16)

 

Generated at Fri, 01 Dec 2017 18:56:15 +0000 (13 days ago)

Copyright © 2005-2017 The PHP Group
All rights reserved.