Ignore code paths from code coverage that are only executed in edge cases
This commit is contained in:
parent
d50565cbe3
commit
119dedae41
|
|
@ -133,7 +133,9 @@ final readonly class Exporter
|
|||
if ($this->canBeReflected($value)) {
|
||||
$numberOfProperties = count((new ReflectionObject($value))->getProperties());
|
||||
} else {
|
||||
// @codeCoverageIgnoreStart
|
||||
$numberOfProperties = count($this->toArray($value));
|
||||
// @codeCoverageIgnoreEnd
|
||||
}
|
||||
|
||||
return sprintf(
|
||||
|
|
@ -403,7 +405,9 @@ final readonly class Exporter
|
|||
{
|
||||
/** @psalm-suppress UndefinedClass */
|
||||
if ($object instanceof Message) {
|
||||
// @codeCoverageIgnoreStart
|
||||
return false;
|
||||
// @codeCoverageIgnoreEnd
|
||||
}
|
||||
|
||||
return true;
|
||||
|
|
|
|||
Loading…
Reference in New Issue