|
@@ -164,11 +164,11 @@ class RestAPIUserTest extends PHPUnit\Framework\TestCase
|
|
|
|
|
|
print __METHOD__." Request GET url=".$url."\n";
|
|
|
$result=getURLContent($url, 'GET', '', 1, array(), array('http', 'https'), 2);
|
|
|
- //print __METHOD__." Result for unexisting user: ".var_export($result, true)."\n";
|
|
|
+ print __METHOD__." result for get on unexisting user: ".var_export($result, true)."\n";
|
|
|
print __METHOD__." curl_error_no: ".$result['curl_error_no']."\n";
|
|
|
$this->assertEquals($result['curl_error_no'], '');
|
|
|
$object=json_decode($result['content'], true);
|
|
|
- $this->assertNotNull($object, "Parsing of json result must no be null");
|
|
|
+ $this->assertNotNull($object, "Parsing of json result must not be null");
|
|
|
$this->assertEquals(404, $object['error']['code']);
|
|
|
|
|
|
$url = $this->api_url.'/users/1?api_key='.$this->api_key;
|
|
@@ -179,7 +179,7 @@ class RestAPIUserTest extends PHPUnit\Framework\TestCase
|
|
|
print __METHOD__." curl_error_no: ".$result['curl_error_no']."\n";
|
|
|
$this->assertEquals($result['curl_error_no'], '');
|
|
|
$object=json_decode($result['content'], true);
|
|
|
- $this->assertNotNull($object, "Parsing of json result must no be null");
|
|
|
+ $this->assertNotNull($object, "Parsing of json result must not be null");
|
|
|
$this->assertEquals(1, $object['statut']);
|
|
|
}
|
|
|
|
|
@@ -222,7 +222,7 @@ class RestAPIUserTest extends PHPUnit\Framework\TestCase
|
|
|
$body = json_encode($bodyobj);
|
|
|
print __METHOD__." Request POST url=".$url."\n";
|
|
|
$result=getURLContent($url, 'POST', $body, 1, $addheaders, array('http', 'https'), 2);
|
|
|
- print __METHOD__." Result code for creating user ".var_export($result, true)."\n";
|
|
|
+ print __METHOD__." rclsesult code for creating user ".var_export($result, true)."\n";
|
|
|
print __METHOD__." curl_error_no: ".$result['curl_error_no']."\n";
|
|
|
$this->assertEquals($result['curl_error_no'], '');
|
|
|
$resid=json_decode($result['content'], true);
|