#NEWLINE# @ test . create_stubs ( { #NEWLINE# #INDENT# api . cinder : ( 'volume_backup_get' , ) , #NEWLINE# #UNINDENT# } ) #NEWLINE# def test_volume_backup_detail_get_with_exception( self ) : #NEWLINE# #INDENT# backup = self . cinder_volume_backups . first ( ) #NEWLINE# api . cinder . volume_backup_get ( IsA ( http . HttpRequest ) , backup . id ) . AndRaise ( self . exceptions . cinder ) #NEWLINE# self . mox . ReplayAll ( ) #NEWLINE# url = reverse ( 'horizon:project:volumes:backups:detail' , args = [ self . id ] ) #NEWLINE# res = self . client . get ( url ) #NEWLINE# self . assertNoFormErrors ( res ) #NEWLINE# self . assertMessageCount ( error = 1 ) #NEWLINE# self . assertRedirectsNoFollow ( res , INDEX_URL )