diff --git a/src/Form/SMTPConfigForm.php b/src/Form/SMTPConfigForm.php
index e0100a2..1938171 100644
--- a/src/Form/SMTPConfigForm.php
+++ b/src/Form/SMTPConfigForm.php
@@ -9,6 +9,7 @@
 
 use Drupal\Core\Form\ConfigFormBase;
 use Drupal\Core\Form\FormStateInterface;
+use Drupal\smtp\Plugin\Mail\SMTPMailSystem;
 
 /**
  * Implements the SMTP admin settings form.
@@ -122,34 +123,22 @@ public function buildForm(array $form, FormStateInterface $form_state) {
       '#default_value' => $config->get('smtp_from'),
       '#description' => t('The e-mail address that all e-mails will be from.'),
     );
+    // @todo - This hangs over from Drupal 7, but is it necessary as site name is required?
+    $site = \Drupal::config('system.site')->get('name');
     $form['email_options']['smtp_fromname'] = array(
       '#type' => 'textfield',
       '#title' => t('E-mail from name'),
       '#default_value' => $config->get('smtp_fromname'),
-      '#description' => t('The name that all e-mails will be from. If left blank will use the site name of:') . ' ' . $config->get('site_name', 'Drupal powered site'),
+      '#description' => t('The name that all e-mails will be from. If left blank will use a default of: !name',
+          ['!name' => $site ? $site : SMTPMailSystem::SMTP_DEFAULT_NAME]),
     );
     $form['email_options']['smtp_allowhtml'] = array(
       '#type' => 'checkbox',
-      '#title' => t('Allow to send e-mails formated as Html'),
+      '#title' => t('Allow to send e-mails formated as HTML'),
       '#default_value' => $config->get('smtp_allowhtml'),
-      '#description' => t('Checking this box will allow Html formated e-mails to be sent with the SMTP protocol.'),
+      '#description' => t('Checking this box will allow HTML formatted e-mails to be sent with the SMTP protocol.'),
     );
 
-    // If an address was given, send a test e-mail message.
-    $test_address = $config->get('smtp_test_address');
-    if ($test_address != '') {
-      $options = array(
-        '@email' => $test_address,
-        '!check' => '/admin/reports/dblog',
-      );
-      // Clear the variable so only one message is sent.
-      $config->clear('smtp_test_address');
-      global $language;
-      $params['subject'] = t('Drupal SMTP test e-mail');
-      $params['body'] = array(t('If you receive this message it means your site is capable of using SMTP to send e-mail.'));
-      //drupal_mail('smtp', 'smtp-test', $test_address, $language, $params);
-      drupal_set_message(t('A test e-mail has been sent to @email. You may want to !check for any error messages.', $options));
-    }
     $form['email_test'] = array(
       '#type' => 'fieldset',
       '#title' => t('Send test e-mail'),
@@ -168,9 +157,6 @@ public function buildForm(array $form, FormStateInterface $form_state) {
       '#description' => t('Checking this box will print SMTP messages from the server for every e-mail that is sent.'),
     );
 
-    // Saving SMTP config vars.
-    $config->save();
-
     return parent::buildForm($form, $form_state);
   }
 
@@ -178,28 +164,32 @@ public function buildForm(array $form, FormStateInterface $form_state) {
    * {@inheritdoc}
    */
   public function validateForm(array &$form, FormStateInterface $form_state) {
-	$values = $form_state->getValues();
+	  $values = $form_state->getValues();
 
     if ($values['smtp_on'] == 1 && $values['smtp_host'] == '') {
-      \Drupal::formBuilder()->setErrorByName('smtp_host', $form_state, t('You must enter an SMTP server address.'));
+      $form_state->setErrorByName('smtp_host', $this->t('You must enter an SMTP server address.'));
     }
 
     if ($values['smtp_on'] == 1 && $values['smtp_port'] == '') {
-      \Drupal::formBuilder()->setErrorByName('smtp_port', $form_state, t('You must enter an SMTP port number.'));
+      $form_state->setErrorByName('smtp_port', $this->t('You must enter an SMTP port number.'));
     }
 
     if ($values['smtp_from'] && !valid_email_address($values['smtp_from'])) {
-      \Drupal::formBuilder()->setErrorByName('smtp_from', $form_state, t('The provided from e-mail address is not valid.'));
+      $form_state->setErrorByName('smtp_from', $this->t('The provided from e-mail address is not valid.'));
+    }
+
+    if ($values['smtp_test_address'] && !valid_email_address($values['smtp_test_address'])) {
+      $form_state->setErrorByName('smtp_test_address', $this->t('The provided test e-mail address is not valid.'));
     }
 
     // If username is set empty, we must set both username/password empty as well.
     if (empty($values['smtp_username'])) {
       $values['smtp_password'] = '';
     }
-    // A little hack. When form is presentend, the password is not shown (Drupal way of doing).
+    // A little hack. When form is presented, the password is not shown (Drupal way of doing).
     // So, if user submits the form without changing the password, we must prevent it from being reset.
     elseif (empty($values['smtp_password'])) {
-      unset($values['smtp_password']);
+      $form_state->unsetValue('smtp_password');
     }
   }
 
