Code Coverage |
||||||||||
Lines |
Functions and Methods |
Classes and Traits |
||||||||
Total | n/a |
0 / 0 |
n/a |
0 / 0 |
CRAP | n/a |
0 / 0 |
1 | <?php |
2 | |
3 | namespace MediaWiki\Extension\DiscussionTools; |
4 | |
5 | use MediaWiki\MediaWikiServices; |
6 | |
7 | // PHP unit does not understand code coverage for this file |
8 | // as the @covers annotation cannot cover a specific file |
9 | // This is fully tested in ServiceWiringTest.php |
10 | // @codeCoverageIgnoreStart |
11 | |
12 | return [ |
13 | 'DiscussionTools.CommentParser' => static function ( MediaWikiServices $services ): CommentParser { |
14 | return new CommentParser( |
15 | $services->getMainConfig(), |
16 | $services->getContentLanguage(), |
17 | $services->getLanguageConverterFactory(), |
18 | $services->getService( 'DiscussionTools.LanguageData' ), |
19 | $services->getTitleParser() |
20 | ); |
21 | }, |
22 | 'DiscussionTools.LanguageData' => static function ( MediaWikiServices $services ): LanguageData { |
23 | return new LanguageData( |
24 | $services->getMainConfig(), |
25 | $services->getContentLanguage(), |
26 | $services->getLanguageConverterFactory(), |
27 | $services->getSpecialPageFactory() |
28 | ); |
29 | }, |
30 | 'DiscussionTools.SubscriptionStore' => static function ( MediaWikiServices $services ): SubscriptionStore { |
31 | return new SubscriptionStore( |
32 | $services->getConfigFactory(), |
33 | $services->getDBLoadBalancerFactory(), |
34 | $services->getReadOnlyMode(), |
35 | $services->getUserFactory(), |
36 | $services->getUserIdentityUtils() |
37 | ); |
38 | }, |
39 | 'DiscussionTools.ThreadItemStore' => static function ( MediaWikiServices $services ): ThreadItemStore { |
40 | return new ThreadItemStore( |
41 | $services->getConfigFactory(), |
42 | $services->getDBLoadBalancerFactory(), |
43 | $services->getReadOnlyMode(), |
44 | $services->getPageStore(), |
45 | $services->getRevisionStore(), |
46 | $services->getTitleFormatter(), |
47 | $services->getActorStore(), |
48 | $services->getContentLanguage() |
49 | ); |
50 | }, |
51 | 'DiscussionTools.ThreadItemFormatter' => static function ( MediaWikiServices $services ): ThreadItemFormatter { |
52 | return new ThreadItemFormatter( |
53 | $services->getLinkRenderer() |
54 | ); |
55 | }, |
56 | ]; |
57 | |
58 | // @codeCoverageIgnoreEnd |