@manager.command()
@click.argument('email', default=settings.MAIL_DEFAULT_SENDER, required=False)
def send_test_mail(email=None):
 from redash import mail
 from flask_mail import Message
 if (email is None):
  email = settings.MAIL_DEFAULT_SENDER
 mail.send(Message(subject='Test Message from Redash', recipients=[email], body='Test message.'))

@ manager . command ( ) @ click . argument ( 'email' , default = settings . MAIL_DEFAULT_SENDER , required = False ) def send_test_mail ( email = None ) : from redash import mail from flask_mail import Message if ( email is None ) : email = settings . MAIL_DEFAULT_SENDER mail . send ( Message ( subject = 'Test Message from Redash' , recipients = [ email ] , body = 'Test message.' ) )
send test message to email .