namespace Symfony\Component\Validator\Tests\Constraints;
use PHPUnit\Framework\TestCase;
use Symfony\Component\Validator\Constraints\PasswordStrength;
use Symfony\Component\Validator\Exception\ConstraintDefinitionException;
class PasswordStrengthTest extends TestCase
{ public function testConstructor() { $constraint =
new PasswordStrength();
$this->
assertSame(2,
$constraint->minScore
);
} public function testConstructorWithParameters() { $constraint =
new PasswordStrength(minScore: PasswordStrength::STRENGTH_STRONG, message: 'This password should be strong.'
);
$this->
assertSame(PasswordStrength::STRENGTH_STRONG,
$constraint->minScore
);
$this->
assertSame('This password should be strong.',
$constraint->message
);
}