Added release notes for 'ContentHandler::runLegacyHooks' removal
[mediawiki.git] / tests / phpunit / languages / classes / LanguageCsTest.php
blob2d38ee8da10397309e984c77a0575b0f517f0b7f
1 <?php
2 /**
3 * @author Santhosh Thottingal
4 * @copyright Copyright © 2012, Santhosh Thottingal
5 * @file
6 */
8 /** Tests for MediaWiki languages/classes/Languagecs.php */
9 class LanguageCsTest extends LanguageClassesTestCase {
10 /**
11 * @dataProvider providePlural
12 * @covers Language::convertPlural
14 public function testPlural( $result, $value ) {
15 $forms = [ 'one', 'few', 'other' ];
16 $this->assertEquals( $result, $this->getLang()->convertPlural( $value, $forms ) );
19 /**
20 * @dataProvider providePlural
21 * @covers Language::getPluralRuleType
23 public function testGetPluralRuleType( $result, $value ) {
24 $this->assertEquals( $result, $this->getLang()->getPluralRuleType( $value ) );
27 public static function providePlural() {
28 return [
29 [ 'other', 0 ],
30 [ 'one', 1 ],
31 [ 'few', 2 ],
32 [ 'few', 3 ],
33 [ 'few', 4 ],
34 [ 'other', 5 ],
35 [ 'other', 11 ],
36 [ 'other', 20 ],
37 [ 'other', 25 ],
38 [ 'other', 200 ],