2020-04-12 11:41:01 -04:00
|
|
|
<?php
|
|
|
|
namespace Psalm\Tests\Internal\Provider;
|
|
|
|
|
|
|
|
class ProjectCacheProvider extends \Psalm\Internal\Provider\ProjectCacheProvider
|
|
|
|
{
|
|
|
|
/**
|
|
|
|
* @var int
|
|
|
|
*/
|
|
|
|
private $last_run = 0;
|
|
|
|
|
|
|
|
public function __construct()
|
|
|
|
{
|
|
|
|
}
|
|
|
|
|
2020-11-01 09:01:43 -05:00
|
|
|
public function getLastRun(string $psalm_version): int
|
2020-04-12 11:41:01 -04:00
|
|
|
{
|
|
|
|
return $this->last_run;
|
|
|
|
}
|
|
|
|
|
2020-11-01 09:01:43 -05:00
|
|
|
public function processSuccessfulRun(float $start_time, string $psalm_version): void
|
2020-04-12 11:41:01 -04:00
|
|
|
{
|
|
|
|
$this->last_run = (int) $start_time;
|
|
|
|
}
|
|
|
|
|
2020-09-04 22:26:33 +02:00
|
|
|
public function canDiffFiles(): bool
|
2020-04-12 11:41:01 -04:00
|
|
|
{
|
|
|
|
return $this->last_run > 0;
|
|
|
|
}
|
|
|
|
|
|
|
|
public function hasLockfileChanged() : bool
|
|
|
|
{
|
2020-04-12 12:02:19 -04:00
|
|
|
return false;
|
2020-04-12 11:41:01 -04:00
|
|
|
}
|
|
|
|
|
|
|
|
public function updateComposerLockHash() : void
|
|
|
|
{
|
|
|
|
}
|
|
|
|
}
|