Completed
Pull Request — master (#62)
by Jason
11:55
created

DynamicBlocksSlideImageDataExtensionTest   A

Complexity

Total Complexity 1

Size/Duplication

Total Lines 18
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 1

Importance

Changes 0
Metric Value
wmc 1
lcom 0
cbo 1
dl 0
loc 18
rs 10
c 0
b 0
f 0

1 Method

Rating   Name   Duplication   Size   Complexity  
A testUpdateCMSFields() 0 7 1
1
<?php
2
3
namespace Dynamic\DynamicBlocks\Test;
4
5
use Dynamic\FlexSlider\Model\SlideImage;
6
use SilverStripe\Dev\SapphireTest;
7
use SilverStripe\Forms\FieldList;
8
9
class DynamicBlocksSlideImageDataExtensionTest extends SapphireTest
10
{
11
    /**
12
     * @var string
13
     */
14
    protected static $fixture_file = 'dynamic-blocks/tests/Fixtures.yml';
15
16
    /**
17
     *
18
     */
19
    public function testUpdateCMSFields()
20
    {
21
        $object = singleton(SlideImage::class);
22
        $fields = $object->getCMSFields();
23
        $this->assertInstanceOf(FieldList::class, $fields);
24
        $this->assertNull($fields->dataFieldByName('SlideshowBlockID'));
25
    }
26
}