public function testUnSubscribeCollectionUnAuth403() { $collections = SampleCollectionsFixture::getCommunityCollections(); /** @var Collection $collection */ $collection = array_shift($collections); $this->requestUnSubscribeCollection($collection->getId())->execute()->expectStatusCode(403); }
public function up(Application $app, EntityManager $em) { $subscribeService = $app->getContainer()->get(SubscribeService::class); $profile = DemoAccountFixture::getAccount()->getCurrentProfile(); $theme = SampleThemesFixture::getTheme(1); self::$subscribes['theme'][0] = $subscribeService->subscribeTheme($profile, $theme); $subscribeProfile = DemoProfileFixture::getProfile(); self::$subscribes['profile'][0] = $subscribeService->subscribeProfile($profile, $subscribeProfile); $collections = SampleCollectionsFixture::getCommunityCollections(); $collection = array_shift($collections); self::$subscribes['collection'][0] = $subscribeService->subscribeCollection($profile, $collection); $community = SampleCommunitiesFixture::getCommunity(1); self::$subscribes['community'][0] = $subscribeService->subscribeCommunity($profile, $community); }