diff options
author | Angie Byron <webchick@24967.no-reply.drupal.org> | 2010-04-28 05:28:22 +0000 |
---|---|---|
committer | Angie Byron <webchick@24967.no-reply.drupal.org> | 2010-04-28 05:28:22 +0000 |
commit | 1bac765683a8026e5b99a29b8cd20caa950301fb (patch) | |
tree | 6d63668b520f3d68173c670fd3672fd2317c6850 /modules/simpletest/tests/update_test_1.install | |
parent | 7f58309f21e3f857a4681eea9fdc1ae517d6ddc7 (diff) | |
download | brdo-1bac765683a8026e5b99a29b8cd20caa950301fb.tar.gz brdo-1bac765683a8026e5b99a29b8cd20caa950301fb.tar.bz2 |
#211182 follow-up by clemens.tolboom, David_Rothstein, tstoeckler: Re-work update depencency check to deal with array_merge_recursive() edge case (with tests).
Diffstat (limited to 'modules/simpletest/tests/update_test_1.install')
-rw-r--r-- | modules/simpletest/tests/update_test_1.install | 29 |
1 files changed, 29 insertions, 0 deletions
diff --git a/modules/simpletest/tests/update_test_1.install b/modules/simpletest/tests/update_test_1.install index 96e8787b3..ac69a358e 100644 --- a/modules/simpletest/tests/update_test_1.install +++ b/modules/simpletest/tests/update_test_1.install @@ -7,6 +7,35 @@ */ /** + * Implements hook_update_dependencies(). + * + * @see update_test_2_update_dependencies() + */ +function update_test_1_update_dependencies() { + // These dependencies are used in combination with those declared in + // update_test_2_update_dependencies() for the sole purpose of testing that + // the results of hook_update_dependencies() are collected correctly and have + // the correct array structure. Therefore, we use updates from System module + // (which have already run), so that they will not get in the way of other + // tests. + $dependencies['system'][7000] = array( + // Compare to update_test_2_update_dependencies(), where the same System + // module update function is forced to depend on an update function from a + // different module. This allows us to test that both dependencies are + // correctly recorded. + 'update_test_1' => 7000, + ); + $dependencies['system'][7001] = array( + // Compare to update_test_2_update_dependencies(), where the same System + // module update function is forced to depend on a different update + // function within the same module. This allows us to test that only the + // dependency on the higher-numbered update function is recorded. + 'update_test_1' => 7002, + ); + return $dependencies; +} + +/** * Dummy update_test_1 update 7000. */ function update_test_1_update_7000() { |