Skip to content
This repository has been archived by the owner on Apr 25, 2023. It is now read-only.

Commit

Permalink
Ignore coverage for global ignored annotations for time being
Browse files Browse the repository at this point in the history
Testing them seems to require either an undue usage of reflection, or specific timing, or both.
  • Loading branch information
sanmai committed Mar 18, 2019
1 parent dcf9449 commit 3fd5dab
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/Serialization/Serializer.php
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,7 @@ public function __construct()
// Can be disabled in certain environments (customized PHP build?)
$this->ctypeEnabled = function_exists('\ctype_upper');

// @codeCoverageIgnoreStart
if (self::$addGlobalIgnoredAnnotations) {
// Ignore Phan/Psalm issue-suppressing annotations
AnnotationReader::addGlobalIgnoredName('phan');
Expand All @@ -101,6 +102,7 @@ public function __construct()
// But do that just once
self::$addGlobalIgnoredAnnotations = false;
}
// @codeCoverageIgnoreEnd

if (self::$configureAnnotationRegistry) {
self::configureAnnotationRegistry();
Expand Down

0 comments on commit 3fd5dab

Please sign in to comment.