Neos\Flow\Tests\Unit\Session\SessionTest::touchUpdatesLastActivityTimestampOfRemoteSession PHP Method

touchUpdatesLastActivityTimestampOfRemoteSession() public method

    public function touchUpdatesLastActivityTimestampOfRemoteSession()
    {
        $storageIdentifier = '6e988eaa-7010-4ee8-bfb8-96ea4b40ec16';
        $metaDataCache = $this->createCache('Meta');
        $session = new Session('ZPjPj3A0Opd7JeDoe7rzUQYCoDMcxscb', $storageIdentifier, 1110000000);
        $this->inject($session, 'bootstrap', $this->mockBootstrap);
        $this->inject($session, 'objectManager', $this->mockObjectManager);
        $this->inject($session, 'settings', $this->settings);
        $this->inject($session, 'metaDataCache', $metaDataCache);
        $this->inject($session, 'storageCache', $this->createCache('Storage'));
        $session->initializeObject();
        $this->inject($session, 'now', 2220000000);
        $session->touch();
        $sessionInfo = $metaDataCache->get('ZPjPj3A0Opd7JeDoe7rzUQYCoDMcxscb');
        $this->assertEquals(2220000000, $sessionInfo['lastActivityTimestamp']);
        $this->assertEquals($storageIdentifier, $sessionInfo['storageIdentifier']);
    }
SessionTest