Horde_ActiveSync_StateTest_Base::_testMissingCollections PHP Method

_testMissingCollections() protected method

Tests initiating a partial sync where 1 collection was passed from client and 2 others had to be loaded from cache.
protected _testMissingCollections ( )
    protected function _testMissingCollections()
    {
        // Need to prime the cache with a synckey for contacts so we have
        // another one to load for the test.
        $col = array('id' => '@Contacts@', 'newsynckey' => '{517541cc-b188-478d-aaaa-fa49c0a8015f}35');
        $cache = new Horde_ActiveSync_SyncCache(self::$state, 'dev123', 'mike', self::$logger->getLogger());
        $cache->updateCollection($col, array('newsynckey' => true));
        $cache->save();
        $collections = $this->getCollectionHandler();
        $col = array('id' => '519422f1-4c5c-4547-946a-1701c0a8015f', 'windowsize' => 5, 'truncation' => 0, 'mimesupport' => 0, 'mimetruncation' => 8, 'conflict' => 1, 'bodyprefs' => array('wanted' => 2, 2 => array('type' => 2, 'truncationsize' => 300000)), 'synckey' => '{517541cc-b188-478d-9e1a-fa49c0a8015f}3', 'deletesasmoves' => 1, 'filtertype' => 5);
        $collections->addCollection($col);
        $collections->initPartialSync();
        $this->assertEquals(2, $collections->collectionCount());
    }