FontPickerFieldTest   A
last analyzed

Complexity

Total Complexity 1

Size/Duplication

Total Lines 6
Duplicated Lines 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
wmc 1
eloc 3
c 1
b 0
f 0
dl 0
loc 6
rs 10

1 Method

Rating   Name   Duplication   Size   Complexity  
A testValueReturnsDefaultValueIfFalsy() 0 4 1
1
<?php
2
3
namespace SilverStripe\Fontpicker\Tests\Forms;
4
5
use SilverStripe\Core\Config\Config;
6
use SilverStripe\Fontpicker\Forms\FontPickerField;
7
use SilverStripe\Dev\SapphireTest;
8
9
class FontPickerFieldTest extends SapphireTest
10
{
11
    public function testValueReturnsDefaultValueIfFalsy()
12
    {
13
        $field = new FontPickerField('test');
14
        $this->assertSame(Config::inst()->get(FontPickerField::class, 'default_font'), $field->Value());
15
    }
16
}
17