diff --git a/test/phpunit/ContratTest.php b/test/phpunit/ContratTest.php index ac919f8d69c..9e035c7b69d 100644 --- a/test/phpunit/ContratTest.php +++ b/test/phpunit/ContratTest.php @@ -139,8 +139,14 @@ class ContratTest extends PHPUnit\Framework\TestCase $langs=$this->savlangs; $db=$this->savdb; + $soc = new Societe($db); + $soc->name = "ContratTest Unittest"; + $socid = $soc->create($user); + $this->assertLessThan($socid, 0, $soc->errorsToString()); + $localobject=new Contrat($db); $localobject->initAsSpecimen(); + $localobject->socid = $socid; $result=$localobject->create($user); print __METHOD__." result=".$result."\n";