public function testLock() { $key = uniqid(); $storage = new Storage($key); $storage->destroy(); }
/** * Destroy shared storage if there is 0 semaphores out there */ public function __destruct() { if (0 == $this->count()) { $this->shm->destroy(); } }