@@ -207,7 +197,7 @@ public function validateForm(array &$form, FormStateInterface $form_state) {
    * {@inheritdoc}
    */
   public function submitForm(array &$form, FormStateInterface $form_state) {
-	$values = $form_state->getValues();
+	  $values = $form_state->getValues();
     $config = $this->configFactory->getEditable('smtp.settings');
 
     if ($config->get('smtp_on') != $values['smtp_on']) {
@@ -249,10 +239,18 @@ public function submitForm(array &$form, FormStateInterface $form_state) {
       ->set('smtp_from', $values['smtp_from'])
       ->set('smtp_fromname', $values['smtp_fromname'])
       ->set('smtp_allowhtml', $values['smtp_allowhtml'])
-      ->set('smtp_test_address', $values['smtp_test_address'])
       ->set('smtp_debugging', $values['smtp_debugging'])
       ->save();
 
+    // If an address was given, send a test e-mail message.
+    if ($test_address = $values['smtp_test_address']) {
+      $params['subject'] = t('Drupal SMTP test e-mail');
+      $params['body'] = array(t('If you receive this message it means your site is capable of using SMTP to send e-mail.'));
+      $account = \Drupal::currentUser();
+      \Drupal::service('plugin.manager.mail')->mail('smtp', 'smtp-test', $test_address, $account->getPreferredLangcode(), $params);
+      drupal_set_message(t('A test e-mail has been sent to @email. You may want to check the log for any error messages.', ['@email' => $test_address]));
+    }
+
     parent::submitForm($form, $form_state);
   }
 
diff --git a/src/Plugin/Mail/SMTPMailSystem.php b/src/Plugin/Mail/SMTPMailSystem.php
index d171e25..cb415ed 100644
--- a/src/Plugin/Mail/SMTPMailSystem.php
+++ b/src/Plugin/Mail/SMTPMailSystem.php
@@ -24,6 +24,8 @@ class SMTPMailSystem implements MailInterface {
   protected $AllowHtml;
   protected $smtpConfig;
 
+  const SMTP_DEFAULT_NAME = 'Drupal';
+
   /**
    * Constructs a SMPTMailSystem object.
    */
@@ -84,7 +86,8 @@ public function mail(array $message) {
     $from_name = $this->smtpConfig->get('smtp_fromname');
     if (empty($from_name)) {
       // If value is not defined in settings, use site_name.
-      $from_name = $this->smtpConfig->get('site_name');
+      $site = \Drupal::config('system.site')->get('name');
+      $from_name = $site ? $site : $this::SMTP_DEFAULT_NAME;
     }
 
     //Hack to fix reply-to issue.
