You are here

function uc_addresses_test_hook_invoked in Ubercart Addresses 7

Reports if a certain hook is invoked.

Automated tests can use this to check whether or not a hook is invoked.

Parameters

string $hook: The hook that was invoked.

object $entity: The entity that was passed with the hook.

5 calls to uc_addresses_test_hook_invoked()
uc_addresses_test_entity_delete in tests/uc_addresses_test.module
Implements hook_entity_delete().
uc_addresses_test_entity_insert in tests/uc_addresses_test.module
Implements hook_entity_insert().
uc_addresses_test_entity_load in tests/uc_addresses_test.module
Implements hook_entity_load().
uc_addresses_test_entity_presave in tests/uc_addresses_test.module
Implements hook_entity_presave().
uc_addresses_test_entity_update in tests/uc_addresses_test.module
Implements hook_entity_update().

File

tests/uc_addresses_test.module, line 114
Testing module for Ubercart Addresses functionality.

Code

function uc_addresses_test_hook_invoked($hook, $entity) {
  variable_set('uc_addresses_' . $hook, entity_id('uc_addresses', $entity));
}