3 * @author Amir E. Aharoni
4 * @copyright Copyright © 2012, Amir E. Aharoni
8 /** Tests for MediaWiki languages/classes/LanguagePl.php */
9 class LanguagePlTest
extends LanguageClassesTestCase
{
10 /** @dataProvider providePlural */
11 function testPlural( $result, $value ) {
12 $forms = array( 'one', 'few', 'many' );
13 $this->assertEquals( $result, $this->getLang()->convertPlural( $value, $forms ) );
16 /** @dataProvider providePlural */
17 function testGetPluralRuleType( $result, $value ) {
18 $this->assertEquals( $result, $this->getLang()->getPluralRuleType( $value ) );
21 public static function providePlural() {
42 /** @dataProvider providerPluralTwoForms */
43 function testPluralTwoForms( $result, $value ) {
44 $forms = array( 'one', 'other' );
45 $this->assertEquals( $result, $this->getLang()->convertPlural( $value, $forms ) );
48 public static function providerPluralTwoForms() {
64 array( 'other', 200 ),
65 array( 'other', 201 ),