fix tests and replace file_exists

This commit is contained in:
Dennis Eichhorn 2020-10-08 15:12:24 +02:00
parent 49fa2450cd
commit 874112f8eb
4 changed files with 48 additions and 0 deletions

View File

@ -23,6 +23,10 @@ use phpOMS\Localization\ISO639x1Enum;
*/
class CostCenterMapperTest extends \PHPUnit\Framework\TestCase
{
/**
* @covers Modules\Accounting\Models\CostCenterMapper
* @group module
*/
public function testCR() : void
{
$costcenter = new CostCenter();

View File

@ -21,6 +21,10 @@ use Modules\Accounting\Models\CostCenter;
*/
class CostCenterTest extends \PHPUnit\Framework\TestCase
{
/**
* @covers Modules\Accounting\Models\CostCenter
* @group module
*/
public function testDefault() : void
{
$cc = new CostCenter();
@ -32,6 +36,10 @@ class CostCenterTest extends \PHPUnit\Framework\TestCase
self::assertNull($cc->getParent());
}
/**
* @covers Modules\Accounting\Models\CostCenter
* @group module
*/
public function testNameInputOutput() : void
{
$cc = new CostCenter();
@ -40,6 +48,10 @@ class CostCenterTest extends \PHPUnit\Framework\TestCase
self::assertEquals('TestName', $cc->getName());
}
/**
* @covers Modules\Accounting\Models\CostCenter
* @group module
*/
public function testCodeInputOutput() : void
{
$cc = new CostCenter();
@ -48,6 +60,10 @@ class CostCenterTest extends \PHPUnit\Framework\TestCase
self::assertEquals('TestCode', $cc->getCode());
}
/**
* @covers Modules\Accounting\Models\CostCenter
* @group module
*/
public function testDescriptionInputOutput() : void
{
$cc = new CostCenter();
@ -56,6 +72,10 @@ class CostCenterTest extends \PHPUnit\Framework\TestCase
self::assertEquals('TestDescription', $cc->getDescription());
}
/**
* @covers Modules\Accounting\Models\CostCenter
* @group module
*/
public function testParentInputOutput() : void
{
$cc = new CostCenter();

View File

@ -23,6 +23,10 @@ use phpOMS\Localization\ISO639x1Enum;
*/
class CostObjectMapperTest extends \PHPUnit\Framework\TestCase
{
/**
* @covers Modules\Accounting\Models\CostObjectMapper
* @group module
*/
public function testCR() : void
{
$costobject = new CostObject();

View File

@ -21,6 +21,10 @@ use Modules\Accounting\Models\CostObject;
*/
class CostObjectTest extends \PHPUnit\Framework\TestCase
{
/**
* @covers Modules\Accounting\Models\CostObject
* @group module
*/
public function testDefault() : void
{
$co = new CostObject();
@ -32,6 +36,10 @@ class CostObjectTest extends \PHPUnit\Framework\TestCase
self::assertNull($co->getParent());
}
/**
* @covers Modules\Accounting\Models\CostObject
* @group module
*/
public function testNameInputOutput() : void
{
$co = new CostObject();
@ -40,6 +48,10 @@ class CostObjectTest extends \PHPUnit\Framework\TestCase
self::assertEquals('TestName', $co->getName());
}
/**
* @covers Modules\Accounting\Models\CostObject
* @group module
*/
public function testCodeInputOutput() : void
{
$co = new CostObject();
@ -48,6 +60,10 @@ class CostObjectTest extends \PHPUnit\Framework\TestCase
self::assertEquals('TestCode', $co->getCode());
}
/**
* @covers Modules\Accounting\Models\CostObject
* @group module
*/
public function testDescriptionInputOutput() : void
{
$co = new CostObject();
@ -56,6 +72,10 @@ class CostObjectTest extends \PHPUnit\Framework\TestCase
self::assertEquals('TestDescription', $co->getDescription());
}
/**
* @covers Modules\Accounting\Models\CostObject
* @group module
*/
public function testParentInputOutput() : void
{
$co = new CostObject();