LanguageIuTest.php 704 B

123456789101112131415161718192021222324252627282930313233343536373839
  1. <?php
  2. /**
  3. * @covers LanguageIu
  4. * @covers IuConverter
  5. */
  6. class LanguageIuTest extends LanguageClassesTestCase {
  7. /**
  8. * @dataProvider provideAutoConvertToAllVariants
  9. * @covers Language::autoConvertToAllVariants
  10. */
  11. public function testAutoConvertToAllVariants( $result, $value ) {
  12. $this->assertEquals( $result, $this->getLang()->autoConvertToAllVariants( $value ) );
  13. }
  14. public static function provideAutoConvertToAllVariants() {
  15. return [
  16. // ike-cans
  17. [
  18. [
  19. 'ike-cans' => 'ᐴ',
  20. 'ike-latn' => 'PUU',
  21. 'iu' => 'PUU',
  22. ],
  23. 'PUU'
  24. ],
  25. // ike-latn
  26. [
  27. [
  28. 'ike-cans' => 'ᐴ',
  29. 'ike-latn' => 'puu',
  30. 'iu' => 'ᐴ',
  31. ],
  32. 'ᐴ'
  33. ],
  34. ];
  35. }
  36. }