Updated to Drupal 8.5. Core Media not yet in use.
[yaffs-website] / vendor / drush / drush / tests / resources / modules / d8 / woot / woot.install
1 <?php
2
3 /**
4  * Good update.
5  */
6 function woot_update_8101() {
7   return t('This is the update message from woot_update_8101');
8 }
9
10 /**
11  * Failing update.
12  */
13 function woot_update_8102() {
14   throw new \Exception('This is the exception message thrown in woot_update_8102');
15 }
16
17 /**
18  * Another good update.
19  */
20 function woot_update_8103() {
21   // By using the theme system we can test that all Drupal modules are fully
22   // loaded when the updates are being performed. The renderer will throw an
23   // exception if this is not the case.
24   $render_array = [
25     '#theme' => 'item_list',
26     '#items' => ['a', 'b'],
27   ];
28   \Drupal::service('renderer')->renderPlain($render_array);
29   return t('This is the update message from woot_update_8103');
30 }