mirror of
https://github.com/wxWidgets/Phoenix.git
synced 2025-09-07 18:30:57 +02:00
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxPython/Phoenix/trunk@72121 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
25 lines
693 B
Python
25 lines
693 B
Python
import imp_unittest, unittest
|
|
import wtc
|
|
import wx
|
|
|
|
#---------------------------------------------------------------------------
|
|
|
|
class filehistory_Tests(wtc.WidgetTestCase):
|
|
|
|
def test_filehistory1(self):
|
|
fh = wx.FileHistory()
|
|
for fn in "one two three four".split():
|
|
fh.AddFileToHistory(fn)
|
|
|
|
self.assertEqual(fh.GetCount(), 4)
|
|
self.assertEqual(fh.Count, 4)
|
|
self.assertEqual(fh.GetHistoryFile(1), 'three') # they are in LIFO order
|
|
m = wx.Menu()
|
|
fh.AddFilesToMenu(m)
|
|
|
|
|
|
#---------------------------------------------------------------------------
|
|
|
|
if __name__ == '__main__':
|
|
unittest.main()
|