From dd590b30800fdbb7652673cc9b48e005048df557 Mon Sep 17 00:00:00 2001 From: Angie Byron Date: Wed, 27 May 2009 16:29:05 +0000 Subject: #246096 by andypost, mr.baileys, and Sutharsan: Fix typo so that cron triggers may be executed (with tests). --- modules/trigger/tests/trigger_test.info | 7 +++++++ modules/trigger/tests/trigger_test.module | 32 +++++++++++++++++++++++++++++++ 2 files changed, 39 insertions(+) create mode 100644 modules/trigger/tests/trigger_test.info create mode 100644 modules/trigger/tests/trigger_test.module (limited to 'modules/trigger/tests') diff --git a/modules/trigger/tests/trigger_test.info b/modules/trigger/tests/trigger_test.info new file mode 100644 index 000000000..878f9f98b --- /dev/null +++ b/modules/trigger/tests/trigger_test.info @@ -0,0 +1,7 @@ +; $Id$ +name = "Trigger Test" +description = "Support module for Trigger tests." +package = Testing +core = 7.x +files[] = trigger_test.module +hidden = TRUE diff --git a/modules/trigger/tests/trigger_test.module b/modules/trigger/tests/trigger_test.module new file mode 100644 index 000000000..c44360d52 --- /dev/null +++ b/modules/trigger/tests/trigger_test.module @@ -0,0 +1,32 @@ + array( + 'type' => 'system', + 'description' => t('Cron test action'), + 'configurable' => FALSE, + 'hooks' => array( + 'cron' => array('run'), + ), + ), + ); +} + +/** + * Action fired during the "cron run" trigger test. + */ +function trigger_test_system_cron_action() { + // Indicate successful execution by setting a persistent variable. + variable_set('trigger_test_system_cron_action', TRUE); +} -- cgit v1.2.3