mirror of
https://github.com/Part-DB/Part-DB-server.git
synced 2025-12-08 20:19:30 +00:00
Refactored constraints, to reuse existing mechanisms
This commit is contained in:
parent
702e5c8732
commit
0d49632b92
26 changed files with 264 additions and 542 deletions
|
|
@ -22,7 +22,7 @@ declare(strict_types=1);
|
|||
|
||||
namespace App\Tests\Entity;
|
||||
|
||||
use App\Entity\BulkImportJobStatus;
|
||||
use App\Entity\InfoProviderSystem\BulkImportJobStatus;
|
||||
use PHPUnit\Framework\TestCase;
|
||||
|
||||
class BulkImportJobStatusTest extends TestCase
|
||||
|
|
@ -39,7 +39,7 @@ class BulkImportJobStatusTest extends TestCase
|
|||
public function testEnumCases(): void
|
||||
{
|
||||
$cases = BulkImportJobStatus::cases();
|
||||
|
||||
|
||||
$this->assertCount(5, $cases);
|
||||
$this->assertContains(BulkImportJobStatus::PENDING, $cases);
|
||||
$this->assertContains(BulkImportJobStatus::IN_PROGRESS, $cases);
|
||||
|
|
@ -68,4 +68,4 @@ class BulkImportJobStatusTest extends TestCase
|
|||
$this->expectException(\ValueError::class);
|
||||
BulkImportJobStatus::from('invalid');
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue