#NEWLINE# @ mock . patch ( ( DESIGNATE_BASIC + '._delete_zone' ) ) #NEWLINE# @ mock . patch ( ( DESIGNATE_BASIC + '._create_zone' ) ) #NEWLINE# def test_create_and_delete_zone( self , mock_designate_basic__create_zone , mock_designate_basic__delete_zone ) : #NEWLINE# #INDENT# scenario = basic . DesignateBasic ( self . context ) #NEWLINE# mock_designate_basic__create_zone . return_value = { #NEWLINE# #INDENT# 'id' : '123' , #NEWLINE# #UNINDENT# } #NEWLINE# scenario . create_and_delete_zone ( ) #NEWLINE# mock_designate_basic__create_zone . assert_called_once_with ( ) #NEWLINE# mock_designate_basic__delete_zone . assert_called_once_with ( '123' )