1
0
mirror of https://github.com/danog/psalm.git synced 2025-01-22 05:41:20 +01:00
This commit is contained in:
kkmuffme 2023-11-15 21:03:14 +01:00
parent be6028d7d4
commit 3299689d99

View File

@ -14,7 +14,6 @@ use function version_compare;
use const PHP_OS;
use const PHP_VERSION;
use const PHP_VERSION_ID;
trait ValidCodeAnalysisTestTrait
{
@ -77,20 +76,6 @@ trait ValidCodeAnalysisTestTrait
$codebase->enterServerMode();
$codebase->config->visitPreloadedStubFiles($codebase);
// avoid MethodSignatureMismatch for __unserialize/() when extending DateTime
if (PHP_VERSION_ID >= 8_02_00) {
$this->addStubFile(
'stubOne.phpstub',
'<?php
namespace {
interface DateTimeInterface {
public function __unserialize(mixed[] $data) {}
}
}
',
);
}
$file_path = self::$src_dir_path . 'somefile.php';
$this->addFile($file_path, $code);