forked from Wavyzz/dolibarr
error management
This commit is contained in:
@@ -346,6 +346,7 @@ class Entrepot extends CommonObject
|
|||||||
{
|
{
|
||||||
$error++;
|
$error++;
|
||||||
$this->errors[] = $this->db->lasterror();
|
$this->errors[] = $this->db->lasterror();
|
||||||
|
dol_syslog(get_class($this)."::delete Error ".$this->db->lasterror(), LOG_ERR);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -358,6 +359,7 @@ class Entrepot extends CommonObject
|
|||||||
{
|
{
|
||||||
$error++;
|
$error++;
|
||||||
$this->errors[] = $this->db->lasterror();
|
$this->errors[] = $this->db->lasterror();
|
||||||
|
dol_syslog(get_class($this)."::delete Error ".$this->db->lasterror(), LOG_ERR);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -238,7 +238,7 @@ class EntrepotTest extends PHPUnit_Framework_TestCase
|
|||||||
|
|
||||||
$result=$localobject->delete($user);
|
$result=$localobject->delete($user);
|
||||||
print __METHOD__." id=".$id." result=".$result."\n";
|
print __METHOD__." id=".$id." result=".$result."\n";
|
||||||
$this->assertLessThan($result, 0);
|
$this->assertLessThan($result, 0, $localobject->errorsToString());
|
||||||
|
|
||||||
return $result;
|
return $result;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user