#NEWLINE# def _check_logout_storage_target( self , disconnected_luns_count = 0 ) : #NEWLINE# #INDENT# self . _volume_driver . _volutils . get_target_lun_count . return_value = 1 #NEWLINE# self . _volume_driver . logout_storage_target ( target_iqn = mock . sentinel . fake_iqn , disconnected_luns_count = disconnected_luns_count ) #NEWLINE# logout_storage = self . _volume_driver . _volutils . logout_storage_target #NEWLINE# if disconnected_luns_count : #NEWLINE# #INDENT# logout_storage . assert_called_once_with ( mock . sentinel . fake_iqn ) #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# self . assertFalse ( logout_storage . called )