'Test collections must have minimum number of apps to be public.'

@mock.patch.object(mkt.feed.constants, 'MIN_APPS_COLLECTION', 3)
def test_collection_min_apps(self):

    app_ids = [app_factory().id, app_factory().id]
    coll = self.feed_collection_factory(app_ids=app_ids)
    FeedItem.objects.create(collection=coll, item_type=feed.FEED_TYPE_COLL, region=1)
    (res, data) = self._get()
    eq_(res.status_code, 404)
    app_ids.append(app_factory().id)
    coll.set_apps(app_ids)
    coll.get_indexer().index_ids([coll.id])
    (res, data) = self._get()
    eq_(res.status_code, 200)
    ok_(data['objects'])
