Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

NTR: add monolog channel #922

Merged
merged 15 commits into from
Jan 15, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions .github/actions/run-e2e/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -138,6 +138,8 @@ runs:

# --------------------------------------------------------------------------------------------------------------------------------------



- name: Install Cypress
if: ${{ inputs.RUN_CYPRESS == 'true' }}
shell: bash
Expand Down
1 change: 1 addition & 0 deletions .php_cs.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

$finder = \PhpCsFixer\Finder::create()->in([
__DIR__ . '/src',
__DIR__ . '/shopware',
__DIR__.'/tests/PHPUnit',
]);

Expand Down
3 changes: 2 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,5 @@ and this project adheres to [Semantic Versioning](http://semver.org/).
### Features
- Return over Shopware Commercial plugins is now transfered to Mollie when the Return status is set to "Done" and can be cancelled with the "Cancelled" status. Please note that the refund cannot be cancelled after two hours.
### Changes
- Minimum Supported Shopware version is now 6.4.5.0
- Minimum Supported Shopware version is now 6.4.5.0
- Add new monolog channel "mollie". You can now add custom handler and assign them to the mollie channel
5 changes: 4 additions & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -42,12 +42,15 @@
},
"autoload": {
"psr-4": {
"Mollie\\Shopware\\": "shopware/",
"Kiener\\MolliePayments\\": "src/",
"Mollie\\Api\\": "vendor_manual/mollie/mollie-api-php/src/"
}
},
"autoload-dev": {
"psr-4": {
"Mollie\\Unit\\": "tests/Unit/",
"Mollie\\Integration\\": "tests/Integration/",
"MolliePayments\\Tests\\": "tests/PHPUnit/",
"MolliePayments\\PHPStan\\": "tests/PHPStan/",
"MolliePayments\\Fixtures\\": "tests/Fixtures/"
Expand All @@ -70,7 +73,7 @@
"shopware/elasticsearch": "*"
},
"require-dev": {
"phpunit/phpunit": "^9.5",
"phpunit/phpunit": "^9",
"phpstan/phpstan": "1.10.0",
"friendsofphp/php-cs-fixer": "^2.18",
"phpcompatibility/php-compatibility": "^9.3",
Expand Down
78 changes: 39 additions & 39 deletions composer.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 6 additions & 2 deletions makefile
Original file line number Diff line number Diff line change
Expand Up @@ -94,10 +94,13 @@ stan: ##2 Starts the PHPStan Analyser
@php vendor/bin/phpstan analyse -c ./.phpstan.neon

phpunit: ##2 Starts all PHPUnit Tests
@XDEBUG_MODE=coverage php vendor/bin/phpunit --configuration=phpunit.xml --coverage-html ./.reports/phpunit/coverage
@XDEBUG_MODE=coverage php vendor/bin/phpunit --testsuite unit --configuration=phpunit.xml --coverage-html ./.reports/phpunit/coverage

phpintegration: ##2 Starts all PHPUnit Tests
@XDEBUG_MODE=coverage cd ../../.. && php vendor/bin/phpunit --testsuite integration --configuration=custom/plugins/MolliePayments/phpunit.xml

infection: ##2 Starts all Infection/Mutation tests
@XDEBUG_MODE=coverage php vendor/bin/infection --configuration=./.infection.json --log-verbosity=all --debug
@XDEBUG_MODE=coverage php vendor/bin/infection --configuration=./.infection.json --log-verbosity=all --debug --test-framework-options="--testsuite=unit --no-coverage"

insights: ##2 Starts the PHPInsights Analyser
@php vendor/bin/phpinsights analyse --no-interaction
Expand Down Expand Up @@ -151,6 +154,7 @@ pr: ##2 Prepares everything for a Pull Request
@make phpmin -B
@make stan -B
@make phpunit -B
@make phpintegration -B
@make jest -B
@make eslint mode=no-dry-run -B
@make stylelint -B
Expand Down
22 changes: 17 additions & 5 deletions phpunit.xml
Original file line number Diff line number Diff line change
@@ -1,23 +1,35 @@
<?xml version="1.0" encoding="UTF-8"?>
<phpunit xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="https://schema.phpunit.de/9.3/phpunit.xsd"
bootstrap="./vendor/autoload.php"
xsi:noNamespaceSchemaLocation="https://schema.phpunit.de/9.6/phpunit.xsd"
bootstrap="./tests/bootstrap/index.php"
cacheResult="false"
colors="true"
executionOrder="random"
resolveDependencies="true"
>
<php>
<ini name="error_reporting" value="-1"/>
<server name="KERNEL_CLASS" value="Shopware\Core\Kernel"/>
<env name="APP_ENV" value="test"/>
<env name="APP_DEBUG" value="1"/>
<env name="SYMFONY_DEPRECATIONS_HELPER" value="weak"/>
</php>

<testsuites>
<testsuite name="MolliePayments Tests">
<testsuite name="unit">
<directory>./tests/PHPUnit</directory>
<directory>./tests/Unit</directory>
</testsuite>
<testsuite name="integration">
<directory>./tests/Integration</directory>
</testsuite>
</testsuites>

<coverage>
<include>
<directory>./src</directory>
<directory suffix=".php">./src</directory>
<directory suffix=".php">./shopware</directory>
</include>
</coverage>


</phpunit>
Loading
Loading