Commit graph

7 commits

Author SHA1 Message Date
Timo Tijhof
46b04ec7ae Use static::class instead of get_called_class()
Available as of PHP 5.5 and more idomatic. Foo::class (explicit),
self::class (defined), and static::class (late bound).

Change-Id: I66937f32095a4e4ecde94ca20a935a3c3efc9cee
2016-02-29 22:43:58 +00:00
Siebrand Mazeland
8e0c0a9fc9 Preparations for migrating core to use JSON based i18n
LocalisationCache and Language have to take the JSON files into account
in deciding if a language is present or not.

Standardizing language validity checking with isSupportedLanguage
and isValidBuiltInCode.

Co-Authored-By: Niklas Laxström <niklas.laxstrom@gmail.com>
Co-Authored-By: Siebrand Mazeland <siebrand@kitano.nl>
Change-Id: I35bbb3a7a145fc48d14fff620407dff5ecfdd4fc
2014-04-01 14:22:03 -07:00
addshore
46a17d0fc3 Cleanup /languages/* tests
This change:
 - Adds method scope
 - adds @covers tags
 - adds various @todos
 - fixes some comments

Before the changes tests ran with:
   1383 tests, 1412 assertions 10 skips
After changes the results remain the same

Change-Id: Iee57447bdb47026952ef5dcce6fed5dad0f80e52
2013-10-22 12:32:29 +02:00
Chad Horohoe
c9b831a02a Clean up language test cases objection construction
I have no clue how this ever actually worked under Zend, but it
definitely didn't with HHVM. Now it works on both.

Change-Id: I521dfb74f30306736adda5662598fd036ad9849b
2013-09-26 16:09:13 -07:00
Siebrand Mazeland
791d0b2a98 Update code formatting
Change-Id: I16a9b42651f1cfb1a70dffbb67b7b83dfeb90d03
2013-04-26 14:21:20 +00:00
Siebrand Mazeland
feb9419a51 Update formatting
7 of n.

Change-Id: I07687a4381f29fd9fc73666e460f25769ed54092
2013-02-15 12:53:41 +00:00
Antoine Musso
a03bf9e27f tests: rm duplicate code in language classes
The language classes have been using the same setUp() tearDown() to
craft a new language object. I have abstracted that code in
LanguageClassesTestCase and made all the language test classes to extend
it. The language is interpolated directly from the class name and an
object for it can be retrieved with the getLang() method.

Change-Id: Ib931336ce219edabe2c72b7e9f04c976a500723e
2012-10-29 09:40:30 +01:00