mirror of
https://github.com/silverstripe/silverstripe-framework
synced 2024-10-22 14:05:37 +02:00
28 lines
638 B
PHP
28 lines
638 B
PHP
<?php
|
|
|
|
namespace SilverStripe\ORM\Tests;
|
|
|
|
use SilverStripe\ORM\FieldType\DBField;
|
|
use SilverStripe\Dev\SapphireTest;
|
|
|
|
class DBLocaleTest extends SapphireTest
|
|
{
|
|
public function testNice()
|
|
{
|
|
$l = DBField::create_field('Locale', 'de_DE');
|
|
$this->assertEquals($l->Nice(), 'German');
|
|
}
|
|
|
|
public function testNiceNative()
|
|
{
|
|
$l = DBField::create_field('Locale', 'de_DE');
|
|
$this->assertEquals($l->Nice(true), 'Deutsch');
|
|
}
|
|
|
|
public function testNativeName()
|
|
{
|
|
$l = DBField::create_field('Locale', 'de_DE');
|
|
$this->assertEquals($l->getNativeName(), 'Deutsch');
|
|
}
|
|
}
|