# Path: heatclient/common/hook_utils.py
# def clear_hook(hc, stack_id, resource_name, hook_type):
# def clear_wildcard_hooks(hc, stack_id, stack_patterns, hook_type,
#                          resource_pattern):
# def get_hook_type_via_status(hc, stack_id):


from unittest import mock
from heatclient.common import hook_utils
import testtools
import heatclient.v1.shell as shell
        shell.do_stack_create(self.client, self.args)
        self.assertEqual(1, self.client.stacks.create.call_count)
        actual_hooks = self.client.stacks.create.call_args[1][
            'environment']['resource_registry']['resources']
        expected_hooks = {
            'bp_e': {'hooks': 'pre-create'},
            'another_bp_e': {'hooks': 'pre-create'},
            'nested_e': {
                'bp': {'hooks': 'pre-create'}
            },
            'super_e': {
                'nested': {
                    'bp': {'hooks': 'pre-create'}
                }
            },
            'bp_a': {'hooks': 'pre-create'},
            'another_bp_a': {'hooks': 'pre-create'},
            'nested_a': {
                'bp': {'hooks': 'pre-create'}
            },
            'super_a': {
                'nested': {
                    'bp': {'hooks': 'pre-create'}
                }
            },
        }
        self.assertEqual(expected_hooks, actual_hooks)

    def test_update_hooks_in_args(self):
        type(self.args).pre_update = mock.PropertyMock(

# Path: heatclient/common/hook_utils.py
# def clear_hook(hc, stack_id, resource_name, hook_type):
# def clear_wildcard_hooks(hc, stack_id, stack_patterns, hook_type,
#                          resource_pattern):
# def get_hook_type_via_status(hc, stack_id):


# Path: heatclient/tests/unit/v1/test_hooks.py
from unittest import mock
from heatclient.common import hook_utils
import testtools
import heatclient.v1.shell as shell

        shell.do_stack_create(self.client, self.args)
        self.assertEqual(1, self.client.stacks.create.call_count)
        actual_hooks = self.client.stacks.create.call_args[1][
            'environment']['resource_registry']['resources']
        expected_hooks = {
            'bp_e': {'hooks': 'pre-create'},
            'another_bp_e': {'hooks': 'pre-create'},
            'nested_e': {
                'bp': {'hooks': 'pre-create'}
            },
            'super_e': {
                'nested': {
                    'bp': {'hooks': 'pre-create'}
                }
            },
            'bp_a': {'hooks': 'pre-create'},
            'another_bp_a': {'hooks': 'pre-create'},
            'nested_a': {
                'bp': {'hooks': 'pre-create'}
            },
            'super_a': {
                'nested': {
                    'bp': {'hooks': 'pre-create'}
                }
            },
        }
        self.assertEqual(expected_hooks, actual_hooks)

    def test_update_hooks_in_args(self):
        type(self.args).pre_update = mock.PropertyMock(

            return_value=['bp', 'another_bp'])