#NEWLINE# def test_scan_sr_unknown_error_fails_once( self ) : #NEWLINE# #INDENT# session = mock . Mock ( ) #NEWLINE# session . call_xenapi . side_effect = test . TestingException #NEWLINE# self . assertRaises ( test . TestingException , vm_utils . _scan_sr , session , 'sr_ref' ) #NEWLINE# session . call_xenapi . assert_called_once_with ( 'SR.scan' , 'sr_ref' )