#NEWLINE# def test_run_resource_event( run ) : #NEWLINE# #INDENT# observer = run . observers [ 0 ] #NEWLINE# ( handle , f_name ) = tempfile . mkstemp ( ) #NEWLINE# run . open_resource ( f_name ) #NEWLINE# observer . resource_event . assert_called_with ( filename = f_name ) #NEWLINE# os . close ( handle ) #NEWLINE# os . remove ( f_name )