Skip to content

Commit de7adad

Browse files
committed
Added information to the Developers Guide on PHPStan
1 parent f96a848 commit de7adad

File tree

2 files changed

+16
-0
lines changed

2 files changed

+16
-0
lines changed

docs-md/DeveloperGuide.md

+10
Original file line numberDiff line numberDiff line change
@@ -255,6 +255,16 @@ if ($required) {
255255
} // @codeCoverageIgnore
256256
```
257257

258+
### Static Analysis
259+
260+
PHPStan can be used to run a static analysis of the PHPCap code. Use the following command in the top-level directory:
261+
262+
./vendor/bin/phpstan
263+
264+
The configuration for PHPStan is in the following file in the top-level directory:
265+
266+
phpstan.neon
267+
258268
### Local Tests
259269
The directory __tests/local/__ has been set up so that all files in it, except for the README file, will be ignored by Git.
260270
This directory is intended as a place for developers to places tests for changes they are working on.

docs/DeveloperGuide.html

+6
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,7 @@
3030
<li class="active"><a href="#Development">Development</a></li>
3131
<ul class="intraPage">
3232
<li class="active"><a href="#Automated Tests">Automated Tests</a></li>
33+
<li class="active"><a href="#Static Analysis">Static Analysis</a></li>
3334
<li class="active"><a href="#Local Tests">Local Tests</a></li>
3435
<li class="active"><a href="#Coding Standard Compliance">Coding Standard Compliance</a></li>
3536
<li class="active"><a href="#Documentation">Documentation</a></li>
@@ -286,6 +287,11 @@ <h5>Code Coverage</h5>
286287
$message = 'No field was specified.';
287288
$this-&gt;errorHandler-&gt;throwException($message, ErrorHandlerInterface::INVALID_ARGUMENT);
288289
} // @codeCoverageIgnore</code></pre></div>
290+
<h3 id="Static Analysis">Static Analysis</h3>
291+
<p>PHPStan can be used to run a static analysis of the PHPCap code. Use the following command in the top-level directory:</p>
292+
<div class="description"><pre><code>./vendor/bin/phpstan</code></pre></div>
293+
<p>The configuration for PHPStan is in the following file in the top-level directory:</p>
294+
<div class="description"><pre><code>phpstan.neon</code></pre></div>
289295
<h3 id="Local Tests">Local Tests</h3>
290296
<p>The directory <strong>tests/local/</strong> has been set up so that all files in it, except for the README file, will be ignored by Git.
291297
This directory is intended as a place for developers to places tests for changes they are working on.</p>

0 commit comments

Comments
 (0)