mirror of
https://github.com/php-curl-class/php-curl-class.git
synced 2026-08-30 04:01:47 +00:00
Add assertions to fix "risky tests" warning
This commit is contained in:
@@ -2620,7 +2620,8 @@ class CurlTest extends \PHPUnit\Framework\TestCase
|
||||
$reflection_method->setAccessible(true);
|
||||
|
||||
$curl = new Curl();
|
||||
$reflection_method->invoke($curl, $response);
|
||||
$response_headers = $reflection_method->invoke($curl, $response);
|
||||
$this->assertArrayHasKey('Status-Line', $response_headers);
|
||||
}
|
||||
|
||||
public function testArrayToStringConversion()
|
||||
|
||||
@@ -2461,9 +2461,13 @@ class MultiCurlTest extends \PHPUnit\Framework\TestCase
|
||||
$curl->setOpt(CURLOPT_CUSTOMREQUEST, 'GET');
|
||||
$curl->setOpt(CURLOPT_HTTPGET, true);
|
||||
|
||||
$complete_called = false;
|
||||
$multi_curl = new MultiCurl();
|
||||
$multi_curl->addCurl($curl);
|
||||
$multi_curl->addCurl($curl)->complete(function ($instance) use (&$complete_called) {
|
||||
$complete_called = true;
|
||||
});
|
||||
$multi_curl->start();
|
||||
$this->assertTrue($complete_called);
|
||||
}
|
||||
|
||||
public function testSequentialId()
|
||||
|
||||
Reference in New Issue
Block a user