Skip to content

Commit 9305722

Browse files
committed
chore: add script to update psalm baseline
Signed-off-by: Daniel Kesselberg <[email protected]>
1 parent c168de2 commit 9305722

File tree

2 files changed

+9
-2
lines changed

2 files changed

+9
-2
lines changed

composer.json

+1
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,7 @@
3131
"lint": "find . -name \\*.php -not -path './vendor/*' -print0 | xargs -0 -n1 php -l",
3232
"psalm": "psalm.phar",
3333
"psalm:fix": "psalm.phar --alter --issues=InvalidReturnType,InvalidNullableReturnType,MismatchingDocblockParamType,MismatchingDocblockReturnType,MissingParamType,InvalidFalsableReturnType",
34+
"psalm:update-baseline": "psalm.phar --threads=1 --update-baseline --set-baseline=tests/psalm-baseline.xml",
3435
"cs:check": "php-cs-fixer fix --dry-run --diff",
3536
"cs:fix": "php-cs-fixer fix",
3637
"test:unit": "vendor/bin/phpunit -c tests/phpunit.xml"

tests/psalm-baseline.xml

+8-2
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@
1010
</file>
1111
<file src="lib/AppInfo/Application.php">
1212
<MissingDependency>
13+
<code>EMF</code>
1314
<code>MSExcel</code>
1415
<code>MSWord</code>
1516
<code>OOXML</code>
@@ -47,7 +48,7 @@
4748
<code><![CDATA[$node->getId()]]></code>
4849
</InvalidScalarArgument>
4950
<RedundantCondition>
50-
<code>$app !== ''</code>
51+
<code><![CDATA[$app !== '']]></code>
5152
</RedundantCondition>
5253
</file>
5354
<file src="lib/Controller/TemplatesController.php">
@@ -66,7 +67,7 @@
6667
<code>null</code>
6768
</NullArgument>
6869
<TypeDoesNotContainType>
69-
<code>$path === ''</code>
70+
<code><![CDATA[$path === '']]></code>
7071
</TypeDoesNotContainType>
7172
<UndefinedInterfaceMethod>
7273
<code>putContent</code>
@@ -83,6 +84,11 @@
8384
<code><![CDATA[$share && method_exists($share, 'getAttributes')]]></code>
8485
</RedundantCondition>
8586
</file>
87+
<file src="lib/Preview/EMF.php">
88+
<MissingDependency>
89+
<code>Office</code>
90+
</MissingDependency>
91+
</file>
8692
<file src="lib/Preview/MSExcel.php">
8793
<MissingDependency>
8894
<code>Office</code>

0 commit comments

Comments
 (0)