1
0
Files
breadcrumb-the-shire/tests/Architecture/AuthHelpLinksPartialContractTest.php

29 lines
976 B
PHP
Raw Normal View History

2026-03-19 19:05:29 +01:00
<?php
namespace MintyPHP\Tests\Architecture;
use PHPUnit\Framework\TestCase;
final class AuthHelpLinksPartialContractTest extends TestCase
{
use ProjectFileAssertionSupport;
public function testAuthHelpLinksPartialSupportsContextFlags(): void
{
$content = $this->readProjectFile('templates/partials/auth-help-links.phtml');
$this->assertStringContainsString('$authHelpContext', $content);
$this->assertStringContainsString("'show_forgot'", $content);
$this->assertStringContainsString("'show_register'", $content);
$this->assertStringContainsString("'show_back_to_login'", $content);
}
public function testRegisterLinkRemainsGuardedByRegistrationFlag(): void
{
$content = $this->readProjectFile('templates/partials/auth-help-links.phtml');
$this->assertStringContainsString('allowRegistration()', $content);
$this->assertStringContainsString("lurl('register')", $content);
}
}