Merge "QUnit: Re-enable config.requireExpects and add missing numbers."
[lhc/web/wiklou.git] / tests / phpunit / languages / LanguageSkTest.php
1 <?php
2 /**
3 * @author Santhosh Thottingal
4 * @copyright Copyright © 2012, Amir E. Aharoni
5 * based on LanguageSkTest.php
6 * @file
7 */
8
9 /** Tests for MediaWiki languages/classes/LanguageSk.php */
10 class LanguageSkTest extends LanguageClassesTestCase {
11 /** @dataProvider providePlural */
12 function testPlural( $result, $value ) {
13 $forms = array( 'one', 'few', 'other' );
14 $this->assertEquals( $result, $this->getLang()->convertPlural( $value, $forms ) );
15 }
16
17 /** @dataProvider providePlural */
18 function testGetPluralRuleType( $result, $value ) {
19 $this->assertEquals( $result, $this->getLang()->getPluralRuleType( $value ) );
20 }
21
22 public static function providePlural() {
23 return array (
24 array( 'other', 0 ),
25 array( 'one', 1 ),
26 array( 'few', 2 ),
27 array( 'few', 3 ),
28 array( 'few', 4 ),
29 array( 'other', 5 ),
30 array( 'other', 11 ),
31 array( 'other', 20 ),
32 array( 'other', 25 ),
33 array( 'other', 200 ),
34 );
35 }
36 }