nitor-infotech-oss / parity-substrate-interface
使用此包,您可以使用功能与运行中的 substrate 节点进行交互。
dev-main
2022-01-17 14:04 UTC
Requires
- php: ^7.2.24
- curl/curl: ^2.3
- deemru/blake2b: ^1.0
- furqansiddiqui/bip39-mnemonic-php: ^0.1.4
- stephenhill/base58: ^1.1
Requires (Dev)
- friendsofphp/php-cs-fixer: ^2.17
- phpunit/phpunit: ^7.0.2
This package is not auto-updated.
Last update: 2024-10-01 21:13:12 UTC
README
我们实现了可以帮助使用函数通过表面接口进行通信的包。
预算在这里
克隆包
git clone https://github.com/nitor-infotech-oss/parity-substrate-interface.git
安装
您可以通过 composer 安装此包
composer require nitorInfoTechOss/substrate-interface-package
创建测试环境步骤
-
创建测试文件夹并创建一个用于测试代码的 PHP 文件
-
运行命令 "touch composer.json"
-
尝试运行以下代码。
用法(就像)
$testClass = new SubstrateInterface("http_url"); echo $testClass->rpc->system->name();
测试
vendor/phpunit/phpunit/phpunit
运行测试用例
I] 克隆项目 git clone https://github.com/neha0921/substrate-interface-package.git
II] 更新 composer composer Update
III] 检查测试用例,运行以下命令
vendor/bin/phpunit
例如:
-
vendor/bin/phpunit --filter testSystemName
-
vendor/bin/phpunit --filter testRpcMethods
变更日志
请参阅 CHANGELOG 了解最近更改的更多信息。
贡献
请参阅 CONTRIBUTING 了解详细信息。
许可
MIT 许可证(MIT)。请参阅 许可文件 了解更多信息。