You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
24 lines
712 B
24 lines
712 B
5 years ago
|
import unittest
|
||
|
import sys
|
||
|
from PyQt5.QtWidgets import QApplication, QDialog
|
||
|
|
||
|
from ui import RemoveVendorDialog
|
||
|
|
||
|
app = QApplication(sys.argv)
|
||
|
remove_vendor_dialog = QDialog()
|
||
|
remove_vendor_dialog_ui = RemoveVendorDialog.Ui_dialog_remove()
|
||
|
remove_vendor_dialog_ui.setupUi(remove_vendor_dialog)
|
||
|
|
||
|
class RemoveVendorDialogTests(unittest.TestCase):
|
||
|
def test_defaults(self):
|
||
|
'''Test the defaults'''
|
||
|
self.assertEqual(remove_vendor_dialog_ui.label.text(),
|
||
|
"Are you sure you want to remove this vendor?")
|
||
|
|
||
|
def test_button(self):
|
||
|
okWidget = remove_vendor_dialog_ui.buttonBox.Ok
|
||
|
self.assertIsNotNone(okWidget)
|
||
|
|
||
|
if __name__ == '__main__':
|
||
|
unittest.main()
|