Created new unittest model.
Separete unittest for module.
Only run unittest for compiled modules.
Reviewer: Marcelo Lira <marcelo.lira@openbossa.org>,
Luciano Wolf <luciano.wolf@openbossa.org>
This commit is contained in:
parent
471486732b
commit
ab918abc1e
211 changed files with 241 additions and 79 deletions
|
|
@ -1,32 +0,0 @@
|
|||
import unittest
|
||||
import sys
|
||||
|
||||
from PySide import QtGui
|
||||
from PySide import QtCore
|
||||
|
||||
from helper import UsesQApplication
|
||||
|
||||
class MainWindow(QtGui.QMainWindow):
|
||||
def __init__(self):
|
||||
QtGui.QMainWindow.__init__(self)
|
||||
|
||||
self.createToolbar()
|
||||
|
||||
def createToolbar(self):
|
||||
pointerButton = QtGui.QToolButton()
|
||||
pointerToolbar = self.addToolBar("Pointer type")
|
||||
pointerToolbar.addWidget(pointerButton)
|
||||
|
||||
|
||||
class TestMainWindow(UsesQApplication):
|
||||
|
||||
def testCreateToolbar(self):
|
||||
w = MainWindow()
|
||||
w.show()
|
||||
QtCore.QTimer.singleShot(1000, self.app.quit)
|
||||
self.app.exec_()
|
||||
|
||||
|
||||
if __name__ == '__main__':
|
||||
unittest.main()
|
||||
|
||||
Loading…
Add table
Add a link
Reference in a new issue