Completed
Push — master ( 7ec6b9...12cca3 )
by Jason
03:37
created

testUpdateCMSFields()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 5
Code Lines 3

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
eloc 3
dl 0
loc 5
rs 10
c 0
b 0
f 0
cc 1
nc 1
nop 0
1
<?php
2
3
namespace Dynamic\FoxyStripe\Test;
4
5
use Dynamic\FoxyStripe\Test\TestOnly\TestOption;
6
use Dynamic\FoxyStripe\Test\TestOnly\TestProduct;
7
use SilverStripe\Dev\SapphireTest;
8
use SilverStripe\Forms\FieldList;
9
10
class FoxyStripeOptionInventoryManagerTest extends SapphireTest
11
{
12
    /**
13
     * @var array
14
     */
15
    protected static $fixture_file = array(
16
        '../fixtures.yml',
17
    );
18
19
    /**
20
     * @var array
21
     */
22
    protected static $extra_dataobjects = [
23
        TestProduct::class,
24
        TestOption::class,
25
    ];
26
27
    /**
28
     *
29
     */
30
    public function testUpdateCMSFields()
31
    {
32
        $object = $this->objFromFixture(TestOption::class, 'one');
33
        $fields = $object->getCMSFields();
34
        $this->assertInstanceOf(FieldList::class, $fields);
35
    }
36
}
37