Move ResultWrapper subclasses to Rdbms
[mediawiki.git] / tests / phpunit / languages / classes / LanguageSlTest.php
blobed138c500e87890016bdf943727eeda60a8f1e52
1 <?php
2 /**
3 * @author Santhosh Thottingal
4 * @copyright Copyright © 2012, Amir E. Aharoni
5 * based on LanguageSkTest.php
6 * @file
7 */
9 /** Tests for MediaWiki languages/classes/LanguageSl.php */
10 class LanguageSlTest extends LanguageClassesTestCase {
11 /**
12 * @dataProvider providerPlural
13 * @covers Language::convertPlural
15 public function testPlural( $result, $value ) {
16 $forms = [ 'one', 'two', 'few', 'other' ];
17 $this->assertEquals( $result, $this->getLang()->convertPlural( $value, $forms ) );
20 /**
21 * @dataProvider providerPlural
22 * @covers Language::getPluralRuleType
24 public function testGetPluralRuleType( $result, $value ) {
25 $this->assertEquals( $result, $this->getLang()->getPluralRuleType( $value ) );
28 public static function providerPlural() {
29 return [
30 [ 'other', 0 ],
31 [ 'one', 1 ],
32 [ 'two', 2 ],
33 [ 'few', 3 ],
34 [ 'few', 4 ],
35 [ 'other', 5 ],
36 [ 'other', 99 ],
37 [ 'other', 100 ],
38 [ 'one', 101 ],
39 [ 'two', 102 ],
40 [ 'few', 103 ],
41 [ 'one', 201 ],