#NEWLINE# def test_pf_autoscale_manage_api_delete_valid( self ) : #NEWLINE# #INDENT# api_id = self . setup_useable_api_call ( ) #NEWLINE# with self . app as c : #NEWLINE# #INDENT# with c . session_transaction ( ) as sess : #NEWLINE# #INDENT# self . setup_admin_login ( sess ) #NEWLINE# #UNINDENT# response = c . get ( ( '/autoscale/manage/api/delete/%s' % response ) , follow_redirects = True ) #NEWLINE# #UNINDENT# self . assertIn ( 'API call was successfully removed' , response . data , 'Invalid response found after deleting call' ) #NEWLINE# api_call = self . db . autoscale . find ( ) #NEWLINE# self . assertEquals ( api_call . count ( ) , 0 , ( 'Invalid api count found %d and should be 0' % api_call . count ( ) ) )