def __init__( self ):
		PyTestSimpleCui.__init__( self )
		self.color = 'green'
		self.root = Tk()
		self.root.title("pytestgui")
		self.width = self.root.winfo_screenwidth() - 300
		self.barFrame = Frame( self.root , bd=2 , relief='sunken' )
		self.barFrame.pack( fill='x' , expand=1 , side='top' , padx=1 , pady=1 )
		self.canvas=Canvas(self.barFrame, width=self.width, height=20)
		self.canvas.pack()
		self.scale=self.canvas.create_rectangle(0, 0, 0, 20,
				fill=self.color, outline=self.color )
		self.descFrame = Frame( self.root )
		self.descFrame.pack( fill='x' , expand=1 , side='bottom' )
		self.test = Desc( self.descFrame , 'test_Normal' , self.width )
		self.testTime = Time( self.descFrame , '0:00' )
		self.testSuite = Desc( self.descFrame , 'Test_Good' , self.width )
		self.testSuiteTime = Time( self.descFrame , '0:00' )
		self.total = Desc( self.descFrame , '100 of 100' , self.width )
		self.testTotalTime = Time( self.descFrame , '0:00' )
		self.count = 0
		self.quit = False
		self.testDescription = ""
		self.suiteDescription = ""
		self.testsCount = 999
		self.updateRequested = False
		thread.start_new_thread( self.root.mainloop , () )
		time.sleep( 0.01 )
		self.centerWindow()
Esempio n. 2
0
 def __init__(self):
     PyTestSimpleCui.__init__(self)
     self.color = 'green'
     self.root = Tk()
     self.root.title("pytestgui")
     self.width = self.root.winfo_screenwidth() - 300
     self.barFrame = Frame(self.root, bd=2, relief='sunken')
     self.barFrame.pack(fill='x', expand=1, side='top', padx=1, pady=1)
     self.canvas = Canvas(self.barFrame, width=self.width, height=20)
     self.canvas.pack()
     self.scale = self.canvas.create_rectangle(0,
                                               0,
                                               0,
                                               20,
                                               fill=self.color,
                                               outline=self.color)
     self.descFrame = Frame(self.root)
     self.descFrame.pack(fill='x', expand=1, side='bottom')
     self.test = Desc(self.descFrame, 'test_Normal', self.width)
     self.testTime = Time(self.descFrame, '0:00')
     self.testSuite = Desc(self.descFrame, 'Test_Good', self.width)
     self.testSuiteTime = Time(self.descFrame, '0:00')
     self.total = Desc(self.descFrame, '100 of 100', self.width)
     self.testTotalTime = Time(self.descFrame, '0:00')
     self.count = 0
     self.quit = False
     self.testDescription = ""
     self.suiteDescription = ""
     self.testsCount = 999
     self.updateRequested = False
     thread.start_new_thread(self.root.mainloop, ())
     time.sleep(0.01)
     self.centerWindow()
Esempio n. 3
0
 def leaveWorld(self, description):
     self.quit = True
     self.askForUpdate()
     time.sleep(0.2)
     return PyTestSimpleCui.leaveWorld(self, description)
Esempio n. 4
0
 def enterSuite(self, description):
     self.suiteDescription = description
     self.askForUpdate()
     return PyTestSimpleCui.enterSuite(self, description)
Esempio n. 5
0
 def enterTest(self, description):
     self.count += 1
     self.testDescription = description
     self.askForUpdate()
     return PyTestSimpleCui.enterTest(self, description)
Esempio n. 6
0
 def failTest(self, fullPath, lineNum, message):
     self.color = 'red'
     self.askForUpdate()
     return PyTestSimpleCui.failTest(self, fullPath, lineNum, message)
Esempio n. 7
0
 def enterWorld(self, description):
     self.testsCount = self._countTests()
     self.askForUpdate()
     return PyTestSimpleCui.enterWorld(self, description)
	def failTest( self, fullPath, lineNum, message ):
		self.color = 'red'
		self.askForUpdate()
		return PyTestSimpleCui.failTest( self , fullPath , lineNum , message )
	def enterWorld( self, description ):
		self.testsCount = self._countTests()
		self.askForUpdate()
		return PyTestSimpleCui.enterWorld( self , description )
Esempio n. 10
0
	def leaveWorld( self , description ):
		self.quit = True
		self.askForUpdate()
		time.sleep( 0.2 )
		return PyTestSimpleCui.leaveWorld( self , description )
Esempio n. 11
0
	def enterSuite( self , description ):
		self.suiteDescription = description
		self.askForUpdate()
		return PyTestSimpleCui.enterSuite( self , description )
Esempio n. 12
0
	def enterTest( self, description ):
		self.count += 1
		self.testDescription = description;
		self.askForUpdate()
		return PyTestSimpleCui.enterTest( self , description )