Skip to content

Fix Psalm assertions on assertInstanceOf()#4509

Merged
sebastianbergmann merged 1 commit intosebastianbergmann:8.5from
BenMorel:psalm
Nov 3, 2020
Merged

Fix Psalm assertions on assertInstanceOf()#4509
sebastianbergmann merged 1 commit intosebastianbergmann:8.5from
BenMorel:psalm

Conversation

@BenMorel
Copy link
Copy Markdown
Contributor

@BenMorel BenMorel commented Nov 3, 2020

Hi, according to vimeo/psalm#4473 (comment), the psalm assertions should be @psalm-assert =T instead of @psalm-assert T.

The linked issue describes the problem in more detail.

@codecov
Copy link
Copy Markdown

codecov bot commented Nov 3, 2020

Codecov Report

Merging #4509 into 8.5 will not change coverage.
The diff coverage is n/a.

Impacted file tree graph

@@            Coverage Diff            @@
##                8.5    #4509   +/-   ##
=========================================
  Coverage     84.31%   84.31%           
  Complexity     3938     3938           
=========================================
  Files           154      154           
  Lines          9789     9789           
=========================================
  Hits           8254     8254           
  Misses         1535     1535           
Impacted Files Coverage Δ Complexity Δ
src/Framework/Assert.php 89.75% <ø> (ø) 263.00 <0.00> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 45e0286...a3a03c3. Read the comment docs.

@sebastianbergmann sebastianbergmann merged commit 9c60d7d into sebastianbergmann:8.5 Nov 3, 2020
@BenMorel
Copy link
Copy Markdown
Contributor Author

BenMorel commented Nov 3, 2020

Well that was fast. Thanks!

@muglug
Copy link
Copy Markdown
Contributor

muglug commented Nov 4, 2020

FYI equality assertions are documented here: https://psalm.dev/docs/annotating_code/assertion_syntax/#equality-assertions

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants