Ejemplo n.º 1
0
 public function testRegistration()
 {
     $schema = \CConfig::getSchema(\UsersRegistration::RegistrationConfirmationConfigName);
     $api = new Registration($this->correctForm);
     $api->exec();
     $this->assertTrue($this->mailer->isSent());
     $lastEmail = \EmailLogModel::getLast();
     $this->assertEquals($lastEmail->to->getValue(), self::SomeCorrectEmail);
     $user = \UserAccount::getByLogin(self::NewLogin);
     $this->assertEquals($user->social_networks->getValue()['facebook'], self::NewUID);
 }
Ejemplo n.º 2
0
 public function testEmailSentOnCriticalLogMessage()
 {
     Record::add('Log2', '', '');
     $this->assertTrue($this->mailer->isSent());
 }