Merge remote-tracking branch 'origin/develop'

This commit is contained in:
snipe 2024-01-25 21:45:49 +00:00
commit 14db425725
2 changed files with 1 additions and 19 deletions

View file

@ -46,15 +46,6 @@ class AssetModel extends SnipeModel
protected $injectUniqueIdentifier = true;
use ValidatingTrait;
public function setEolAttribute($value)
{
if ($value == '') {
$value = 0;
}
$this->attributes['eol'] = $value;
}
/**
* The attributes that are mass assignable.
*

View file

@ -10,16 +10,7 @@ use Tests\TestCase;
class AssetModelTest extends TestCase
{
use InteractsWithSettings;
public function testAnAssetModelZerosOutBlankEols()
{
$am = new AssetModel;
$am->eol = '';
$this->assertTrue($am->eol === 0);
$am->eol = '4';
$this->assertTrue($am->eol == 4);
}
public function testAnAssetModelContainsAssets()
{
$category = Category::factory()->create([