Skip to content

Commit

Permalink
fix: Pimcore library init files (#132)
Browse files Browse the repository at this point in the history
  • Loading branch information
dkarlovi authored Jun 2, 2023
1 parent b3e6c9b commit bee8e03
Show file tree
Hide file tree
Showing 3 changed files with 77 additions and 0 deletions.
15 changes: 15 additions & 0 deletions resources/Pimcore/library/phpstan.neon.dist
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
includes:
- /tools/.composer/vendor-bin/phpstan/vendor/phpstan/phpstan-deprecation-rules/rules.neon
- /tools/.composer/vendor-bin/phpstan/vendor/phpstan/phpstan-strict-rules/rules.neon
- /tools/.composer/vendor-bin/phpstan/vendor/phpstan/phpstan-phpunit/extension.neon
- /tools/.composer/vendor-bin/phpstan/vendor/phpstan/phpstan-symfony/extension.neon
parameters:
tmpDir: %currentWorkingDirectory%/var/phpqa/phpstan
level: max
paths:
- ./
excludePaths:
- var/
- vendor/
bootstrapFiles:
- vendor/pimcore/pimcore/stubs/dynamic-constants.php
30 changes: 30 additions & 0 deletions resources/Pimcore/library/phpunit.xml.dist
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
<?xml version="1.0" encoding="UTF-8"?>
<phpunit xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="vendor/phpunit/phpunit/phpunit.xsd"
beStrictAboutChangesToGlobalState="true"
beStrictAboutCoversAnnotation="true"
beStrictAboutOutputDuringTests="true"
beStrictAboutResourceUsageDuringSmallTests="true"
beStrictAboutTodoAnnotatedTests="true"
bootstrap="./vendor/autoload.php"
cacheResultFile="var/phpqa/phpunit.result.cache"
colors="true"
convertDeprecationsToExceptions="true"
enforceTimeLimit="true"
executionOrder="random"
failOnEmptyTestSuite="true"
failOnRisky="true"
failOnWarning="true"
forceCoversAnnotation="true"
verbose="true">
<coverage processUncoveredFiles="true">
<include>
<directory suffix=".php">./src</directory>
</include>
</coverage>
<testsuites>
<testsuite name="SigwinPimcoreSpecificBundle">
<directory>./tests/unit</directory>
</testsuite>
</testsuites>
</phpunit>
32 changes: 32 additions & 0 deletions resources/Pimcore/library/psalm.xml.dist
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
<?xml version="1.0"?>
<psalm xmlns="https://getpsalm.org/schema/config"
cacheDirectory="var/phpqa/psalm"
checkForThrowsInGlobalScope="true"
ensureArrayIntOffsetsExist="true"
ensureArrayStringOffsetsExist="true"
errorLevel="1"
findUnusedBaselineEntry="true"
findUnusedCode="false"
findUnusedPsalmSuppress="true"
findUnusedVariablesAndParams="true"
limitMethodComplexity="true"
restrictReturnTypes="true"
strictBinaryOperands="true">
<projectFiles>
<directory name="./"/>
<ignoreFiles allowMissingFiles="true">
<file name=".php-cs-fixer.dist.php"/>
<directory name="var/"/>
<directory name="vendor/"/>
</ignoreFiles>
</projectFiles>

<stubs>
<file name="vendor/pimcore/pimcore/stubs/dynamic-constants.php"/>
</stubs>

<plugins>
<pluginClass class="Psalm\PhpUnitPlugin\Plugin"/>
<pluginClass class="Psalm\SymfonyPsalmPlugin\Plugin"/>
</plugins>
</psalm>

0 comments on commit bee8e03

Please sign in to comment.