1
0
mirror of https://github.com/phpbb/phpbb.git synced 2025-07-31 14:00:31 +02:00

[ticket/13207] Add default subscription options for newly registered users

PHPBB3-13207
This commit is contained in:
Marc Alexander
2014-10-25 14:50:01 -07:00
parent f22cd2d734
commit 18f24a2270
3 changed files with 38 additions and 4 deletions

View File

@@ -45,12 +45,24 @@ class phpbb_functional_registration_test extends phpbb_functional_test_case
$form = $crawler->selectButton('Submit')->form(array(
'username' => 'user-reg-test',
'email' => 'user-reg-test@phpbb.com',
'new_password' => 'testtest',
'password_confirm' => 'testtest',
'new_password' => 'user-reg-testuser-reg-test',
'password_confirm' => 'user-reg-testuser-reg-test',
));
$form['tz']->select('Europe/Berlin');
$crawler = self::submit($form);
$this->assertContainsLang('ACCOUNT_ADDED', $crawler->filter('#message')->text());
}
/**
* @depends test_register_new_account
*/
public function test_default_subscription_options()
{
$this->login('user-reg-test');
$crawler = self::request('GET', 'ucp.php?i=ucp_notifications&mode=notification_options&sid=' . $this->sid);
$form_values = $crawler->selectButton('Submit')->form()->getValues();
$this->assertEquals(1, $form_values['notification.type.post_notification.method.email']);
$this->assertEquals(1, $form_values['notification.type.topic_notification.method.email']);
}
}