Index: src/sas/qtgui/Utilities/UnitTesting/GuiUtilsTest.py
===================================================================
--- src/sas/qtgui/Utilities/UnitTesting/GuiUtilsTest.py	(revision 6cb305acde0f8a18b6580f6801bf0cd6613b4587)
+++ src/sas/qtgui/Utilities/UnitTesting/GuiUtilsTest.py	(revision 57be490d989c9a52dd3d902191267a861890a9ef)
@@ -1,2 +1,3 @@
+# -*- coding: utf-8 -*-
 import sys
 import unittest
@@ -446,4 +447,93 @@
         self.assertEqual(yscale, "log")
 
+    def testReplaceHTMLwithUTF8(self):
+        ''' test single character replacement '''
+        s = None
+        with self.assertRaises(AttributeError):
+            result = replaceHTMLwithUTF8(s)
+
+        s = ""
+        self.assertEqual(replaceHTMLwithUTF8(s), s)
+
+        s = "aaaa"
+        self.assertEqual(replaceHTMLwithUTF8(s), s)
+
+        s = "&#x212B; &#x221e;      &#177;"
+        self.assertEqual(replaceHTMLwithUTF8(s), "Ã
+ â      Â±")
+
+    def testReplaceHTMLwithASCII(self):
+        ''' test single character replacement'''
+        s = None
+        with self.assertRaises(AttributeError):
+            result = replaceHTMLwithASCII(s)
+
+        s = ""
+        self.assertEqual(replaceHTMLwithASCII(s), s)
+
+        s = "aaaa"
+        self.assertEqual(replaceHTMLwithASCII(s), s)
+
+        s = "&#x212B; &#x221e;      &#177;"
+        self.assertEqual(replaceHTMLwithASCII(s), "Ang inf      +/-")
+
+    def testConvertUnitToUTF8(self):
+        ''' test unit string replacement'''
+        s = None
+        self.assertIsNone(convertUnitToUTF8(s))
+
+        s = ""
+        self.assertEqual(convertUnitToUTF8(s), s)
+
+        s = "aaaa"
+        self.assertEqual(convertUnitToUTF8(s), s)
+
+        s = "1/A"
+        self.assertEqual(convertUnitToUTF8(s), "Ã
+<sup>-1</sup>")
+
+        s = "Ang"
+        self.assertEqual(convertUnitToUTF8(s), "Ã
+")
+
+        s = "1e-6/Ang^2"
+        self.assertEqual(convertUnitToUTF8(s), "10<sup>-6</sup>/Ã
+<sup>2</sup>")
+
+        s = "inf"
+        self.assertEqual(convertUnitToUTF8(s), "â")
+
+        s = "1/cm"
+        self.assertEqual(convertUnitToUTF8(s), "cm<sup>-1</sup>")
+
+    def testConvertUnitToHTML(self):
+        ''' test unit string replacement'''
+        s = None
+        self.assertIsNone(convertUnitToHTML(s))
+
+        s = ""
+        self.assertEqual(convertUnitToHTML(s), s)
+
+        s = "aaaa"
+        self.assertEqual(convertUnitToHTML(s), s)
+
+        s = "1/A"
+        self.assertEqual(convertUnitToHTML(s), "&#x212B;<sup>-1</sup>")
+
+        s = "Ang"
+        self.assertEqual(convertUnitToHTML(s), "&#x212B;")
+
+        s = "1e-6/Ang^2"
+        self.assertEqual(convertUnitToHTML(s), "10<sup>-6</sup>/&#x212B;<sup>2</sup>")
+
+        s = "inf"
+        self.assertEqual(convertUnitToHTML(s), "&#x221e;")
+        s = "-inf"
+
+        self.assertEqual(convertUnitToHTML(s), "-&#x221e;")
+
+        s = "1/cm"
+        self.assertEqual(convertUnitToHTML(s), "cm<sup>-1</sup>")
+
     def testParseName(self):
         '''test parse out a string from the beinning of a string'''
Index: src/sas/qtgui/Utilities/UnitTesting/ReportDialogTest.py
===================================================================
--- src/sas/qtgui/Utilities/UnitTesting/ReportDialogTest.py	(revision 57be490d989c9a52dd3d902191267a861890a9ef)
+++ src/sas/qtgui/Utilities/UnitTesting/ReportDialogTest.py	(revision 57be490d989c9a52dd3d902191267a861890a9ef)
@@ -0,0 +1,150 @@
+import os
+import sys
+import unittest
+import logging
+from xhtml2pdf import pisa
+
+from unittest.mock import mock_open, patch
+
+from unittest.mock import MagicMock
+
+from PyQt5 import QtWidgets, QtPrintSupport
+
+# set up import paths
+import path_prepare
+
+import sas.qtgui.Utilities.GuiUtils as GuiUtils
+# Local
+from sas.qtgui.Utilities.ReportDialog import ReportDialog
+
+if not QtWidgets.QApplication.instance():
+    app = QtWidgets.QApplication(sys.argv)
+
+class ReportDialogTest(unittest.TestCase):
+    '''Test the report dialog'''
+    def setUp(self):
+        '''Create the dialog'''
+        class dummy_manager(object):
+            _parent = QtWidgets.QWidget()
+            def communicator(self):
+                return GuiUtils.Communicate()
+            def communicate(self):
+                return GuiUtils.Communicate()
+
+        test_html = "test_html"
+        test_txt = "test_txt"
+        test_images = []
+        self.test_list = [test_html, test_txt, test_images]
+        self.widget = ReportDialog(parent=dummy_manager(), report_list=self.test_list)
+
+    def tearDown(self):
+        '''Destroy the GUI'''
+        #self.widget.close()
+        self.widget = None
+
+    def testDefaults(self):
+        '''Look at the default state of the widget'''
+        self.assertIn(self.test_list[0], self.widget.txtBrowser.toHtml())
+        self.assertTrue(self.widget.txtBrowser.isReadOnly())
+
+    def testOnPrint(self):
+        ''' Printing the report '''
+        document = self.widget.txtBrowser.document()
+        document.print = MagicMock()
+
+        # test rejected dialog
+        QtPrintSupport.QPrintDialog.exec_ = MagicMock(return_value=QtWidgets.QDialog.Rejected)
+
+        # invoke the method
+        self.widget.onPrint()
+
+        # Assure printing was not done
+        self.assertFalse(document.print.called)
+
+        # test accepted dialog
+        QtPrintSupport.QPrintDialog.exec_ = MagicMock(return_value=QtWidgets.QDialog.Accepted)
+
+        # invoke the method
+        self.widget.onPrint()
+
+        # Assure printing was done
+        self.assertTrue(document.print.called)
+
+
+    def testOnSave(self):
+        ''' Saving the report to a file '''
+        # PDF save
+        QtWidgets.QFileDialog.getSaveFileName = MagicMock(return_value=["test.pdf", "(*.pdf)"])
+        os.startfile = MagicMock()
+        os.system = MagicMock()
+
+        # conversion failed
+        self.widget.HTML2PDF = MagicMock(return_value=1)
+
+        # invoke the method
+        self.widget.onSave()
+
+        # Check that the file wasn't saved
+        if os.name == 'nt':  # Windows
+            self.assertFalse(os.startfile.called)
+        elif sys.platform == "darwin":  # Mac
+            self.assertFalse(os.system.called)
+
+        # conversion succeeded
+        self.widget.HTML2PDF = MagicMock(return_value=0)
+
+        # invoke the method
+        self.widget.onSave()
+
+        # Check that the file was saved
+        if os.name == 'nt':  # Windows
+            self.assertTrue(os.startfile.called)
+        elif sys.platform == "darwin":  # Mac
+            self.assertTrue(os.system.called)
+
+        # TXT save
+        QtWidgets.QFileDialog.getSaveFileName = MagicMock(return_value=["test.txt", "(*.txt)"])
+        self.widget.onTXTSave = MagicMock()
+        # invoke the method
+        self.widget.onSave()
+
+        # Check that the file was saved
+        self.assertTrue(self.widget.onTXTSave)
+
+        # HTML save
+        QtWidgets.QFileDialog.getSaveFileName = MagicMock(return_value=["test.html", "(*.html)"])
+        self.widget.onHTMLSave = MagicMock()
+        # invoke the method
+        self.widget.onSave()
+
+        # Check that the file was saved
+        self.assertTrue(self.widget.onHTMLSave)
+
+    def testGetPictures(self):
+        ''' Saving MPL charts and returning filenames '''
+        pass
+
+    def testHTML2PDF(self):
+        ''' html to pdf conversion '''
+        class pisa_dummy(object):
+            err = 0
+        pisa.CreatePDF = MagicMock(return_value=pisa_dummy())
+        open = MagicMock(return_value="y")
+
+        data = self.widget.txtBrowser.toHtml()
+        return_value = self.widget.HTML2PDF(data, "b")
+
+        self.assertTrue(pisa.CreatePDF.called)
+        self.assertEqual(return_value, 0)
+
+        # Try to raise somewhere
+        pisa.CreatePDF.side_effect = Exception("Failed")
+
+        logging.error = MagicMock()
+
+        #run the method
+        return_value = self.widget.HTML2PDF(data, "c")
+
+        self.assertTrue(logging.error.called)
+        logging.error.assert_called_with("Error creating pdf: Failed")
+
