. */ declare(strict_types=1); namespace Fisharebest\Webtrees\Elements; use PHPUnit\Framework\Attributes\CoversClass; #[CoversClass(AbstractElement::class)] #[CoversClass(LanguageId::class)] class LanguageIdTest extends AbstractElementTestCase { /** * Standard tests for all elements. */ public static function setupBeforeClass(): void { parent::setUpBeforeClass(); static::$element = new LanguageId('label'); } public function testCanonical(): void { self::assertSame('ENGLISH', self::$element->canonical("\t English\t ")); self::assertSame('KLINGON', self::$element->canonical('kLiNgOn')); self::assertSame('ANGLO-SAXON', self::$element->canonical('anglo-saxon')); self::assertSame('CATALAN_SPN', self::$element->canonical('CATALAN_SPN')); } }