Index: trunk/extensions/GlobalUsage/GlobalUsageHooks.php |
— | — | @@ -99,5 +99,13 @@ |
100 | 100 | |
101 | 101 | return self::$gu; |
102 | 102 | } |
| 103 | + |
| 104 | + /** |
| 105 | + * Hook to make sure globalimagelinks table gets duplicated for parsertests |
| 106 | + */ |
| 107 | + public static function onParserTestTables ( &$tables ) { |
| 108 | + $tables[] = 'globalimagelinks'; |
| 109 | + return true; |
| 110 | + } |
103 | 111 | |
104 | 112 | } |
\ No newline at end of file |
Index: trunk/extensions/GlobalUsage/GlobalUsage.php |
— | — | @@ -70,8 +70,8 @@ |
71 | 71 | $wgHooks['TitleMoveComplete'][] = 'GlobalUsageHooks::onTitleMoveComplete'; |
72 | 72 | $wgHooks['ImagePageAfterImageLinks'][] = 'SpecialGlobalUsage::onImagePageAfterImageLinks'; |
73 | 73 | $wgHooks['ImagePageShowTOC'][] = 'SpecialGlobalUsage::onImagePageShowTOC'; |
| 74 | +$wgHooks['ParserTestTables'][] = 'GlobalUsageHooks::onParserTestTables'; |
74 | 75 | |
75 | | - |
76 | 76 | // If set to false, the local database contains the globalimagelinks table |
77 | 77 | // Else set to something understandable to LBFactory |
78 | 78 | $wgGlobalUsageDatabase = false; |