pagantis/module-utils
Composer 安装命令:
composer require pagantis/module-utils
包简介
Pagantis PHP Library. Module utils
README 文档
README
Module Utils will help you when developing integration test of Pagantis. The library will use the Exception object to find some problem. Check each exception type to find the error which causes the problem.
How to use
Install the library by:
-
Downloading it from here
-
Using Composer:
composer require pagantis/module-utils
Finally, be sure to include the autoloader:
require_once '/path/to/your-project/vendor/autoload.php';
Once the library is ready and inside the project the stub objects will available and the moduleUtils will also available.
//Amount mismatch Example try { if ($price1 != $price2) { throw new AmountMismatchException($price1, $price2); } } catch(AmountMismatchException $e) { $jsonResponse = new JsonExceptionResponse(); $jsonResponse->setException($e); $jsonResponse->toJson(); }
Help us to improve
We are happy to accept suggestions or pull requests. If you are willing to help us develop better software please create a pull request here following the PSR-2 code style and we will use reviewable to check the code and if al test pass and no issues are detected by SensioLab Insights you could will be ready to merge.
统计信息
- 总下载量: 10.23k
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 0
- 点击次数: 0
- 依赖项目数: 7
- 推荐数: 0
其他信息
- 授权协议: proprietary
- 更新时间: 2019-03-13