summaryrefslogtreecommitdiff
path: root/modules/node/tests/node_test_exception.module
blob: 7b09c77c7dd0cc18360aa04a8bf0da26f9fb373e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
<?php
// $Id$

/**
 * @file
 * Dummy module implementing node related hooks to test API interaction with
 * the Node module.
 */

/**
 * Implement hook_node_insert().
 */
function node_test_exception_node_insert($node) {
  if ($node->title['zxx'][0]['value'] == 'testing_transaction_exception') {
    throw new Exception('Test exception for rollback.');
  }
}