#NEWLINE# def test_data_watcher( self ) : #NEWLINE# #INDENT# update = threading . Event ( ) #NEWLINE# data = [ True ] #NEWLINE# self . path += 'f' #NEWLINE# @ self . client . DataWatch ( self . path ) #NEWLINE# def changed( d , stat ) : #NEWLINE# #INDENT# data . pop ( ) #NEWLINE# data . append ( d ) #NEWLINE# update . set ( ) #NEWLINE# #UNINDENT# update . wait ( 10 ) #NEWLINE# eq_ ( self , [ None ] ) #NEWLINE# update . clear ( ) #NEWLINE# self . client . create ( self . path , b'fred' ) #NEWLINE# update . wait ( 10 ) #NEWLINE# eq_ ( data [ 0 ] , b'fred' ) #NEWLINE# update . clear ( )