Files
Phoenix/unittests/test_fswatcher.py
Robin Dunn 150725928a Add wxFileSystemWatcher
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxPython/Phoenix/trunk@72274 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-08-02 05:39:26 +00:00

22 lines
630 B
Python

import imp_unittest, unittest
import wtc
import wx
#---------------------------------------------------------------------------
class fswatcher_Tests(wtc.WidgetTestCase):
def test_fswatcher1(self):
evtLoop = self.app.GetTraits().CreateEventLoop()
activator = wx.EventLoopActivator(evtLoop) # automatically restores the old one
watcher = wx.FileSystemWatcher()
watcher.Add(__file__)
watcher.Bind(wx.EVT_FSWATCHER, lambda evt: None)
#---------------------------------------------------------------------------
if __name__ == '__main__':
unittest.main()