#NEWLINE# def test_watcher_with_closing( self ) : #NEWLINE# #INDENT# a = [ ] #NEWLINE# ev = threading . Event ( ) #NEWLINE# self . client . delete ( self . path ) #NEWLINE# @ self . client . DataWatch ( self . path ) #NEWLINE# def changed( val , stat ) : #NEWLINE# #INDENT# a . append ( val ) #NEWLINE# ev . set ( ) #NEWLINE# #UNINDENT# eq_ ( a , [ None ] ) #NEWLINE# b = False #NEWLINE# try : #NEWLINE# #INDENT# self . client . stop ( ) #NEWLINE# #UNINDENT# except : #NEWLINE# #INDENT# b = True #NEWLINE# #UNINDENT# eq_ ( b , False )