[Locale] Fixed: StubLocale::setDefault() throws no exception when "en" is passed
This commit is contained in:
parent
b2cbc67289
commit
d0faf5531d
@ -466,8 +466,10 @@ class StubLocale
|
|||||||
*/
|
*/
|
||||||
public static function setDefault($locale)
|
public static function setDefault($locale)
|
||||||
{
|
{
|
||||||
|
if ('en' !== $locale) {
|
||||||
throw new MethodNotImplementedException(__METHOD__);
|
throw new MethodNotImplementedException(__METHOD__);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
public static function getDataDirectory()
|
public static function getDataDirectory()
|
||||||
{
|
{
|
||||||
|
@ -252,4 +252,9 @@ class StubLocaleTest extends LocaleTestCase
|
|||||||
{
|
{
|
||||||
StubLocale::setDefault('pt_BR');
|
StubLocale::setDefault('pt_BR');
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public function testSetDefaultAcceptsEn()
|
||||||
|
{
|
||||||
|
StubLocale::setDefault('en');
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user