FoxyStripeSettingTest   A
last analyzed

Complexity

Total Complexity 2

Size/Duplication

Total Lines 24
Duplicated Lines 0 %

Importance

Changes 0
Metric Value
wmc 2
eloc 7
dl 0
loc 24
rs 10
c 0
b 0
f 0

2 Methods

Rating   Name   Duplication   Size   Complexity  
A testGetDataMap() 0 4 1
A testGetCMSFields() 0 5 1
1
<?php
2
3
namespace Dynamic\FoxyStripe\Test;
4
5
use Dynamic\FoxyStripe\Model\FoxyStripeSetting;
6
use SilverStripe\Dev\SapphireTest;
7
use SilverStripe\Forms\FieldList;
8
9
class FoxyStripeSettingTest extends SapphireTest
10
{
11
    /**
12
     * @var string
13
     */
14
    protected static $fixture_file = 'fixtures.yml';
15
16
    /**
17
     *
18
     */
19
    public function testGetCMSFields()
20
    {
21
        $object = singleton(FoxyStripeSetting::class);
22
        $fields = $object->getCMSFields();
23
        $this->assertInstanceOf(FieldList::class, $fields);
24
    }
25
26
    /**
27
     *
28
     */
29
    public function testGetDataMap()
30
    {
31
        $object = singleton(FoxyStripeSetting::class);
32
        $this->assertTrue(is_array($object->getDataMap()));
33
    }
34
}
35