Skip to content
Snippets Groups Projects
Commit 9c068642 authored by Sebastien ANDRE's avatar Sebastien ANDRE
Browse files

Merge branch 'hotline#173813_contenu_du_mail_de_rappel_des_activites' into 'master'

hotline : #173813 : add horaires in confirmation mail

See merge request !4806
parents 001addab 85885ce1
1 merge request!4806hotline : #173813 : add horaires in confirmation mail
Pipeline #24982 failed with stage
in 24 minutes and 59 seconds
- correctif #173813 : Abonne : Le contenu du mail de confirmation peut afficher les horaires de l'activité.
\ No newline at end of file
......@@ -109,4 +109,9 @@ class Class_Activity_RegistrationMail_SessionActivity {
public function getContentOrActivityDescription() {
return $this->_training_session->getContentOrActivityDescription();
}
public function getHoraires() : string {
return $this->_training_session->getHoraires();
}
}
......@@ -994,7 +994,44 @@ class AbonneControllerActivitiesAmadouInscritSessionFebruaryJavaOpenTest
class AbonneControllerActivitiesAmadouWithoutMailInscritSessionFebruaryJavaOpenTest extends AbstractAbonneControllerActivitiesTestCase {
/* hotline : https://forge.afi-sa.net/issues/173813 */
class AbonneControllerActivitiesWithHorairesInMailRegistrationTest
extends AbstractAbonneControllerActivitiesTestCase {
protected $_mails;
public function setUp() {
parent::setUp();
Class_SessionActivity::find(31)->setHoraires('10h00');
$this->_session_java_fevrier
->setIntervenants($this->_session_python_juillet
->getIntervenants())->save();
Class_AdminVar::set('ACTIVITY_REGISTRATION_BODY',
'inscription pour : {session.horaires}');
$this->dispatch('/opac/abonne/inscrire-session/id/31');
Class_SessionActivity::clearCache();
Class_Article::clearCache();
$this->_mails = $this->_mail_transport->getSentMails();
}
/** @test */
public function firstMailBodyShouldContainsSessionHoraires() {
$this->assertEquals('inscription pour : 10h00', $this->_mails[0]->getBodyHtml(true));
}
}
class AbonneControllerActivitiesAmadouWithoutMailInscritSessionFebruaryJavaOpenTest
extends AbstractAbonneControllerActivitiesTestCase {
protected
$_mails;
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment