public function testSetExpiration() { $key =
new Key(uniqid(__METHOD__, true
));
/** @var PersistingStoreInterface $store */
$store =
$this->
getStore();
$store->
save($key);
$store->
putOffExpiration($key, 1
);
$this->
assertGreaterThanOrEqual(0,
$key->
getRemainingLifetime());
$this->
assertLessThanOrEqual(1,
$key->
getRemainingLifetime());
} public function testExpiredLockCleaned() { $resource =
uniqid(__METHOD__, true
);
$key1 =
new Key($resource);
$key2 =
new Key($resource);
/** @var PersistingStoreInterface $store */