def test_footer(self):
     footer = MailFooter.monitored('*****@*****.**', 'http://test1.com',
                                   'http://test2.com')
     assert '[email protected] is subscribed to http://test1.com' in footer
     assert 'admin can change settings at http://test2.com' in footer
     footer = MailFooter.standard(M.Notification())
     assert 'Sent from sourceforge.net because you indicated interest in' in footer
示例#2
0
 def test_footer(self):
     footer = MailFooter.monitored('*****@*****.**', 'http://test1.com',
                                   'http://test2.com')
     assert '[email protected] is subscribed to http://test1.com' in footer
     assert 'admin can change settings at http://test2.com' in footer
     footer = MailFooter.standard(M.Notification())
     self.assertIn('Sent from localhost because you indicated interest',
                   footer)
 def test_footer(self):
     footer = MailFooter.monitored(
             '*****@*****.**',
             'http://test1.com',
             'http://test2.com')
     assert '[email protected] is subscribed to http://test1.com' in footer
     assert 'admin can change settings at http://test2.com' in footer
     footer = MailFooter.standard(M.Notification())
     assert 'Sent from sourceforge.net because you indicated interest in' in footer
示例#4
0
 def test_footer(self):
     footer = MailFooter.monitored(
         '*****@*****.**',
         'http://test1.com',
         'http://test2.com')
     assert '[email protected] is subscribed to http://test1.com' in footer
     assert 'admin can change settings at http://test2.com' in footer
     footer = MailFooter.standard(M.Notification())
     self.assertIn('Sent from localhost because you indicated interest',
                   footer)
示例#5
0
文件: ticket.py 项目: joequant/allura
 def get_mail_footer(self, notification, toaddr):
     if toaddr and toaddr == self.monitoring_email:
         return MailFooter.monitored(
             toaddr,
             h.absurl(self.app.url),
             h.absurl("{0}admin/{1}/options".format(self.project.url(), self.app.config.options.mount_point)),
         )
     return MailFooter.standard(
         notification,
         self.app.config.options.get("AllowEmailPosting", True),
         discussion_disabled=self.discussion_disabled,
     )
示例#6
0
 def get_mail_footer(self, notification, toaddr):
     if toaddr and toaddr == self.monitoring_email:
         return MailFooter.monitored(
             toaddr, h.absurl(self.app.url),
             h.absurl('{0}admin/{1}/options'.format(
                 self.project.url(), self.app.config.options.mount_point)))
     return super(Ticket, self).get_mail_footer(notification, toaddr)
示例#7
0
文件: forum.py 项目: joequant/allura
 def get_mail_footer(self, notification, toaddr):
     if toaddr and toaddr == self.monitoring_email:
         return MailFooter.monitored(
             toaddr,
             h.absurl(self.url()),
             h.absurl("{0}admin/{1}/forums".format(self.project.url(), self.app.config.options.mount_point)),
         )
     return super(Forum, self).get_mail_footer(notification, toaddr)