diff --git a/core/test.class.inc.php b/core/test.class.inc.php
index c7c97686b..34455dde8 100644
--- a/core/test.class.inc.php
+++ b/core/test.class.inc.php
@@ -252,7 +252,15 @@ abstract class TestWebServices extends TestHandler
$fp = @fopen($sUrl, 'rb', false, $ctx);
if (!$fp)
{
- throw new Exception("Problem with $sUrl, $php_errormsg");
+ global $php_errormsg;
+ if (isset($php_errormsg))
+ {
+ throw new Exception("Problem with $sUrl, $php_errormsg");
+ }
+ else
+ {
+ throw new Exception("Problem with $sUrl");
+ }
}
$response = @stream_get_contents($fp);
if ($response === false)
diff --git a/pages/testlist.inc.php b/pages/testlist.inc.php
index 1ce7b6b99..eec5181e4 100644
--- a/pages/testlist.inc.php
+++ b/pages/testlist.inc.php
@@ -1206,7 +1206,7 @@ class TestImportREST extends TestWebServices
static public function GetDescription()
{
- return 'Bulk load in the background';
+ return 'Test various options and fonctionality of import.php';
}
protected function DoExecSingleLoad($aLoadSpec)
@@ -1230,12 +1230,21 @@ class TestImportREST extends TestWebServices
$sArguments = implode('
', $aGetParamReport);
+ if (strlen($sCsvData) > 5000)
+ {
+ $sCsvDataViewable = 'INPUT TOO LONG TO BE DISPLAYED ('.strlen($sCsvData).")\n".substr($sCsvData, 0, 500)."\n... TO BE CONTINUED";
+ }
+ else
+ {
+ $sCsvDataViewable = $sCsvData;
+ }
+
echo "
$sCsvData\n"; + echo "
$sCsvDataViewable\n"; echo "