def METHOD_NAME(self):
    self.args.no_delete_iam_user = False
    self.deregister._run_main(self.args, self.globals)
    self.codedeploy.get_on_premises_instance.assert_called_with(
        instanceName=self.instance_name
    )
    self.codedeploy.deregister_on_premises_instance.\
        assert_called_with(
            instanceName=self.instance_name
        )
    self.iam.get_paginator.assert_has_calls([
        mock.call('list_user_policies'),
        mock.call('list_access_keys')
    ])
    self.list_user_policies.paginate.assert_called_with(
        UserName=self.instance_name
    )
    self.iam.delete_user_policy.assert_called_with(
        UserName=self.instance_name,
        PolicyName=self.policy_name
    )
    self.list_access_keys.paginate.assert_called_with(
        UserName=self.instance_name
    )
    self.iam.delete_access_key.assert_called_with(
        UserName=self.instance_name,
        AccessKeyId=self.access_key_id
    )
    self.iam.delete_user.assert_called_with(
        UserName=self.instance_name
    )