Skip to content

Commit

Permalink
test: see errors
Browse files Browse the repository at this point in the history
  • Loading branch information
mr-feek committed May 3, 2020
1 parent c2c4ea6 commit 6ce6739
Showing 1 changed file with 27 additions and 0 deletions.
27 changes: 27 additions & 0 deletions tests/acceptance/ExceptionHandler.feature
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
Feature: ExceptionHandler
If an exception is thrown while psalm analyzes the codebase, the status code returned will not be 0

Background:
Given I have the following config
"""
<?xml version="1.0"?>
<psalm totallyTyped="true">
<projectFiles>
<directory name="."/>
<ignoreFiles> <directory name="../../vendor"/> </ignoreFiles>
</projectFiles>
<plugins>
<pluginClass class="Psalm\LaravelPlugin\Plugin"/>
</plugins>
</psalm>
"""

Scenario:
Given I have the following code
"""
<?php
function get( // cause a parser error
"""
When I run Psalm
Then I see these errors
| ParseError | Syntax error, unexpected EOF, expecting T_VARIABLE on line 2 |

0 comments on commit 6ce6739

Please sign in to comment.