snipe-it/tests/unit/DepreciationTest.php
2016-03-25 01:18:05 -07:00

28 lines
692 B
PHP

<?php
use App\Models\Depreciation;
use Illuminate\Foundation\Testing\WithoutMiddleware;
use Illuminate\Foundation\Testing\DatabaseMigrations;
use Illuminate\Foundation\Testing\DatabaseTransactions;
class DepreciationTest extends \Codeception\TestCase\Test
{
/**
* @var \UnitTester
*/
protected $tester;
use DatabaseMigrations;
public function testDepreciationAdd()
{
$depreciations = factory(Depreciation::class, 'depreciation')->make();
$values = [
'name' => $depreciations->name,
'months' => $depreciations->months,
];
Depreciation::create($values);
$this->tester->seeRecord('depreciations', $values);
}
}