File: |
src/PasswordHelper/Password.php |
Role: |
Class source |
Content type: |
text/plain |
Description: |
Class source |
Class: |
PHP Password Validation Helper
Generate and check a password according to rules |
Author: |
By John Conde |
Last change: |
refactor: minor code cleanup
refactor: minor code cleanup
refactor: update codebase for PHP 8.0 compatibility
- Updated test cases in PolicyTest, ValidatorTest, and GeneratorTest to match the new class interfaces and expectations.
- Added getter methods for minLength and maxLength in the Generator class.
- Updated assertions in GeneratorTest to use PHPUnit 8.5 compatible methods.
- Adjusted test expectations in ValidatorTest to align with the current validation logic.
This refactoring ensures that the codebase is fully compatible with PHP 8.0 while maintaining the intended functionality and test coverage.
Improve docblocks, restore Validator compatibility, and fix Generator return types
- Enhanced docblock comments for all classes in src/PasswordHelper to be more descriptive and PSR-12 compliant.
- Fixed Generator::getRandomCharacter() to always return a string, preventing type errors.
- Reintroduced protected meetsMinimum* methods in Validator to support legacy and test code.
Added PHP Documentor support
Added __debugInfo() to PHP 7+ for debugging purposes
|
Date: |
7 days ago |
Size: |
4,145 bytes |
|
|
|