def get_ssl_certificate_delete_flow(self): delete_ssl_cert_flow = linear_flow.Flow( a10constants.DELETE_SSL_CERT_FLOW) delete_ssl_cert_flow.add( cert_tasks.GetSSLCertData( requires=[constants.LOADBALANCER, constants.LISTENER], provides=a10constants.CERT_DATA)) delete_ssl_cert_flow.add( cert_tasks.ClientSSLTemplateDelete( requires=[a10constants.CERT_DATA, a10constants.VTHUNDER])) delete_ssl_cert_flow.add( cert_tasks.SSLCertDelete( requires=[a10constants.CERT_DATA, a10constants.VTHUNDER])) delete_ssl_cert_flow.add( cert_tasks.SSLKeyDelete( requires=[a10constants.CERT_DATA, a10constants.VTHUNDER])) return delete_ssl_cert_flow
def get_ssl_certificate_delete_flow(self, listener): delete_ssl_cert_flow = linear_flow.Flow( a10constants.DELETE_SSL_CERT_FLOW) delete_ssl_cert_flow.add(cert_tasks.GetSSLCertData( name='get_ssl_cert_data_' + listener, requires=[constants.LOADBALANCER, constants.LISTENER], rebind={constants.LISTENER: listener}, provides=a10constants.CERT_DATA)) delete_ssl_cert_flow.add(cert_tasks.ClientSSLTemplateDelete( name='client_ssl_template_delete_' + listener, requires=[a10constants.CERT_DATA, a10constants.VTHUNDER])) delete_ssl_cert_flow.add(cert_tasks.SSLCertDelete( name='ssl_cert_delete_' + listener, requires=[a10constants.CERT_DATA, a10constants.VTHUNDER])) delete_ssl_cert_flow.add(cert_tasks.SSLKeyDelete( name='ssl_key_delete_' + listener, requires=[a10constants.CERT_DATA, a10constants.VTHUNDER])) return delete_ssl_cert_flow
def test_ssl_key_delete(self, barbican_class): mock_ssl_key = cert_tasks.SSLKeyDelete() mock_ssl_key.axapi_client = self.client_mock mock_ssl_key.execute(CERT_DATA, VTHUNDER) self.client_mock.file.ssl_key.delete.assert_called_with( file=a10_test_constants.MOCK_KEY_FILENAME)