Fix: The way we tested if a ref/id already exists was wrong. Introduce a

common static method for this. Removed verifNumRef method.
Fix: Add missing logs
This commit is contained in:
Laurent Destailleur
2014-05-13 10:12:45 +02:00
parent 3a29d7dac1
commit 69eaefc459
16 changed files with 114 additions and 254 deletions

View File

@@ -185,7 +185,7 @@ class ProjectTest extends PHPUnit_Framework_TestCase
$this->assertLessThan($result, 0);
return $localobject;
}
/**
* testProjectOther
*
@@ -232,27 +232,5 @@ class ProjectTest extends PHPUnit_Framework_TestCase
return $result;
}
/**
* testVerifyNumRef
*
* @return void
*/
public function testVerifyNumRef()
{
global $conf,$user,$langs,$db;
$conf=$this->savconf;
$user=$this->savuser;
$langs=$this->savlangs;
$db=$this->savdb;
$localobject=new Project($this->savdb);
$result=$localobject->ref='refthatdoesnotexists';
$result=$localobject->VerifyNumRef();
print __METHOD__." result=".$result."\n";
$this->assertEquals($result, 0);
return $result;
}
}
?>