public function testContentDraftOnFlushWithoutBBUserToken()
 {
     $token = self::$app->getSecurityContext()->getToken();
     self::$app->getSecurityContext()->setToken(null);
     self::$contentManager->setBBUserToken(null);
     $text = new Text();
     $this->assertNull($text->getDraft());
     self::$em->persist($text);
     self::$em->flush($text);
     $this->assertNull($text->getDraft());
     self::$app->getSecurityContext()->setToken($token);
     self::$contentManager->setBBUserToken($token);
 }
 public static function tearDownAfterClass()
 {
     self::$contentManager->setBBUserToken(null);
     self::$app->getSecurityContext()->setToken(null);
 }