Add entitytotest test, because a LDAP user can override the entity restriction without this test
Merge branch '3.5' of https://github.com/Dolibarr/dolibarr into 3.5
In some cases of improper use of the delete () function, the complete repertoire of propale objects, invoice or order was deleted.

Ex in agefodd module:
	$obj_link=new Propal($db);
        $obj_link->id=$agf->propalid;
        $resultdel=$obj_link->delete($user);

To prevent misuse of the function, the reference is not considered given
Merge branch '3.5' of https://github.com/Dolibarr/dolibarr into 3.5
Add multicompany->enabled test
Merge pull request #1348 from atm-alexis/3.5

Improper use of delete() function and ldap with multientity bug corrections