feature test su institution

This commit is contained in:
Giuseppe Naponiello
2026-06-22 22:14:15 +02:00
parent cc4e174880
commit fe73662903
39 changed files with 2432 additions and 1 deletions

View File

@@ -0,0 +1,27 @@
<?php
namespace Tests\Unit;
use App\Enums\InstitutionLinkType;
use PHPUnit\Framework\TestCase;
class InstitutionLinkTypeTest extends TestCase
{
public function test_every_case_has_a_non_empty_label(): void
{
foreach (InstitutionLinkType::cases() as $case) {
$this->assertNotSame('', $case->label());
}
}
public function test_official_case_value_and_label(): void
{
$this->assertSame('official', InstitutionLinkType::Official->value);
$this->assertSame('Official website', InstitutionLinkType::Official->label());
}
public function test_it_is_a_string_backed_enum(): void
{
$this->assertSame(InstitutionLinkType::Social, InstitutionLinkType::from('social'));
}
}