people_sdk / library
Library People SDK: base components
Requires
- php: ~7 || ~8
- liberty_code/config: ^1.0.
- liberty_code/data: ^1.0.
- liberty_code/di: ^1.0.
- liberty_code/http: ^1.0.
- liberty_code/library: ^1.0.
- liberty_code/model: ^1.0.
- liberty_code/requisition: ^1.0.
Requires (Dev)
- liberty_code/register: ^1.0.
- liberty_code/validation: ^1.0.
- phpunit/phpunit: v8.5.22
This package is auto-updated.
Last update: 2024-10-09 16:09:37 UTC
README
Description
Library contains base components, used in other SDK components.
Requirement
- Script language: PHP: version 7 || 8
Framework library implementation requirement
Library repository: liberty_code/validation: version 1.0
Standard rules implementation (or equivalent):
Validator provided on entities, must contain all standard rules, added on its rule collection.
Validator rules implementation (or equivalent):
Validator provided on entities, must contain all validator rules, added on its rule collection. Each validator rule must use validator, with same implementation as validator provided on entities.
Library repository: liberty_code/http: version 1.0
Request factory implementation:
Default persistor provided on entity repository, must be able to use request factory features, allowing to provide HTTP request instances.
Installation
Several ways are possible:
Composer
Requirement
It requires composer installation. For more information: https://getcomposer.org
Command: Move in project root directory
cd "<project_root_dir_path>"
Command: Installation
php composer.phar require people_sdk/library ["<version>"]
Note
Include vendor
If project uses composer, vendor must be included:
require_once('<project_root_dir_path>/vendor/autoload.php');
Configuration
Installation command allows to add, on composer file "
{ "require": { "people_sdk/library": "<version>" } }
Include
Download
- Download following repository.
- Put it on repository root directory.
Include source
require_once('<repository_root_path>/include/Include.php');
Usage
TODO
Test
Unit test
Unit tests allows to test components features, and to automate their validation.
Requirement
Composer
It requires composer installation. For more information: https://getcomposer.org
Command: Dependencies installation
php composer.phar install
Command: Run unit tests
vendor\bin\phpunit
Note
It uses PHPUnit to handle unit tests. For more information: https://phpunit.readthedocs.io