paulorlima9 / laravel-openpix
Laravel OpenPix SDK
v1.0.0
2024-03-25 17:46 UTC
Requires
- php: >=8.0
- ext-json: *
- guzzlehttp/guzzle: ^7.8
- illuminate/support: ^11.0
- laravel/framework: ^11.0
Requires (Dev)
- ext-curl: *
- phpunit/phpunit: ^8.0 || ^9.0 || ^10.0
README
这是一个测试类,用于验证 LaravelOpenPixContract
接口的实现是否正确在 LaravelOpenPixService
类中,以及访问特定合同的方法是否返回相应接口的正确实例。
安装
确保您的开发环境中已安装 PHPUnit 以运行这些测试。
使用
- 在您的开发环境中克隆此仓库。
- 导航到
LaravelOpenPixServiceTest.php
文件所在的目录。 - 执行命令
phpunit LaravelOpenPixServiceTest.php
以运行测试。
测试
test_openpix_contract
验证 LaravelOpenPixService
是否正确实现了 LaravelOpenPixContract
接口。
test_openpix_charge_function
验证 charges()
方法是否返回有效的 ChargeContract
实例。
test_openpix_refund_function
验证 refunds()
方法是否返回有效的 RefundsContract
实例。
test_openpix_payments_function
验证 payments()
方法是否返回有效的 PaymentsContract
实例。
test_openpix_transactions_function
验证 transactions()
方法是否返回有效的 TransactionContract
实例。
test_openpix_webhooks_function
验证 webhooks()
方法是否返回有效的 WebhooksContract
实例。
test_openpix_customers_function
验证 customers()
方法是否返回有效的 CustomerContract
实例。
注意
在运行测试之前,请确保所有必要的依赖都已正确配置。