best-it / shopware-bugsnag
shopware中bugsnag.com的实现
1.3.0
2021-09-24 11:01 UTC
Requires
- php: ^7.0
- bugsnag/bugsnag: ^3.0
- shopware/shopware: ^5.4
Requires (Dev)
- best-it/php_codesniffer: ^1.2
- phpmd/phpmd: ^2.6
- phpunit/phpunit: ^6.0
This package is auto-updated.
Last update: 2024-09-24 17:42:37 UTC
README
Shopware-Bugsnag 插件
这是一个非常简单的bugsnag.com实现,没有其他功能 :)
安装
您可以使用create_package.sh创建一个Plugin.zip文件,然后通过shopware后端安装,或者使用composer要求插件
$ composer require best-it/shopware-bugsnag
配置
API密钥
在激活插件之前,请确保在插件配置中输入您的bugsnag API密钥。您可以在后端插件配置中或通过BUGSNAG_API_KEY环境变量完成此操作。
如果您的API密钥为空且未设置环境,您的商店将抛出异常。
测试
PHPUnit测试已启用,应在tests文件夹中编写。要运行它们,请使用
$ ./vendor/bin/phpunit
要检查插件是否在您的环境中工作,请在您的代码中实现此操作,并在bugsnag门户中进行检查。
$this->get('best_it_bugsnag.client')->notifyException(new \Exception('测试错误'));