Skip to content

Commit

Permalink
Set Xdebug's stack limit to 256 for legacy PHP
Browse files Browse the repository at this point in the history
  • Loading branch information
SimonFrings committed Mar 31, 2021
1 parent 1054cf6 commit d7ee56f
Showing 1 changed file with 11 additions and 8 deletions.
19 changes: 11 additions & 8 deletions tests/FunctionalTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,9 @@ public function setUpClientServer()
/** @group internet */
public function testConnection()
{
// max_nesting_level was set to 100 for PHP Versions < 5.4 which resulted in failing test for legacy PHP
ini_set('xdebug.max_nesting_level', 256);

$this->assertResolveStream($this->client->connect('www.google.com:80'));
}

Expand Down Expand Up @@ -92,8 +95,8 @@ public function testConnectionSocks5()
/** @group internet */
public function testConnectionSocksOverTls()
{
if (!function_exists('stream_socket_enable_crypto')) {
$this->markTestSkipped('Required function does not exist in your environment (HHVM?)');
if (defined('HHVM_VERSION')) {
$this->markTestSkipped('Not supported on HHVM');
}

$socket = new \React\Socket\Server('tls://127.0.0.1:0', $this->loop, array('tls' => array(
Expand All @@ -117,8 +120,8 @@ public function testConnectionSocksOverTls()
*/
public function testConnectionSocksOverTlsUsesPeerNameFromSocksUri()
{
if (!function_exists('stream_socket_enable_crypto')) {
$this->markTestSkipped('Required function does not exist in your environment (HHVM?)');
if (defined('HHVM_VERSION')) {
$this->markTestSkipped('Not supported on HHVM');
}

$socket = new \React\Socket\Server('tls://127.0.0.1:0', $this->loop, array('tls' => array(
Expand Down Expand Up @@ -421,8 +424,8 @@ public function testConnectorInvalidUnboundPortTimeout()
/** @group internet */
public function testSecureConnectorOkay()
{
if (!function_exists('stream_socket_enable_crypto')) {
$this->markTestSkipped('Required function does not exist in your environment (HHVM?)');
if (defined('HHVM_VERSION')) {
$this->markTestSkipped('Not supported on HHVM');
}

$ssl = new SecureConnector($this->client, $this->loop);
Expand All @@ -445,8 +448,8 @@ public function testSecureConnectorToBadSslWithVerifyFails()
/** @group internet */
public function testSecureConnectorToBadSslWithoutVerifyWorks()
{
if (!function_exists('stream_socket_enable_crypto')) {
$this->markTestSkipped('Required function does not exist in your environment (HHVM?)');
if (defined('HHVM_VERSION')) {
$this->markTestSkipped('Not supported on HHVM');
}

$ssl = new SecureConnector($this->client, $this->loop, array('verify_peer' => false));
Expand Down

0 comments on commit d7ee56f

Please sign in to comment.